<?php
$tdataCalls_Summary=array();
	$tdataCalls_Summary[".NumberOfChars"]=80; 
	$tdataCalls_Summary[".ShortName"]="Calls_Summary";
	$tdataCalls_Summary[".OwnerID"]="Region";
	$tdataCalls_Summary[".OriginalTable"]="calls";


	
//	field labels
$fieldLabelsCalls_Summary = array();
if(mlang_getcurrentlang()=="English")
{
	$fieldLabelsCalls_Summary["English"]=array();
	$fieldToolTipsCalls_Summary["English"]=array();
	$fieldLabelsCalls_Summary["English"]["Date"] = "Date";
	$fieldToolTipsCalls_Summary["English"]["Date"] = "";
	$fieldLabelsCalls_Summary["English"]["Executive_Name"] = "Executive Name";
	$fieldToolTipsCalls_Summary["English"]["Executive Name"] = "";
	$fieldLabelsCalls_Summary["English"]["COUNT"] = "COUNT";
	$fieldToolTipsCalls_Summary["English"]["COUNT"] = "";
	$fieldLabelsCalls_Summary["English"]["Customer_Status"] = "Customer Status";
	$fieldToolTipsCalls_Summary["English"]["Customer Status"] = "";
	$fieldLabelsCalls_Summary["English"]["Region"] = "Region";
	$fieldToolTipsCalls_Summary["English"]["Region"] = "";
	if (count($fieldToolTipsCalls_Summary["English"])){
		$tdataCalls_Summary[".isUseToolTips"]=true;
	}
}


	
	$tdataCalls_Summary[".NCSearch"]=true;

	

$tdataCalls_Summary[".shortTableName"] = "Calls_Summary";
$tdataCalls_Summary[".nSecOptions"] = 1;
$tdataCalls_Summary[".recsPerRowList"] = 1;	
$tdataCalls_Summary[".tableGroupBy"] = "1";
$tdataCalls_Summary[".mainTableOwnerID"] = "Region";
$tdataCalls_Summary[".moveNext"] = 1;




$tdataCalls_Summary[".showAddInPopup"] = false;

$tdataCalls_Summary[".showEditInPopup"] = false;

$tdataCalls_Summary[".showViewInPopup"] = false;


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

$tdataCalls_Summary[".listAjax"] = false;

	$tdataCalls_Summary[".audit"] = false;

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

$tdataCalls_Summary[".exportTo"] = true;

$tdataCalls_Summary[".printFriendly"] = true;

$tdataCalls_Summary[".delete"] = true;

$tdataCalls_Summary[".showSimpleSearchOptions"] = false;

$tdataCalls_Summary[".showSearchPanel"] = true;


$tdataCalls_Summary[".isUseAjaxSuggest"] = true;



// button handlers file names

$tdataCalls_Summary[".addPageEvents"] = false;


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

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

$tdataCalls_Summary[".isUseiBox"] = false;



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

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

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


$tdataCalls_Summary[".googleLikeFields"][] = "COUNT";
$tdataCalls_Summary[".googleLikeFields"][] = "Date";
$tdataCalls_Summary[".googleLikeFields"][] = "Executive Name";
$tdataCalls_Summary[".googleLikeFields"][] = "Customer Status";
$tdataCalls_Summary[".googleLikeFields"][] = "Region";

$tdataCalls_Summary[".panelSearchFields"][] = "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("Date", $tdataCalls_Summary[".allSearchFields"])) 
{
	$tdataCalls_Summary[".allSearchFields"][] = "Date";	
}


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

$tdataCalls_Summary[".isTableType"] = "report";

$tdataCalls_Summary[".reportGroupFields"] = true;

	

$tdataCalls_Summary[".isDisplayLoading"] = true;

$tdataCalls_Summary[".isResizeColumns"] = false;


$tdataCalls_Summary[".noRecordsFirstPage"] = true;




$gstrOrderBy = "ORDER BY Date(Date) DESC";
if(strlen($gstrOrderBy) && strtolower(substr($gstrOrderBy,0,8))!="order by")
	$gstrOrderBy = "order by ".$gstrOrderBy;
$tdataCalls_Summary[".strOrderBy"] = $gstrOrderBy;
	
$tdataCalls_Summary[".orderindexes"] = array();
$tdataCalls_Summary[".orderindexes"][] = array(2, (0 ? "ASC" : "DESC"), "Date(Date)");

$tdataCalls_Summary[".sqlHead"] = "SELECT COUNT(calls.idCalls) AS `COUNT`,  Date(Date) AS `Date`,  calls.`Executive Name`,  customer_list.`Customer Status`,  customer_list.Region";
$tdataCalls_Summary[".sqlFrom"] = "FROM calls  INNER JOIN customer_list ON calls.`Customer Name` = customer_list.`Customer Name`";
$tdataCalls_Summary[".sqlWhereExpr"] = "";
$tdataCalls_Summary[".sqlTail"] = "GROUP BY Date(Date), calls.`Executive Name`, customer_list.`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;
$tdataCalls_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;
$tdataCalls_Summary[".arrGroupsPerPage"] = $arrGPP;

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

//	COUNT
	$fdata = array();
	$fdata["strName"] = "COUNT";
	$fdata["ownerTable"] = "";
		
		
		
	$fdata["FieldType"]= 3;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "COUNT";
	
		$fdata["FullName"]= "COUNT(calls.idCalls)";
	
		
		
		
		
		
				$fdata["Index"]= 1;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		$fdata["bInlineAdd"]=true; 
	
		
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
		
		
		
		
			$tdataCalls_Summary["COUNT"]=$fdata;
//	Date
	$fdata = array();
	$fdata["strName"] = "Date";
	$fdata["ownerTable"] = "";
		
		
		
	$fdata["FieldType"]= 135;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Date";
	$fdata["ViewFormat"]= "Short Date";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Date";
	
		$fdata["FullName"]= "Date(Date)";
	
		
		
		
		
		
				$fdata["Index"]= 2;
		$fdata["DateEditType"] = 13; 
	$fdata["InitialYearFactor"] = 100; 
	$fdata["LastYearFactor"] = 10; 
			
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
		
		
		
		
			$tdataCalls_Summary["Date"]=$fdata;
//	Executive Name
	$fdata = array();
	$fdata["strName"] = "Executive Name";
	$fdata["ownerTable"] = "calls";
		
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "Executive_Name";
	
		$fdata["FullName"]= "calls.`Executive Name`";
	
		
		
		
		
		
				$fdata["Index"]= 3;
				$fdata["EditParams"]="";
			$fdata["EditParams"].= " maxlength=45";
		
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
		
		
		
		
			$tdataCalls_Summary["Executive Name"]=$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_list.`Customer Status`";
	
		
		
		
		
		
				$fdata["Index"]= 4;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		$fdata["bInlineAdd"]=true; 
	
		
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
		
		
		
		
			$tdataCalls_Summary["Customer Status"]=$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"]= "customer_list.Region";
	
		
		
		
		
		
				$fdata["Index"]= 5;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		
		
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				
		
		
		
		
		
			$tdataCalls_Summary["Region"]=$fdata;

	
$tables_data["Calls Summary"]=&$tdataCalls_Summary;
$field_labels["Calls_Summary"] = &$fieldLabelsCalls_Summary;
$fieldToolTips["Calls Summary"] = &$fieldToolTipsCalls_Summary;

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

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

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

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










$proto38=array();
$proto38["m_strHead"] = "SELECT";
$proto38["m_strFieldList"] = "COUNT(calls.idCalls) AS `COUNT`,  Date(Date) AS `Date`,  calls.`Executive Name`,  customer_list.`Customer Status`,  customer_list.Region";
$proto38["m_strFrom"] = "FROM calls  INNER JOIN customer_list ON calls.`Customer Name` = customer_list.`Customer Name`";
$proto38["m_strWhere"] = "";
$proto38["m_strOrderBy"] = "ORDER BY Date(Date) DESC";
$proto38["m_strTail"] = "GROUP BY Date(Date), calls.`Executive Name`, customer_list.`Customer Status`";
$proto39=array();
$proto39["m_sql"] = "";
$proto39["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

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

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

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

$proto38["m_having"] = $obj;
$proto38["m_fieldlist"] = array();
						$proto43=array();
			$proto44=array();
$proto44["m_functiontype"] = "SQLF_COUNT";
$proto44["m_arguments"] = array();
						$obj = new SQLField(array(
	"m_strName" => "idCalls",
	"m_strTable" => "calls"
));

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

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

$proto38["m_fieldlist"][]=$obj;
						$proto46=array();
			$proto47=array();
$proto47["m_functiontype"] = "SQLF_CUSTOM";
$proto47["m_arguments"] = array();
						$obj = new SQLNonParsed(array(
	"m_sql" => "Date"
));

$proto47["m_arguments"][]=$obj;
$proto47["m_strFunctionName"] = "Date";
$obj = new SQLFunctionCall($proto47);

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

$proto38["m_fieldlist"][]=$obj;
						$proto49=array();
			$obj = new SQLField(array(
	"m_strName" => "Executive Name",
	"m_strTable" => "calls"
));

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

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

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

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

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

$proto38["m_fieldlist"][]=$obj;
$proto38["m_fromlist"] = array();
												$proto55=array();
$proto55["m_link"] = "SQLL_MAIN";
			$proto56=array();
$proto56["m_strName"] = "calls";
$proto56["m_columns"] = array();
$proto56["m_columns"][] = "idCalls";
$proto56["m_columns"][] = "Date";
$proto56["m_columns"][] = "Call Details";
$proto56["m_columns"][] = "Executive Name";
$proto56["m_columns"][] = "Customer Name";
$obj = new SQLTable($proto56);

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

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

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

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

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

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

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

$proto38["m_fromlist"][]=$obj;
$proto38["m_groupby"] = array();
												$proto63=array();
						$proto64=array();
$proto64["m_functiontype"] = "SQLF_CUSTOM";
$proto64["m_arguments"] = array();
						$obj = new SQLNonParsed(array(
	"m_sql" => "Date"
));

$proto64["m_arguments"][]=$obj;
$proto64["m_strFunctionName"] = "Date";
$obj = new SQLFunctionCall($proto64);

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

$proto38["m_groupby"][]=$obj;
												$proto66=array();
						$obj = new SQLField(array(
	"m_strName" => "Executive Name",
	"m_strTable" => "calls"
));

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

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

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

$proto38["m_groupby"][]=$obj;
$proto38["m_orderby"] = array();
												$proto70=array();
						$proto71=array();
$proto71["m_functiontype"] = "SQLF_CUSTOM";
$proto71["m_arguments"] = array();
						$obj = new SQLNonParsed(array(
	"m_sql" => "Date"
));

$proto71["m_arguments"][]=$obj;
$proto71["m_strFunctionName"] = "Date";
$obj = new SQLFunctionCall($proto71);

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

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

$queryData_Calls_Summary = $obj;
$tdataCalls_Summary[".sqlquery"] = $queryData_Calls_Summary;

$tableEvents["Calls Summary"] = new eventsBase;

?>
