<?php
$tdataRO_Customer_List_Summary=array();
	$tdataRO_Customer_List_Summary[".NumberOfChars"]=80; 
	$tdataRO_Customer_List_Summary[".ShortName"]="RO_Customer_List_Summary";
	$tdataRO_Customer_List_Summary[".OwnerID"]="";
	$tdataRO_Customer_List_Summary[".OriginalTable"]="area";


	
//	field labels
$fieldLabelsRO_Customer_List_Summary = array();
if(mlang_getcurrentlang()=="English")
{
	$fieldLabelsRO_Customer_List_Summary["English"]=array();
	$fieldToolTipsRO_Customer_List_Summary["English"]=array();
	$fieldLabelsRO_Customer_List_Summary["English"]["Region"] = "Region";
	$fieldToolTipsRO_Customer_List_Summary["English"]["Region"] = "";
	$fieldLabelsRO_Customer_List_Summary["English"]["Nos"] = "Nos";
	$fieldToolTipsRO_Customer_List_Summary["English"]["Nos"] = "";
	$fieldLabelsRO_Customer_List_Summary["English"]["Customer_Status"] = "Customer Status";
	$fieldToolTipsRO_Customer_List_Summary["English"]["Customer Status"] = "";
	if (count($fieldToolTipsRO_Customer_List_Summary["English"])){
		$tdataRO_Customer_List_Summary[".isUseToolTips"]=true;
	}
}


	
	$tdataRO_Customer_List_Summary[".NCSearch"]=true;

	

$tdataRO_Customer_List_Summary[".shortTableName"] = "RO_Customer_List_Summary";
$tdataRO_Customer_List_Summary[".nSecOptions"] = 0;
$tdataRO_Customer_List_Summary[".recsPerRowList"] = 1;	
$tdataRO_Customer_List_Summary[".tableGroupBy"] = "1";
$tdataRO_Customer_List_Summary[".mainTableOwnerID"] = "";
$tdataRO_Customer_List_Summary[".moveNext"] = 1;




$tdataRO_Customer_List_Summary[".showAddInPopup"] = false;

$tdataRO_Customer_List_Summary[".showEditInPopup"] = false;

$tdataRO_Customer_List_Summary[".showViewInPopup"] = false;


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

$tdataRO_Customer_List_Summary[".listAjax"] = false;

	$tdataRO_Customer_List_Summary[".audit"] = false;

	$tdataRO_Customer_List_Summary[".locking"] = false;
	
$tdataRO_Customer_List_Summary[".listIcons"] = true;




$tdataRO_Customer_List_Summary[".showSimpleSearchOptions"] = false;

$tdataRO_Customer_List_Summary[".showSearchPanel"] = true;


$tdataRO_Customer_List_Summary[".isUseAjaxSuggest"] = true;

$tdataRO_Customer_List_Summary[".rowHighlite"] = true;


// button handlers file names

$tdataRO_Customer_List_Summary[".addPageEvents"] = false;


// use datepicker for search panel
$tdataRO_Customer_List_Summary[".isUseCalendarForSearch"] = false;

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

$tdataRO_Customer_List_Summary[".isUseiBox"] = false;




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

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

$tdataRO_Customer_List_Summary[".globSearchFields"][] = "Nos";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Nos", $tdataRO_Customer_List_Summary[".allSearchFields"]))
{
	$tdataRO_Customer_List_Summary[".allSearchFields"][] = "Nos";	
}
$tdataRO_Customer_List_Summary[".globSearchFields"][] = "Customer 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("Customer Status", $tdataRO_Customer_List_Summary[".allSearchFields"]))
{
	$tdataRO_Customer_List_Summary[".allSearchFields"][] = "Customer Status";	
}


$tdataRO_Customer_List_Summary[".googleLikeFields"][] = "Nos";
$tdataRO_Customer_List_Summary[".googleLikeFields"][] = "Region";
$tdataRO_Customer_List_Summary[".googleLikeFields"][] = "Customer Status";



$tdataRO_Customer_List_Summary[".advSearchFields"][] = "Nos";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("Nos", $tdataRO_Customer_List_Summary[".allSearchFields"])) 
{
	$tdataRO_Customer_List_Summary[".allSearchFields"][] = "Nos";	
}
$tdataRO_Customer_List_Summary[".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", $tdataRO_Customer_List_Summary[".allSearchFields"])) 
{
	$tdataRO_Customer_List_Summary[".allSearchFields"][] = "Region";	
}
$tdataRO_Customer_List_Summary[".advSearchFields"][] = "Customer 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("Customer Status", $tdataRO_Customer_List_Summary[".allSearchFields"])) 
{
	$tdataRO_Customer_List_Summary[".allSearchFields"][] = "Customer Status";	
}

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


	

$tdataRO_Customer_List_Summary[".isDisplayLoading"] = true;

$tdataRO_Customer_List_Summary[".isResizeColumns"] = false;





$tdataRO_Customer_List_Summary[".pageSize"] = 20;

$gstrOrderBy = "";
if(strlen($gstrOrderBy) && strtolower(substr($gstrOrderBy,0,8))!="order by")
	$gstrOrderBy = "order by ".$gstrOrderBy;
$tdataRO_Customer_List_Summary[".strOrderBy"] = $gstrOrderBy;
	
$tdataRO_Customer_List_Summary[".orderindexes"] = array();

$tdataRO_Customer_List_Summary[".sqlHead"] = "SELECT COUNT(idCL) AS Nos,  Region,  `Customer Status`";
$tdataRO_Customer_List_Summary[".sqlFrom"] = "FROM customer_list";
$tdataRO_Customer_List_Summary[".sqlWhereExpr"] = "";
$tdataRO_Customer_List_Summary[".sqlTail"] = "GROUP BY Region, `Customer Status`";




//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;
$tdataRO_Customer_List_Summary[".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;
$tdataRO_Customer_List_Summary[".arrGroupsPerPage"] = $arrGPP;

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

//	Nos
	$fdata = array();
	$fdata["strName"] = "Nos";
	$fdata["ownerTable"] = "";
		
		
		
	$fdata["FieldType"]= 3;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Nos";
	
		$fdata["FullName"]= "COUNT(idCL)";
	
		
		
		
		
		
				$fdata["Index"]= 1;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		
		
		
		
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataRO_Customer_List_Summary["Nos"]=$fdata;
//	Region
	$fdata = array();
	$fdata["strName"] = "Region";
	$fdata["ownerTable"] = "customer_list";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Region";
	
		$fdata["FullName"]= "Region";
	
		
		
		
		
		
				$fdata["Index"]= 2;
				$fdata["EditParams"]="";
			$fdata["EditParams"].= " maxlength=50";
		
		
		
		
		
		
		
		
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				
		
				
		
		
		
			$tdataRO_Customer_List_Summary["Region"]=$fdata;
//	Customer Status
	$fdata = array();
	$fdata["strName"] = "Customer Status";
	$fdata["ownerTable"] = "customer_list";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Customer_Status";
	
		$fdata["FullName"]= "`Customer Status`";
	
		
		
		
		
		
				$fdata["Index"]= 3;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		
		
		
		
		$fdata["bAdvancedSearch"]=true; 
	
		
		
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataRO_Customer_List_Summary["Customer Status"]=$fdata;

	
$tables_data["RO-Customer List Summary"]=&$tdataRO_Customer_List_Summary;
$field_labels["RO_Customer_List_Summary"] = &$fieldLabelsRO_Customer_List_Summary;
$fieldToolTips["RO-Customer List Summary"] = &$fieldToolTipsRO_Customer_List_Summary;

// -----------------start  prepare master-details data arrays ------------------------------//
// tables which are detail tables for current table (master)
$detailsTablesData["RO-Customer List Summary"] = array();

	
// tables which are master tables for current table (detail)
$masterTablesData["RO-Customer List Summary"] = array();

$mIndex = 1-1;
			$strOriginalDetailsTable="employee_list";
	$masterTablesData["RO-Customer List Summary"][$mIndex] = array(
		  "mDataSourceTable"=>"My Home"
		, "mOriginalTable" => $strOriginalDetailsTable
		, "mShortTable" => "My_Home"
		, "masterKeys" => array()
		, "detailKeys" => array()
		, "dispChildCount" => "1"
		, "hideChild" => "0"	
		, "dispInfo" => "1"								
		, "previewOnList" => 1
		, "previewOnAdd" => 0
		, "previewOnEdit" => 0
		, "previewOnView" => 1
	);	
		$masterTablesData["RO-Customer List Summary"][$mIndex]["masterKeys"][]="Region";
		$masterTablesData["RO-Customer List Summary"][$mIndex]["detailKeys"][]="Region";

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

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










$proto233=array();
$proto233["m_strHead"] = "SELECT";
$proto233["m_strFieldList"] = "COUNT(idCL) AS Nos,  Region,  `Customer Status`";
$proto233["m_strFrom"] = "FROM customer_list";
$proto233["m_strWhere"] = "";
$proto233["m_strOrderBy"] = "";
$proto233["m_strTail"] = "GROUP BY Region, `Customer Status`";
$proto234=array();
$proto234["m_sql"] = "";
$proto234["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

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

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

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

$proto233["m_having"] = $obj;
$proto233["m_fieldlist"] = array();
						$proto238=array();
			$proto239=array();
$proto239["m_functiontype"] = "SQLF_COUNT";
$proto239["m_arguments"] = array();
						$obj = new SQLField(array(
	"m_strName" => "idCL",
	"m_strTable" => "customer_list"
));

$proto239["m_arguments"][]=$obj;
$proto239["m_strFunctionName"] = "COUNT";
$obj = new SQLFunctionCall($proto239);

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

$proto233["m_fieldlist"][]=$obj;
						$proto241=array();
			$obj = new SQLField(array(
	"m_strName" => "Region",
	"m_strTable" => "customer_list"
));

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

$proto233["m_fieldlist"][]=$obj;
						$proto243=array();
			$obj = new SQLField(array(
	"m_strName" => "Customer Status",
	"m_strTable" => "customer_list"
));

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

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

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

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

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

$proto233["m_fromlist"][]=$obj;
$proto233["m_groupby"] = array();
												$proto249=array();
						$obj = new SQLField(array(
	"m_strName" => "Region",
	"m_strTable" => "customer_list"
));

$proto249["m_column"]=$obj;
$obj = new SQLGroupByItem($proto249);

$proto233["m_groupby"][]=$obj;
												$proto251=array();
						$obj = new SQLField(array(
	"m_strName" => "Customer Status",
	"m_strTable" => "customer_list"
));

$proto251["m_column"]=$obj;
$obj = new SQLGroupByItem($proto251);

$proto233["m_groupby"][]=$obj;
$proto233["m_orderby"] = array();
$obj = new SQLQuery($proto233);

$queryData_RO_Customer_List_Summary = $obj;
$tdataRO_Customer_List_Summary[".sqlquery"] = $queryData_RO_Customer_List_Summary;

$tableEvents["RO-Customer List Summary"] = new eventsBase;

?>
