<?php
$tdataLeads_Management=array();
	$tdataLeads_Management[".NumberOfChars"]=80; 
	$tdataLeads_Management[".ShortName"]="Leads_Management";
	$tdataLeads_Management[".OwnerID"]="Employee Name";
	$tdataLeads_Management[".OriginalTable"]="lead_table";


	
//	field labels
$fieldLabelsLeads_Management = array();
if(mlang_getcurrentlang()=="English")
{
	$fieldLabelsLeads_Management["English"]=array();
	$fieldToolTipsLeads_Management["English"]=array();
	$fieldLabelsLeads_Management["English"]["Leadid"] = "Leadid";
	$fieldToolTipsLeads_Management["English"]["Leadid"] = "";
	$fieldLabelsLeads_Management["English"]["Region"] = "Region";
	$fieldToolTipsLeads_Management["English"]["Region"] = "";
	$fieldLabelsLeads_Management["English"]["Customer_Name"] = "Customer Name";
	$fieldToolTipsLeads_Management["English"]["Customer Name"] = "";
	$fieldLabelsLeads_Management["English"]["Contact_Person"] = "Contact Person";
	$fieldToolTipsLeads_Management["English"]["Contact Person"] = "";
	$fieldLabelsLeads_Management["English"]["Lead_Details"] = "Lead Details";
	$fieldToolTipsLeads_Management["English"]["Lead Details"] = "";
	$fieldLabelsLeads_Management["English"]["Employee_Name"] = "Employee Name";
	$fieldToolTipsLeads_Management["English"]["Employee Name"] = "";
	$fieldLabelsLeads_Management["English"]["Approx_Closure_Date"] = "Approx Closure Date";
	$fieldToolTipsLeads_Management["English"]["Approx Closure Date"] = "";
	$fieldLabelsLeads_Management["English"]["Lead_Status"] = "Lead Status";
	$fieldToolTipsLeads_Management["English"]["Lead Status"] = "";
	$fieldLabelsLeads_Management["English"]["Requirement_Details"] = "Requirement Details";
	$fieldToolTipsLeads_Management["English"]["Requirement Details"] = "";
	$fieldLabelsLeads_Management["English"]["Approx_Value"] = "Approx Value";
	$fieldToolTipsLeads_Management["English"]["Approx Value"] = "";
	$fieldLabelsLeads_Management["English"]["First_Quote_Remarks"] = "First Quote Remarks";
	$fieldToolTipsLeads_Management["English"]["First Quote Remarks"] = "";
	$fieldLabelsLeads_Management["English"]["Proposed_Closure_Date"] = "Proposed Closure Date";
	$fieldToolTipsLeads_Management["English"]["Proposed Closure Date"] = "";
	$fieldLabelsLeads_Management["English"]["Projected_Closure_QTR"] = "Projected Closure QTR";
	$fieldToolTipsLeads_Management["English"]["Projected Closure QTR"] = "";
	$fieldLabelsLeads_Management["English"]["Proposed_Solution_Details"] = "Proposed Solution Details";
	$fieldToolTipsLeads_Management["English"]["Proposed Solution Details"] = "";
	$fieldLabelsLeads_Management["English"]["Quoted_Price"] = "Quoted Price";
	$fieldToolTipsLeads_Management["English"]["Quoted Price"] = "";
	$fieldLabelsLeads_Management["English"]["Final_Quote_Remarks"] = "Final Quote Remarks";
	$fieldToolTipsLeads_Management["English"]["Final Quote Remarks"] = "";
	$fieldLabelsLeads_Management["English"]["Discussion_Highlights"] = "Discussion Highlights";
	$fieldToolTipsLeads_Management["English"]["Discussion Highlights"] = "";
	$fieldLabelsLeads_Management["English"]["WIN___Lost_Analysis"] = "WIN / Lost Analysis";
	$fieldToolTipsLeads_Management["English"]["WIN / Lost Analysis"] = "";
	$fieldLabelsLeads_Management["English"]["Alligned_Vendor"] = "Alligned Vendor";
	$fieldToolTipsLeads_Management["English"]["Alligned Vendor"] = "";
	$fieldLabelsLeads_Management["English"]["Address"] = "Address";
	$fieldToolTipsLeads_Management["English"]["Address"] = "";
	$fieldLabelsLeads_Management["English"]["City"] = "City";
	$fieldToolTipsLeads_Management["English"]["City"] = "";
	$fieldLabelsLeads_Management["English"]["State"] = "State";
	$fieldToolTipsLeads_Management["English"]["State"] = "";
	$fieldLabelsLeads_Management["English"]["Postal_Code"] = "Postal Code";
	$fieldToolTipsLeads_Management["English"]["Postal Code"] = "";
	if (count($fieldToolTipsLeads_Management["English"])){
		$tdataLeads_Management[".isUseToolTips"]=true;
	}
}


	
	$tdataLeads_Management[".NCSearch"]=true;

	

$tdataLeads_Management[".shortTableName"] = "Leads_Management";
$tdataLeads_Management[".nSecOptions"] = 1;
$tdataLeads_Management[".recsPerRowList"] = 1;	
$tdataLeads_Management[".tableGroupBy"] = "0";
$tdataLeads_Management[".mainTableOwnerID"] = "Employee Name";
$tdataLeads_Management[".moveNext"] = 1;




$tdataLeads_Management[".showAddInPopup"] = false;

$tdataLeads_Management[".showEditInPopup"] = false;

$tdataLeads_Management[".showViewInPopup"] = false;


$tdataLeads_Management[".fieldsForRegister"] = array();

$tdataLeads_Management[".listAjax"] = false;

	$tdataLeads_Management[".audit"] = false;

	$tdataLeads_Management[".locking"] = false;
	
$tdataLeads_Management[".listIcons"] = true;
$tdataLeads_Management[".edit"] = true;
$tdataLeads_Management[".view"] = true;




$tdataLeads_Management[".showSimpleSearchOptions"] = false;

$tdataLeads_Management[".showSearchPanel"] = true;


$tdataLeads_Management[".isUseAjaxSuggest"] = true;

$tdataLeads_Management[".rowHighlite"] = true;


// button handlers file names

$tdataLeads_Management[".addPageEvents"] = false;

$tdataLeads_Management[".arrKeyFields"][] = "Leadid";

// use datepicker for search panel
$tdataLeads_Management[".isUseCalendarForSearch"] = true;

// use timepicker for search panel
$tdataLeads_Management[".isUseTimeForSearch"] = false;

$tdataLeads_Management[".isUseiBox"] = false;


$tdataLeads_Management[".useDetailsPreview"] = true;	


$tdataLeads_Management[".isUseInlineJs"] = $tdataLeads_Management[".isUseInlineAdd"] || $tdataLeads_Management[".isUseInlineEdit"];

$tdataLeads_Management[".allSearchFields"] = array();

$tdataLeads_Management[".globSearchFields"][] = "Leadid";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Leadid", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Leadid";	
}
$tdataLeads_Management[".globSearchFields"][] = "Region";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Region", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Region";	
}
$tdataLeads_Management[".globSearchFields"][] = "Customer Name";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Customer Name", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Customer Name";	
}
$tdataLeads_Management[".globSearchFields"][] = "Contact Person";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Contact Person", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Contact Person";	
}
$tdataLeads_Management[".globSearchFields"][] = "Lead Details";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Lead Details", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Lead Details";	
}
$tdataLeads_Management[".globSearchFields"][] = "Lead Status";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Lead Status", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Lead Status";	
}
$tdataLeads_Management[".globSearchFields"][] = "Employee Name";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Employee Name", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Employee Name";	
}
$tdataLeads_Management[".globSearchFields"][] = "Projected Closure QTR";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Projected Closure QTR", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Projected Closure QTR";	
}
$tdataLeads_Management[".globSearchFields"][] = "Approx Value";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Approx Value", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Approx Value";	
}
$tdataLeads_Management[".globSearchFields"][] = "Approx Closure Date";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Approx Closure Date", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Approx Closure Date";	
}
$tdataLeads_Management[".globSearchFields"][] = "Quoted Price";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Quoted Price", $tdataLeads_Management[".allSearchFields"]))
{
	$tdataLeads_Management[".allSearchFields"][] = "Quoted Price";	
}


$tdataLeads_Management[".googleLikeFields"][] = "State";
$tdataLeads_Management[".googleLikeFields"][] = "City";
$tdataLeads_Management[".googleLikeFields"][] = "Address";
$tdataLeads_Management[".googleLikeFields"][] = "Postal Code";
$tdataLeads_Management[".googleLikeFields"][] = "Leadid";
$tdataLeads_Management[".googleLikeFields"][] = "Region";
$tdataLeads_Management[".googleLikeFields"][] = "Customer Name";
$tdataLeads_Management[".googleLikeFields"][] = "Contact Person";
$tdataLeads_Management[".googleLikeFields"][] = "Lead Details";
$tdataLeads_Management[".googleLikeFields"][] = "Alligned Vendor";
$tdataLeads_Management[".googleLikeFields"][] = "Lead Status";
$tdataLeads_Management[".googleLikeFields"][] = "Employee Name";
$tdataLeads_Management[".googleLikeFields"][] = "Projected Closure QTR";
$tdataLeads_Management[".googleLikeFields"][] = "Approx Value";
$tdataLeads_Management[".googleLikeFields"][] = "Requirement Details";
$tdataLeads_Management[".googleLikeFields"][] = "Approx Closure Date";
$tdataLeads_Management[".googleLikeFields"][] = "Quoted Price";
$tdataLeads_Management[".googleLikeFields"][] = "Proposed Solution Details";
$tdataLeads_Management[".googleLikeFields"][] = "Proposed Closure Date";
$tdataLeads_Management[".googleLikeFields"][] = "First Quote Remarks";
$tdataLeads_Management[".googleLikeFields"][] = "Final Quote Remarks";
$tdataLeads_Management[".googleLikeFields"][] = "Discussion Highlights";
$tdataLeads_Management[".googleLikeFields"][] = "WIN / Lost Analysis";



$tdataLeads_Management[".advSearchFields"][] = "State";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("State", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "State";	
}
$tdataLeads_Management[".advSearchFields"][] = "City";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("City", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "City";	
}
$tdataLeads_Management[".advSearchFields"][] = "Address";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Address", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Address";	
}
$tdataLeads_Management[".advSearchFields"][] = "Postal Code";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Postal Code", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Postal Code";	
}
$tdataLeads_Management[".advSearchFields"][] = "Leadid";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Leadid", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Leadid";	
}
$tdataLeads_Management[".advSearchFields"][] = "Region";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Region", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Region";	
}
$tdataLeads_Management[".advSearchFields"][] = "Customer Name";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Customer Name", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Customer Name";	
}
$tdataLeads_Management[".advSearchFields"][] = "Contact Person";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Contact Person", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Contact Person";	
}
$tdataLeads_Management[".advSearchFields"][] = "Lead Details";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Lead Details", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Lead Details";	
}
$tdataLeads_Management[".advSearchFields"][] = "Alligned Vendor";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Alligned Vendor", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Alligned Vendor";	
}
$tdataLeads_Management[".advSearchFields"][] = "Lead Status";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Lead Status", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Lead Status";	
}
$tdataLeads_Management[".advSearchFields"][] = "Employee Name";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Employee Name", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Employee Name";	
}
$tdataLeads_Management[".advSearchFields"][] = "Projected Closure QTR";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Projected Closure QTR", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Projected Closure QTR";	
}
$tdataLeads_Management[".advSearchFields"][] = "Approx Value";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Approx Value", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Approx Value";	
}
$tdataLeads_Management[".advSearchFields"][] = "Requirement Details";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Requirement Details", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Requirement Details";	
}
$tdataLeads_Management[".advSearchFields"][] = "Approx Closure Date";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Approx Closure Date", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Approx Closure Date";	
}
$tdataLeads_Management[".advSearchFields"][] = "Quoted Price";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Quoted Price", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Quoted Price";	
}
$tdataLeads_Management[".advSearchFields"][] = "Proposed Solution Details";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Proposed Solution Details", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Proposed Solution Details";	
}
$tdataLeads_Management[".advSearchFields"][] = "Proposed Closure Date";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Proposed Closure Date", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Proposed Closure Date";	
}
$tdataLeads_Management[".advSearchFields"][] = "First Quote Remarks";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("First Quote Remarks", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "First Quote Remarks";	
}
$tdataLeads_Management[".advSearchFields"][] = "Final Quote Remarks";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Final Quote Remarks", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Final Quote Remarks";	
}
$tdataLeads_Management[".advSearchFields"][] = "Discussion Highlights";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Discussion Highlights", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "Discussion Highlights";	
}
$tdataLeads_Management[".advSearchFields"][] = "WIN / Lost Analysis";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("WIN / Lost Analysis", $tdataLeads_Management[".allSearchFields"])) 
{
	$tdataLeads_Management[".allSearchFields"][] = "WIN / Lost Analysis";	
}

$tdataLeads_Management[".isTableType"] = "list";


	

$tdataLeads_Management[".isDisplayLoading"] = true;

$tdataLeads_Management[".isResizeColumns"] = false;

	$tdataLeads_Management[".subQueriesSupAccess"] = true;



$tdataLeads_Management[".totalsFields"][] = array("fName"=>"Leadid", "totalsType"=>"COUNT", "viewFormat"=>"");
$tdataLeads_Management[".totalsFields"][] = array("fName"=>"Approx Value", "totalsType"=>"TOTAL", "viewFormat"=>"");
$tdataLeads_Management[".totalsFields"][] = array("fName"=>"Quoted Price", "totalsType"=>"TOTAL", "viewFormat"=>"");

$tdataLeads_Management[".pageSize"] = 20;

$gstrOrderBy = "ORDER BY lead_table.`Approx Closure Date`, lead_table.`Lead Status`";
if(strlen($gstrOrderBy) && strtolower(substr($gstrOrderBy,0,8))!="order by")
	$gstrOrderBy = "order by ".$gstrOrderBy;
$tdataLeads_Management[".strOrderBy"] = $gstrOrderBy;
	
$tdataLeads_Management[".orderindexes"] = array();
$tdataLeads_Management[".orderindexes"][] = array(7, (1 ? "ASC" : "DESC"), "lead_table.`Approx Closure Date`");
$tdataLeads_Management[".orderindexes"][] = array(8, (1 ? "ASC" : "DESC"), "lead_table.`Lead Status`");

$tdataLeads_Management[".sqlHead"] = "SELECT lead_table.Leadid,  lead_table.Region,  lead_table.`Customer Name`,  lead_table.`Contact Person`,  lead_table.`Lead Details`,  lead_table.`Employee Name`,  lead_table.`Approx Closure Date`,  lead_table.`Lead Status`,  lead_table.`Requirement Details`,  lead_table.`Approx Value`,  lead_table.`First Quote Remarks`,  lead_table.`Proposed Closure Date`,  lead_table.`Projected Closure QTR`,  lead_table.`Proposed Solution Details`,  lead_table.`Quoted Price`,  lead_table.`Final Quote Remarks`,  lead_table.`Discussion Highlights`,  lead_table.`WIN / Lost Analysis`,  lead_table.`Alligned Vendor`,  customer_list.Address,  customer_list.City,  customer_list.`State`,  customer_list.`Postal Code`";
$tdataLeads_Management[".sqlFrom"] = "FROM lead_table  INNER JOIN customer_list ON lead_table.`Customer Name` = customer_list.`Customer Name`";
$tdataLeads_Management[".sqlWhereExpr"] = "lead_table.`Lead Status` ='Suspect' OR lead_table.`Lead Status` ='prospect' OR lead_table.`Lead Status` ='Review' OR lead_table.`Lead Status` ='Hot' OR lead_table.`Lead Status` ='Commit'";
$tdataLeads_Management[".sqlTail"] = "";

//fill array of tabs for edit page
$arrEditTabs = array();
	$tabFields = array();
	$tabFields[]="Requirement Details";
	$tabFields[]="Proposed Solution Details";
$arrEditTabs[] = array('tabId'=>'Requirement_Details1',
					   'tabName'=>"Requirement Details",
					   'nType'=>'0',
					   'nOrder'=>7,
					   'tabGroup'=>1,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
	$tabFields = array();
	$tabFields[]="Employee Name";
	$tabFields[]="Proposed Closure Date";
	$tabFields[]="Projected Closure QTR";
	$tabFields[]="Approx Value";
	$tabFields[]="Approx Closure Date";
$arrEditTabs[] = array('tabId'=>'Opportunity_Attributes1',
					   'tabName'=>"Opportunity Attributes",
					   'nType'=>'0',
					   'nOrder'=>10,
					   'tabGroup'=>1,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
	$tabFields = array();
	$tabFields[]="First Quote Remarks";
	$tabFields[]="Final Quote Remarks";
	$tabFields[]="Quoted Price";
$arrEditTabs[] = array('tabId'=>'Quote_Details1',
					   'tabName'=>"Quote Details",
					   'nType'=>'0',
					   'nOrder'=>16,
					   'tabGroup'=>1,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
	$tabFields = array();
	$tabFields[]="Discussion Highlights";
	$tabFields[]="WIN / Lost Analysis";
$arrEditTabs[] = array('tabId'=>'Opportunity_Analysis1',
					   'tabName'=>"Opportunity Analysis",
					   'nType'=>'0',
					   'nOrder'=>20,
					   'tabGroup'=>1,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
$tdataLeads_Management[".arrEditTabs"] = $arrEditTabs;

//fill array of tabs for add page
$arrAddTabs = array();
	$tabFields = array();
$arrAddTabs[] = array('tabId'=>'New_section1',
					  'tabName'=>"New section",
					  'nType'=>'1',
					  'nOrder'=>1,
					  'tabGroup'=>0,
					  'arrFields'=> $tabFields,
					  'expandSec'=>0);
	$tabFields = array();
$arrAddTabs[] = array('tabId'=>'Requirement_Details1',
					  'tabName'=>"Requirement Details",
					  'nType'=>'0',
					  'nOrder'=>3,
					  'tabGroup'=>1,
					  'arrFields'=> $tabFields,
					  'expandSec'=>0);
	$tabFields = array();
$arrAddTabs[] = array('tabId'=>'Opportunity_Attributes1',
					  'tabName'=>"Opportunity Attributes",
					  'nType'=>'0',
					  'nOrder'=>5,
					  'tabGroup'=>1,
					  'arrFields'=> $tabFields,
					  'expandSec'=>0);
	$tabFields = array();
$arrAddTabs[] = array('tabId'=>'Quote_Details1',
					  'tabName'=>"Quote Details",
					  'nType'=>'0',
					  'nOrder'=>7,
					  'tabGroup'=>1,
					  'arrFields'=> $tabFields,
					  'expandSec'=>0);
	$tabFields = array();
$arrAddTabs[] = array('tabId'=>'Opportunity_Analysis1',
					  'tabName'=>"Opportunity Analysis",
					  'nType'=>'0',
					  'nOrder'=>9,
					  'tabGroup'=>1,
					  'arrFields'=> $tabFields,
					  'expandSec'=>0);
$tdataLeads_Management[".arrAddTabs"] = $arrAddTabs;

//fill array of tabs for view page
$arrViewTabs = array();
	$tabFields = array();
$arrViewTabs[] = array('tabId'=>'Address1',
					   'tabName'=>"Address",
					   'nType'=>'1',
					   'nOrder'=>8,
					   'tabGroup'=>0,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
	$tabFields = array();
	$tabFields[] = "Requirement Details";
	$tabFields[] = "Proposed Solution Details";
$arrViewTabs[] = array('tabId'=>'Requirement_Details1',
					   'tabName'=>"Requirement Details",
					   'nType'=>'0',
					   'nOrder'=>14,
					   'tabGroup'=>1,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
	$tabFields = array();
	$tabFields[] = "Employee Name";
	$tabFields[] = "Proposed Closure Date";
	$tabFields[] = "Projected Closure QTR";
	$tabFields[] = "Approx Value";
	$tabFields[] = "Approx Closure Date";
$arrViewTabs[] = array('tabId'=>'Opportunity_Attributes1',
					   'tabName'=>"Opportunity Attributes",
					   'nType'=>'0',
					   'nOrder'=>17,
					   'tabGroup'=>1,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
	$tabFields = array();
	$tabFields[] = "First Quote Remarks";
	$tabFields[] = "Final Quote Remarks";
	$tabFields[] = "Quoted Price";
$arrViewTabs[] = array('tabId'=>'Quote_Details1',
					   'tabName'=>"Quote Details",
					   'nType'=>'0',
					   'nOrder'=>23,
					   'tabGroup'=>1,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
	$tabFields = array();
	$tabFields[] = "Discussion Highlights";
	$tabFields[] = "WIN / Lost Analysis";
$arrViewTabs[] = array('tabId'=>'Opportunity_Analysis1',
					   'tabName'=>"Opportunity Analysis",
					   'nType'=>'0',
					   'nOrder'=>27,
					   'tabGroup'=>1,
					   'arrFields'=> $tabFields,
					   'expandSec'=>0);
$tdataLeads_Management[".arrViewTabs"] = $arrViewTabs;

//fill array of records per page for list and report without group fields
$arrRPP = array();
$arrRPP[] = 10;
$arrRPP[] = 20;
$arrRPP[] = 30;
$arrRPP[] = 50;
$arrRPP[] = 100;
$arrRPP[] = 500;
$arrRPP[] = -1;
$tdataLeads_Management[".arrRecsPerPage"] = $arrRPP;

//fill array of groups per page for report with group fields
$arrGPP = array();
$arrGPP[] = 1;
$arrGPP[] = 3;
$arrGPP[] = 5;
$arrGPP[] = 10;
$arrGPP[] = 50;
$arrGPP[] = 100;
$arrGPP[] = -1;
$tdataLeads_Management[".arrGroupsPerPage"] = $arrGPP;

	$tableKeys = array();
	$tableKeys[] = "Leadid";
	$tdataLeads_Management[".Keys"] = $tableKeys;

//	Leadid
	$fdata = array();
	$fdata["strName"] = "Leadid";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 3;
	
		$fdata["AutoInc"]=true;
	
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Leadid";
	
		$fdata["FullName"]= "lead_table.Leadid";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 1;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		
		
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Leadid"]=$fdata;
//	Region
	$fdata = array();
	$fdata["strName"] = "Region";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Readonly";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Region";
	
		$fdata["FullName"]= "lead_table.Region";
	
		
		
		
		
		
				$fdata["Index"]= 2;
				
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Region"]=$fdata;
//	Customer Name
	$fdata = array();
	$fdata["strName"] = "Customer Name";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Readonly";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Customer_Name";
	
		$fdata["FullName"]= "lead_table.`Customer Name`";
	
		
		
		
		
		
				$fdata["Index"]= 3;
				
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Customer Name"]=$fdata;
//	Contact Person
	$fdata = array();
	$fdata["strName"] = "Contact Person";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Readonly";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Contact_Person";
	
		$fdata["FullName"]= "lead_table.`Contact Person`";
	
		
		
		
		
		
				$fdata["Index"]= 4;
				
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Contact Person"]=$fdata;
//	Lead Details
	$fdata = array();
	$fdata["strName"] = "Lead Details";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "HTML";
	
		
		
		
		
		
	$fdata["GoodName"]= "Lead_Details";
	
		$fdata["FullName"]= "lead_table.`Lead Details`";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 5;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=100";
		$fdata["nRows"] = 100;
			$fdata["EditParams"].= " cols=200";
		$fdata["nCols"] = 200;
		
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Lead Details"]=$fdata;
//	Employee Name
	$fdata = array();
	$fdata["strName"] = "Employee Name";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Lookup wizard";
	$fdata["ViewFormat"]= "";
	
		
		$fdata["LookupType"]=1;
	$fdata["pLookupType"] = 1;
	$fdata["freeInput"] = 0;	
	$fdata["autoCompleteFieldsOnEdit"] = 0;
	$fdata["autoCompleteFields"] = array();
										$fdata["LinkField"]="username";
	$fdata["LinkFieldType"]=200;
	$fdata["DisplayField"]="Full Name";
				$fdata["LookupTable"]="employee_list";
	$fdata["LookupOrderBy"]="Full Name";
																			
					
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Employee_Name";
	
		$fdata["FullName"]= "lead_table.`Employee Name`";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 6;
				
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Employee Name"]=$fdata;
//	Approx Closure Date
	$fdata = array();
	$fdata["strName"] = "Approx Closure Date";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Date";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Approx_Closure_Date";
	
		$fdata["FullName"]= "lead_table.`Approx Closure Date`";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 7;
		$fdata["DateEditType"] = 13; 
	$fdata["InitialYearFactor"] = 0; 
	$fdata["LastYearFactor"] = 10; 
			
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Approx Closure Date"]=$fdata;
//	Lead Status
	$fdata = array();
	$fdata["strName"] = "Lead Status";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Lookup wizard";
	$fdata["ViewFormat"]= "";
	
		
		$fdata["LookupType"]=0;
	$fdata["pLookupType"] = 0;
	$fdata["freeInput"] = 0;	
	$fdata["autoCompleteFieldsOnEdit"] = 0;
	$fdata["autoCompleteFields"] = array();
									$fdata["LookupValues"]=array();
	$fdata["LookupValues"][]="Suspect";
	$fdata["LookupValues"][]="Prospect";
	$fdata["LookupValues"][]="Review";
	$fdata["LookupValues"][]="Hot";
	$fdata["LookupValues"][]="Commit";
	$fdata["LookupValues"][]="Order Received";
	$fdata["LookupValues"][]="Dropped";
	$fdata["LookupValues"][]="Lost";
			
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Lead_Status";
	
		$fdata["FullName"]= "lead_table.`Lead Status`";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 8;
				
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Lead Status"]=$fdata;
//	Requirement Details
	$fdata = array();
	$fdata["strName"] = "Requirement Details";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "HTML";
	
		
		
		
		
		
	$fdata["GoodName"]= "Requirement_Details";
	
		$fdata["FullName"]= "lead_table.`Requirement Details`";
	
		$fdata["IsRequired"]=true; 
	
		$fdata["UseRTE"]=true; 
	
		$fdata["UseRTEBasic"] = true; 
	
		
		
				$fdata["Index"]= 9;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=250";
		$fdata["nRows"] = 250;
			$fdata["EditParams"].= " cols=750";
		$fdata["nCols"] = 750;
		
		
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Requirement Details"]=$fdata;
//	Approx Value
	$fdata = array();
	$fdata["strName"] = "Approx Value";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 3;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Approx_Value";
	
		$fdata["FullName"]= "lead_table.`Approx Value`";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 10;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Approx Value"]=$fdata;
//	First Quote Remarks
	$fdata = array();
	$fdata["strName"] = "First Quote Remarks";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "HTML";
	
		
		
		
		
		
	$fdata["GoodName"]= "First_Quote_Remarks";
	
		$fdata["FullName"]= "lead_table.`First Quote Remarks`";
	
		$fdata["IsRequired"]=true; 
	
		$fdata["UseRTE"]=true; 
	
		$fdata["UseRTEBasic"] = true; 
	
		
		
				$fdata["Index"]= 11;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=250";
		$fdata["nRows"] = 250;
			$fdata["EditParams"].= " cols=750";
		$fdata["nCols"] = 750;
		
		
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["First Quote Remarks"]=$fdata;
//	Proposed Closure Date
	$fdata = array();
	$fdata["strName"] = "Proposed Closure Date";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Date";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Proposed_Closure_Date";
	
		$fdata["FullName"]= "lead_table.`Proposed Closure Date`";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 12;
		$fdata["DateEditType"] = 13; 
	$fdata["InitialYearFactor"] = 0; 
	$fdata["LastYearFactor"] = 10; 
			
		
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Proposed Closure Date"]=$fdata;
//	Projected Closure QTR
	$fdata = array();
	$fdata["strName"] = "Projected Closure QTR";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Lookup wizard";
	$fdata["ViewFormat"]= "";
	
		
		$fdata["LookupType"]=1;
	$fdata["pLookupType"] = 1;
	$fdata["freeInput"] = 0;	
	$fdata["autoCompleteFieldsOnEdit"] = 0;
	$fdata["autoCompleteFields"] = array();
										$fdata["LinkField"]="QTR";
	$fdata["LinkFieldType"]=200;
	$fdata["DisplayField"]="QTR";
				$fdata["LookupTable"]="qtr_name";
	$fdata["LookupOrderBy"]="QTR";
																$fdata["AllowToAdd"]=true; 
				
					
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Projected_Closure_QTR";
	
		$fdata["FullName"]= "lead_table.`Projected Closure QTR`";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 13;
				
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Projected Closure QTR"]=$fdata;
//	Proposed Solution Details
	$fdata = array();
	$fdata["strName"] = "Proposed Solution Details";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "HTML";
	
		
		
		
		
		
	$fdata["GoodName"]= "Proposed_Solution_Details";
	
		$fdata["FullName"]= "lead_table.`Proposed Solution Details`";
	
		$fdata["IsRequired"]=true; 
	
		$fdata["UseRTE"]=true; 
	
		$fdata["UseRTEBasic"] = true; 
	
		
		
				$fdata["Index"]= 14;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=250";
		$fdata["nRows"] = 250;
			$fdata["EditParams"].= " cols=750";
		$fdata["nCols"] = 750;
		
		
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Proposed Solution Details"]=$fdata;
//	Quoted Price
	$fdata = array();
	$fdata["strName"] = "Quoted Price";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 3;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Quoted_Price";
	
		$fdata["FullName"]= "lead_table.`Quoted Price`";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 15;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Quoted Price"]=$fdata;
//	Final Quote Remarks
	$fdata = array();
	$fdata["strName"] = "Final Quote Remarks";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "HTML";
	
		
		
		
		
		
	$fdata["GoodName"]= "Final_Quote_Remarks";
	
		$fdata["FullName"]= "lead_table.`Final Quote Remarks`";
	
		$fdata["IsRequired"]=true; 
	
		$fdata["UseRTE"]=true; 
	
		$fdata["UseRTEBasic"] = true; 
	
		
		
				$fdata["Index"]= 16;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=250";
		$fdata["nRows"] = 250;
			$fdata["EditParams"].= " cols=750";
		$fdata["nCols"] = 750;
		
		
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Final Quote Remarks"]=$fdata;
//	Discussion Highlights
	$fdata = array();
	$fdata["strName"] = "Discussion Highlights";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "HTML";
	
		
		
		
		
		
	$fdata["GoodName"]= "Discussion_Highlights";
	
		$fdata["FullName"]= "lead_table.`Discussion Highlights`";
	
		$fdata["IsRequired"]=true; 
	
		$fdata["UseRTE"]=true; 
	
		$fdata["UseRTEBasic"] = true; 
	
		
		
				$fdata["Index"]= 17;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=250";
		$fdata["nRows"] = 250;
			$fdata["EditParams"].= " cols=750";
		$fdata["nCols"] = 750;
		
		
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Discussion Highlights"]=$fdata;
//	WIN / Lost Analysis
	$fdata = array();
	$fdata["strName"] = "WIN / Lost Analysis";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "HTML";
	
		
		
		
		
		
	$fdata["GoodName"]= "WIN___Lost_Analysis";
	
		$fdata["FullName"]= "lead_table.`WIN / Lost Analysis`";
	
		$fdata["IsRequired"]=true; 
	
		$fdata["UseRTE"]=true; 
	
		$fdata["UseRTEBasic"] = true; 
	
		
		
				$fdata["Index"]= 18;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=250";
		$fdata["nRows"] = 250;
			$fdata["EditParams"].= " cols=750";
		$fdata["nCols"] = 750;
		
		
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["WIN / Lost Analysis"]=$fdata;
//	Alligned Vendor
	$fdata = array();
	$fdata["strName"] = "Alligned Vendor";
	$fdata["ownerTable"] = "lead_table";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Lookup wizard";
	$fdata["ViewFormat"]= "";
	
		
		$fdata["LookupType"]=1;
	$fdata["pLookupType"] = 1;
	$fdata["freeInput"] = 0;	
	$fdata["autoCompleteFieldsOnEdit"] = 0;
	$fdata["autoCompleteFields"] = array();
										$fdata["LinkField"]="Vendor Name";
	$fdata["LinkFieldType"]=200;
	$fdata["DisplayField"]="Vendor Name";
				$fdata["LookupTable"]="vendor_list";
	$fdata["LookupOrderBy"]="Vendor Name";
																			$fdata["SimpleAdd"]=true;
	
					
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Alligned_Vendor";
	
		$fdata["FullName"]= "lead_table.`Alligned Vendor`";
	
		
		
		
		
		
				$fdata["Index"]= 19;
				
		
		
		
		$fdata["bEditPage"]=true; 
	
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Alligned Vendor"]=$fdata;
//	Address
	$fdata = array();
	$fdata["strName"] = "Address";
	$fdata["ownerTable"] = "customer_list";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text area";
	$fdata["ViewFormat"]= "HTML";
	
		
		
		
		
		
	$fdata["GoodName"]= "Address";
	
		$fdata["FullName"]= "customer_list.Address";
	
		
		
		
		
		
				$fdata["Index"]= 20;
			$fdata["EditParams"] = "";
			$fdata["EditParams"].= " rows=100";
		$fdata["nRows"] = 100;
			$fdata["EditParams"].= " cols=200";
		$fdata["nCols"] = 200;
		
		
		
		
		
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Address"]=$fdata;
//	City
	$fdata = array();
	$fdata["strName"] = "City";
	$fdata["ownerTable"] = "customer_list";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "City";
	
		$fdata["FullName"]= "customer_list.City";
	
		
		
		
		
		
				$fdata["Index"]= 21;
				$fdata["EditParams"]="";
			
		
		
		
		
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["City"]=$fdata;
//	State
	$fdata = array();
	$fdata["strName"] = "State";
	$fdata["ownerTable"] = "customer_list";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "State";
	
		$fdata["FullName"]= "customer_list.`State`";
	
		
		
		
		
		
				$fdata["Index"]= 22;
				$fdata["EditParams"]="";
			
		
		
		
		
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["State"]=$fdata;
//	Postal Code
	$fdata = array();
	$fdata["strName"] = "Postal Code";
	$fdata["ownerTable"] = "customer_list";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Postal_Code";
	
		$fdata["FullName"]= "customer_list.`Postal Code`";
	
		
		
		
		
		
				$fdata["Index"]= 23;
				$fdata["EditParams"]="";
			
		
		
		
		
		
		$fdata["bViewPage"]=true; 
	
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataLeads_Management["Postal Code"]=$fdata;

	
$tables_data["Leads-Management"]=&$tdataLeads_Management;
$field_labels["Leads_Management"] = &$fieldLabelsLeads_Management;
$fieldToolTips["Leads-Management"] = &$fieldToolTipsLeads_Management;

// -----------------start  prepare master-details data arrays ------------------------------//
// tables which are detail tables for current table (master)
$detailsTablesData["Leads-Management"] = array();
$dIndex = 1-1;
			$strOriginalDetailsTable="lead_bom";
	$detailsTablesData["Leads-Management"][$dIndex] = array(
		  "dDataSourceTable"=>"Lead-BOM"
		, "dOriginalTable"=>$strOriginalDetailsTable
		, "dShortTable"=>"Lead_BOM"
		, "masterKeys"=>array()
		, "detailKeys"=>array()
		, "dispChildCount"=> "0"
		, "hideChild"=>"0"
		, "sqlHead"=>"SELECT lead_bom.LBOMID,  lead_bom.Lead_ID,  lead_bom.`Material Category`,  lead_bom.`Material Code`,  lead_bom.Quantity,  material_master.List_Price AS Unit_Price,  lead_bom.Quantity*material_master.List_price AS Amonut"	
		, "sqlFrom"=>"FROM lead_bom  INNER JOIN material_master ON lead_bom.`Material Code` = material_master.`Material Code`"	
		, "sqlWhere"=>""
		, "sqlTail"=>""
		, "groupBy"=>"0"
		, "previewOnList" => 1
		, "previewOnAdd" => 1
		, "previewOnEdit" => 1
		, "previewOnView" => 1
	);	
		$detailsTablesData["Leads-Management"][$dIndex]["masterKeys"][]="Leadid";
		$detailsTablesData["Leads-Management"][$dIndex]["detailKeys"][]="Lead_ID";

$dIndex = 2-1;
			$strOriginalDetailsTable="lead_bom";
	$detailsTablesData["Leads-Management"][$dIndex] = array(
		  "dDataSourceTable"=>"Quote"
		, "dOriginalTable"=>$strOriginalDetailsTable
		, "dShortTable"=>"Quote"
		, "masterKeys"=>array()
		, "detailKeys"=>array()
		, "dispChildCount"=> "0"
		, "hideChild"=>"1"
		, "sqlHead"=>"SELECT lead_bom.LBOMID,  lead_bom.Lead_ID,  lead_bom.`Material Code`,  lead_bom.Quantity,  material_master.List_Price AS Unit_Price,  lead_bom.Quantity*material_master.List_price AS Amonut,  material_master.Tax AS `Tax %`,  (lead_bom.Quantity*material_master.List_price)*(material_master.Tax/100)+(lead_bom.Quantity*material_master.List_price) AS `Ext. Amount`,  material_master.Specification"	
		, "sqlFrom"=>"FROM lead_bom  INNER JOIN material_master ON lead_bom.`Material Code` = material_master.`Material Code`"	
		, "sqlWhere"=>""
		, "sqlTail"=>""
		, "groupBy"=>"0"
		, "previewOnList" => 0
		, "previewOnAdd" => 0
		, "previewOnEdit" => 0
		, "previewOnView" => 0
	);	
		$detailsTablesData["Leads-Management"][$dIndex]["masterKeys"][]="Leadid";
		$detailsTablesData["Leads-Management"][$dIndex]["detailKeys"][]="Lead_ID";

$dIndex = 3-1;
			$strOriginalDetailsTable="lead_bom";
	$detailsTablesData["Leads-Management"][$dIndex] = array(
		  "dDataSourceTable"=>"SPC_Req"
		, "dOriginalTable"=>$strOriginalDetailsTable
		, "dShortTable"=>"SPC_Req"
		, "masterKeys"=>array()
		, "detailKeys"=>array()
		, "dispChildCount"=> "0"
		, "hideChild"=>"1"
		, "sqlHead"=>"SELECT lead_bom.LBOMID,  lead_bom.Lead_ID,  lead_bom.`Material Category`,  lead_bom.`Material Code`,  lead_bom.Quantity,  lead_bom.SPC_REQ_BY,  lead_bom.Target_Price,  lead_bom.SPC_Status,  material_master.List_Price AS `Unit Price`,  lead_bom.Quantity*material_master.List_price AS Amount,  lead_bom.Quantity*lead_bom.Target_Price AS `Target Amt`"	
		, "sqlFrom"=>"FROM lead_bom  INNER JOIN material_master ON lead_bom.`Material Code` = material_master.`Material Code`"	
		, "sqlWhere"=>""
		, "sqlTail"=>""
		, "groupBy"=>"0"
		, "previewOnList" => 0
		, "previewOnAdd" => 0
		, "previewOnEdit" => 0
		, "previewOnView" => 0
	);	
		$detailsTablesData["Leads-Management"][$dIndex]["masterKeys"][]="Leadid";
		$detailsTablesData["Leads-Management"][$dIndex]["detailKeys"][]="Lead_ID";

$dIndex = 4-1;
			$strOriginalDetailsTable="lead_bom";
	$detailsTablesData["Leads-Management"][$dIndex] = array(
		  "dDataSourceTable"=>"SPC__Quote"
		, "dOriginalTable"=>$strOriginalDetailsTable
		, "dShortTable"=>"SPC__Quote"
		, "masterKeys"=>array()
		, "detailKeys"=>array()
		, "dispChildCount"=> "0"
		, "hideChild"=>"1"
		, "sqlHead"=>"SELECT lead_bom.LBOMID,  lead_bom.Lead_ID,  lead_bom.`Material Code`,  lead_bom.Quantity,  lead_bom.Special_Price AS Unit_Price,  lead_bom.Quantity*lead_bom.Special_Price AS Amonut,  material_master.Tax AS `Tax %`,  (lead_bom.Quantity*lead_bom.Special_Price)*(material_master.Tax/100)+(lead_bom.Quantity*lead_bom.Special_Price) AS `Ext. Amount`,  material_master.Specification"	
		, "sqlFrom"=>"FROM lead_bom  INNER JOIN material_master ON lead_bom.`Material Code` = material_master.`Material Code`"	
		, "sqlWhere"=>""
		, "sqlTail"=>""
		, "groupBy"=>"0"
		, "previewOnList" => 0
		, "previewOnAdd" => 0
		, "previewOnEdit" => 0
		, "previewOnView" => 0
	);	
		$detailsTablesData["Leads-Management"][$dIndex]["masterKeys"][]="Leadid";
		$detailsTablesData["Leads-Management"][$dIndex]["detailKeys"][]="Lead_ID";


	
// tables which are master tables for current table (detail)
$masterTablesData["Leads-Management"] = array();

// -----------------end  prepare master-details data arrays ------------------------------//

require_once(getabspath("classes/sql.php"));










$proto400=array();
$proto400["m_strHead"] = "SELECT";
$proto400["m_strFieldList"] = "lead_table.Leadid,  lead_table.Region,  lead_table.`Customer Name`,  lead_table.`Contact Person`,  lead_table.`Lead Details`,  lead_table.`Employee Name`,  lead_table.`Approx Closure Date`,  lead_table.`Lead Status`,  lead_table.`Requirement Details`,  lead_table.`Approx Value`,  lead_table.`First Quote Remarks`,  lead_table.`Proposed Closure Date`,  lead_table.`Projected Closure QTR`,  lead_table.`Proposed Solution Details`,  lead_table.`Quoted Price`,  lead_table.`Final Quote Remarks`,  lead_table.`Discussion Highlights`,  lead_table.`WIN / Lost Analysis`,  lead_table.`Alligned Vendor`,  customer_list.Address,  customer_list.City,  customer_list.`State`,  customer_list.`Postal Code`";
$proto400["m_strFrom"] = "FROM lead_table  INNER JOIN customer_list ON lead_table.`Customer Name` = customer_list.`Customer Name`";
$proto400["m_strWhere"] = "lead_table.`Lead Status` ='Suspect' OR lead_table.`Lead Status` ='prospect' OR lead_table.`Lead Status` ='Review' OR lead_table.`Lead Status` ='Hot' OR lead_table.`Lead Status` ='Commit'";
$proto400["m_strOrderBy"] = "ORDER BY lead_table.`Approx Closure Date`, lead_table.`Lead Status`";
$proto400["m_strTail"] = "";
$proto401=array();
$proto401["m_sql"] = "lead_table.`Lead Status` ='Suspect' OR lead_table.`Lead Status` ='prospect' OR lead_table.`Lead Status` ='Review' OR lead_table.`Lead Status` ='Hot' OR lead_table.`Lead Status` ='Commit'";
$proto401["m_uniontype"] = "SQLL_OR";
	$obj = new SQLNonParsed(array(
	"m_sql" => "lead_table.`Lead Status` ='Suspect' OR lead_table.`Lead Status` ='prospect' OR lead_table.`Lead Status` ='Review' OR lead_table.`Lead Status` ='Hot' OR lead_table.`Lead Status` ='Commit'"
));

$proto401["m_column"]=$obj;
$proto401["m_contained"] = array();
						$proto403=array();
$proto403["m_sql"] = "lead_table.`Lead Status` ='Suspect'";
$proto403["m_uniontype"] = "SQLL_UNKNOWN";
						$obj = new SQLField(array(
	"m_strName" => "Lead Status",
	"m_strTable" => "lead_table"
));

$proto403["m_column"]=$obj;
$proto403["m_contained"] = array();
$proto403["m_strCase"] = "='Suspect'";
$proto403["m_havingmode"] = "0";
$proto403["m_inBrackets"] = "0";
$proto403["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto403);

			$proto401["m_contained"][]=$obj;
						$proto405=array();
$proto405["m_sql"] = "lead_table.`Lead Status` ='prospect'";
$proto405["m_uniontype"] = "SQLL_UNKNOWN";
						$obj = new SQLField(array(
	"m_strName" => "Lead Status",
	"m_strTable" => "lead_table"
));

$proto405["m_column"]=$obj;
$proto405["m_contained"] = array();
$proto405["m_strCase"] = "='prospect'";
$proto405["m_havingmode"] = "0";
$proto405["m_inBrackets"] = "0";
$proto405["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto405);

			$proto401["m_contained"][]=$obj;
						$proto407=array();
$proto407["m_sql"] = "lead_table.`Lead Status` ='Review'";
$proto407["m_uniontype"] = "SQLL_UNKNOWN";
						$obj = new SQLField(array(
	"m_strName" => "Lead Status",
	"m_strTable" => "lead_table"
));

$proto407["m_column"]=$obj;
$proto407["m_contained"] = array();
$proto407["m_strCase"] = "='Review'";
$proto407["m_havingmode"] = "0";
$proto407["m_inBrackets"] = "0";
$proto407["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto407);

			$proto401["m_contained"][]=$obj;
						$proto409=array();
$proto409["m_sql"] = "lead_table.`Lead Status` ='Hot'";
$proto409["m_uniontype"] = "SQLL_UNKNOWN";
						$obj = new SQLField(array(
	"m_strName" => "Lead Status",
	"m_strTable" => "lead_table"
));

$proto409["m_column"]=$obj;
$proto409["m_contained"] = array();
$proto409["m_strCase"] = "='Hot'";
$proto409["m_havingmode"] = "0";
$proto409["m_inBrackets"] = "0";
$proto409["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto409);

			$proto401["m_contained"][]=$obj;
						$proto411=array();
$proto411["m_sql"] = "lead_table.`Lead Status` ='Commit'";
$proto411["m_uniontype"] = "SQLL_UNKNOWN";
						$obj = new SQLField(array(
	"m_strName" => "Lead Status",
	"m_strTable" => "lead_table"
));

$proto411["m_column"]=$obj;
$proto411["m_contained"] = array();
$proto411["m_strCase"] = "='Commit'";
$proto411["m_havingmode"] = "0";
$proto411["m_inBrackets"] = "0";
$proto411["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto411);

			$proto401["m_contained"][]=$obj;
$proto401["m_strCase"] = "";
$proto401["m_havingmode"] = "0";
$proto401["m_inBrackets"] = "0";
$proto401["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto401);

$proto400["m_where"] = $obj;
$proto413=array();
$proto413["m_sql"] = "";
$proto413["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto413["m_column"]=$obj;
$proto413["m_contained"] = array();
$proto413["m_strCase"] = "";
$proto413["m_havingmode"] = "0";
$proto413["m_inBrackets"] = "0";
$proto413["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto413);

$proto400["m_having"] = $obj;
$proto400["m_fieldlist"] = array();
						$proto415=array();
			$obj = new SQLField(array(
	"m_strName" => "Leadid",
	"m_strTable" => "lead_table"
));

$proto415["m_expr"]=$obj;
$proto415["m_alias"] = "";
$obj = new SQLFieldListItem($proto415);

$proto400["m_fieldlist"][]=$obj;
						$proto417=array();
			$obj = new SQLField(array(
	"m_strName" => "Region",
	"m_strTable" => "lead_table"
));

$proto417["m_expr"]=$obj;
$proto417["m_alias"] = "";
$obj = new SQLFieldListItem($proto417);

$proto400["m_fieldlist"][]=$obj;
						$proto419=array();
			$obj = new SQLField(array(
	"m_strName" => "Customer Name",
	"m_strTable" => "lead_table"
));

$proto419["m_expr"]=$obj;
$proto419["m_alias"] = "";
$obj = new SQLFieldListItem($proto419);

$proto400["m_fieldlist"][]=$obj;
						$proto421=array();
			$obj = new SQLField(array(
	"m_strName" => "Contact Person",
	"m_strTable" => "lead_table"
));

$proto421["m_expr"]=$obj;
$proto421["m_alias"] = "";
$obj = new SQLFieldListItem($proto421);

$proto400["m_fieldlist"][]=$obj;
						$proto423=array();
			$obj = new SQLField(array(
	"m_strName" => "Lead Details",
	"m_strTable" => "lead_table"
));

$proto423["m_expr"]=$obj;
$proto423["m_alias"] = "";
$obj = new SQLFieldListItem($proto423);

$proto400["m_fieldlist"][]=$obj;
						$proto425=array();
			$obj = new SQLField(array(
	"m_strName" => "Employee Name",
	"m_strTable" => "lead_table"
));

$proto425["m_expr"]=$obj;
$proto425["m_alias"] = "";
$obj = new SQLFieldListItem($proto425);

$proto400["m_fieldlist"][]=$obj;
						$proto427=array();
			$obj = new SQLField(array(
	"m_strName" => "Approx Closure Date",
	"m_strTable" => "lead_table"
));

$proto427["m_expr"]=$obj;
$proto427["m_alias"] = "";
$obj = new SQLFieldListItem($proto427);

$proto400["m_fieldlist"][]=$obj;
						$proto429=array();
			$obj = new SQLField(array(
	"m_strName" => "Lead Status",
	"m_strTable" => "lead_table"
));

$proto429["m_expr"]=$obj;
$proto429["m_alias"] = "";
$obj = new SQLFieldListItem($proto429);

$proto400["m_fieldlist"][]=$obj;
						$proto431=array();
			$obj = new SQLField(array(
	"m_strName" => "Requirement Details",
	"m_strTable" => "lead_table"
));

$proto431["m_expr"]=$obj;
$proto431["m_alias"] = "";
$obj = new SQLFieldListItem($proto431);

$proto400["m_fieldlist"][]=$obj;
						$proto433=array();
			$obj = new SQLField(array(
	"m_strName" => "Approx Value",
	"m_strTable" => "lead_table"
));

$proto433["m_expr"]=$obj;
$proto433["m_alias"] = "";
$obj = new SQLFieldListItem($proto433);

$proto400["m_fieldlist"][]=$obj;
						$proto435=array();
			$obj = new SQLField(array(
	"m_strName" => "First Quote Remarks",
	"m_strTable" => "lead_table"
));

$proto435["m_expr"]=$obj;
$proto435["m_alias"] = "";
$obj = new SQLFieldListItem($proto435);

$proto400["m_fieldlist"][]=$obj;
						$proto437=array();
			$obj = new SQLField(array(
	"m_strName" => "Proposed Closure Date",
	"m_strTable" => "lead_table"
));

$proto437["m_expr"]=$obj;
$proto437["m_alias"] = "";
$obj = new SQLFieldListItem($proto437);

$proto400["m_fieldlist"][]=$obj;
						$proto439=array();
			$obj = new SQLField(array(
	"m_strName" => "Projected Closure QTR",
	"m_strTable" => "lead_table"
));

$proto439["m_expr"]=$obj;
$proto439["m_alias"] = "";
$obj = new SQLFieldListItem($proto439);

$proto400["m_fieldlist"][]=$obj;
						$proto441=array();
			$obj = new SQLField(array(
	"m_strName" => "Proposed Solution Details",
	"m_strTable" => "lead_table"
));

$proto441["m_expr"]=$obj;
$proto441["m_alias"] = "";
$obj = new SQLFieldListItem($proto441);

$proto400["m_fieldlist"][]=$obj;
						$proto443=array();
			$obj = new SQLField(array(
	"m_strName" => "Quoted Price",
	"m_strTable" => "lead_table"
));

$proto443["m_expr"]=$obj;
$proto443["m_alias"] = "";
$obj = new SQLFieldListItem($proto443);

$proto400["m_fieldlist"][]=$obj;
						$proto445=array();
			$obj = new SQLField(array(
	"m_strName" => "Final Quote Remarks",
	"m_strTable" => "lead_table"
));

$proto445["m_expr"]=$obj;
$proto445["m_alias"] = "";
$obj = new SQLFieldListItem($proto445);

$proto400["m_fieldlist"][]=$obj;
						$proto447=array();
			$obj = new SQLField(array(
	"m_strName" => "Discussion Highlights",
	"m_strTable" => "lead_table"
));

$proto447["m_expr"]=$obj;
$proto447["m_alias"] = "";
$obj = new SQLFieldListItem($proto447);

$proto400["m_fieldlist"][]=$obj;
						$proto449=array();
			$obj = new SQLField(array(
	"m_strName" => "WIN / Lost Analysis",
	"m_strTable" => "lead_table"
));

$proto449["m_expr"]=$obj;
$proto449["m_alias"] = "";
$obj = new SQLFieldListItem($proto449);

$proto400["m_fieldlist"][]=$obj;
						$proto451=array();
			$obj = new SQLField(array(
	"m_strName" => "Alligned Vendor",
	"m_strTable" => "lead_table"
));

$proto451["m_expr"]=$obj;
$proto451["m_alias"] = "";
$obj = new SQLFieldListItem($proto451);

$proto400["m_fieldlist"][]=$obj;
						$proto453=array();
			$obj = new SQLField(array(
	"m_strName" => "Address",
	"m_strTable" => "customer_list"
));

$proto453["m_expr"]=$obj;
$proto453["m_alias"] = "";
$obj = new SQLFieldListItem($proto453);

$proto400["m_fieldlist"][]=$obj;
						$proto455=array();
			$obj = new SQLField(array(
	"m_strName" => "City",
	"m_strTable" => "customer_list"
));

$proto455["m_expr"]=$obj;
$proto455["m_alias"] = "";
$obj = new SQLFieldListItem($proto455);

$proto400["m_fieldlist"][]=$obj;
						$proto457=array();
			$obj = new SQLField(array(
	"m_strName" => "State",
	"m_strTable" => "customer_list"
));

$proto457["m_expr"]=$obj;
$proto457["m_alias"] = "";
$obj = new SQLFieldListItem($proto457);

$proto400["m_fieldlist"][]=$obj;
						$proto459=array();
			$obj = new SQLField(array(
	"m_strName" => "Postal Code",
	"m_strTable" => "customer_list"
));

$proto459["m_expr"]=$obj;
$proto459["m_alias"] = "";
$obj = new SQLFieldListItem($proto459);

$proto400["m_fieldlist"][]=$obj;
$proto400["m_fromlist"] = array();
												$proto461=array();
$proto461["m_link"] = "SQLL_MAIN";
			$proto462=array();
$proto462["m_strName"] = "lead_table";
$proto462["m_columns"] = array();
$proto462["m_columns"][] = "Leadid";
$proto462["m_columns"][] = "Region";
$proto462["m_columns"][] = "Customer Name";
$proto462["m_columns"][] = "Contact Person";
$proto462["m_columns"][] = "Lead Details";
$proto462["m_columns"][] = "Employee Name";
$proto462["m_columns"][] = "Approx Closure Date";
$proto462["m_columns"][] = "Lead Status";
$proto462["m_columns"][] = "Manager Name";
$proto462["m_columns"][] = "Manager Remarks";
$proto462["m_columns"][] = "Sales Call Status";
$proto462["m_columns"][] = "Lead Level";
$proto462["m_columns"][] = "Requirement Details";
$proto462["m_columns"][] = "Approx Value";
$proto462["m_columns"][] = "First Quote Remarks";
$proto462["m_columns"][] = "Proposed Closure Date";
$proto462["m_columns"][] = "Projected Closure QTR";
$proto462["m_columns"][] = "Proposed Solution Details";
$proto462["m_columns"][] = "Quoted Price";
$proto462["m_columns"][] = "Final Quote Remarks";
$proto462["m_columns"][] = "Discussion Highlights";
$proto462["m_columns"][] = "WIN / Lost Analysis";
$proto462["m_columns"][] = "Alligned Vendor";
$obj = new SQLTable($proto462);

$proto461["m_table"] = $obj;
$proto461["m_alias"] = "";
$proto463=array();
$proto463["m_sql"] = "";
$proto463["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto463["m_column"]=$obj;
$proto463["m_contained"] = array();
$proto463["m_strCase"] = "";
$proto463["m_havingmode"] = "0";
$proto463["m_inBrackets"] = "0";
$proto463["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto463);

$proto461["m_joinon"] = $obj;
$obj = new SQLFromListItem($proto461);

$proto400["m_fromlist"][]=$obj;
												$proto465=array();
$proto465["m_link"] = "SQLL_INNERJOIN";
			$proto466=array();
$proto466["m_strName"] = "customer_list";
$proto466["m_columns"] = array();
$proto466["m_columns"][] = "idCL";
$proto466["m_columns"][] = "Created on";
$proto466["m_columns"][] = "Region";
$proto466["m_columns"][] = "Customer Name";
$proto466["m_columns"][] = "Address";
$proto466["m_columns"][] = "City";
$proto466["m_columns"][] = "State";
$proto466["m_columns"][] = "Country";
$proto466["m_columns"][] = "Postal Code";
$proto466["m_columns"][] = "Web address";
$proto466["m_columns"][] = "Area";
$proto466["m_columns"][] = "Customer_Category";
$proto466["m_columns"][] = "Breif About the Company";
$proto466["m_columns"][] = "Existing Setup";
$proto466["m_columns"][] = "Interaction Summary";
$proto466["m_columns"][] = "Commercial Summary";
$proto466["m_columns"][] = "Customer Status";
$proto466["m_columns"][] = "Assigned Executive";
$proto466["m_columns"][] = "Assigned Date";
$proto466["m_columns"][] = "Last Updated on";
$proto466["m_columns"][] = "Aligned Partner";
$obj = new SQLTable($proto466);

$proto465["m_table"] = $obj;
$proto465["m_alias"] = "";
$proto467=array();
$proto467["m_sql"] = "lead_table.`Customer Name` = customer_list.`Customer Name`";
$proto467["m_uniontype"] = "SQLL_UNKNOWN";
						$obj = new SQLField(array(
	"m_strName" => "Customer Name",
	"m_strTable" => "lead_table"
));

$proto467["m_column"]=$obj;
$proto467["m_contained"] = array();
$proto467["m_strCase"] = "= customer_list.`Customer Name`";
$proto467["m_havingmode"] = "0";
$proto467["m_inBrackets"] = "0";
$proto467["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto467);

$proto465["m_joinon"] = $obj;
$obj = new SQLFromListItem($proto465);

$proto400["m_fromlist"][]=$obj;
$proto400["m_groupby"] = array();
$proto400["m_orderby"] = array();
												$proto469=array();
						$obj = new SQLField(array(
	"m_strName" => "Approx Closure Date",
	"m_strTable" => "lead_table"
));

$proto469["m_column"]=$obj;
$proto469["m_bAsc"] = 1;
$proto469["m_nColumn"] = 0;
$obj = new SQLOrderByItem($proto469);

$proto400["m_orderby"][]=$obj;					
												$proto471=array();
						$obj = new SQLField(array(
	"m_strName" => "Lead Status",
	"m_strTable" => "lead_table"
));

$proto471["m_column"]=$obj;
$proto471["m_bAsc"] = 1;
$proto471["m_nColumn"] = 0;
$obj = new SQLOrderByItem($proto471);

$proto400["m_orderby"][]=$obj;					
$obj = new SQLQuery($proto400);

$queryData_Leads_Management = $obj;
$tdataLeads_Management[".sqlquery"] = $queryData_Leads_Management;

include(getabspath("include/Leads_Management_events.php"));
$tableEvents["Leads-Management"] = new eventclass_Leads_Management;

?>
