<?php



$tdataClones = array();
$tdataClones[".searchableFields"] = array();
$tdataClones[".ShortName"] = "Clones";
$tdataClones[".OwnerID"] = "";
$tdataClones[".OriginalTable"] = "Clones";


$tdataClones[".pagesByType"] = my_json_decode( "{\"add\":[\"add\"],\"edit\":[\"edit\"],\"export\":[\"export\"],\"import\":[\"import\"],\"list\":[\"list\"],\"masterlist\":[\"masterlist\"],\"masterprint\":[\"masterprint\"],\"search\":[\"search\"]}" );
$tdataClones[".originalPagesByType"] = $tdataClones[".pagesByType"];
$tdataClones[".pages"] = types2pages( my_json_decode( "{\"add\":[\"add\"],\"edit\":[\"edit\"],\"export\":[\"export\"],\"import\":[\"import\"],\"list\":[\"list\"],\"masterlist\":[\"masterlist\"],\"masterprint\":[\"masterprint\"],\"search\":[\"search\"]}" ) );
$tdataClones[".originalPages"] = $tdataClones[".pages"];
$tdataClones[".defaultPages"] = my_json_decode( "{\"add\":\"add\",\"edit\":\"edit\",\"export\":\"export\",\"import\":\"import\",\"list\":\"list\",\"masterlist\":\"masterlist\",\"masterprint\":\"masterprint\",\"search\":\"search\"}" );
$tdataClones[".originalDefaultPages"] = $tdataClones[".defaultPages"];

//	field labels
$fieldLabelsClones = array();
$fieldToolTipsClones = array();
$pageTitlesClones = array();
$placeHoldersClones = array();

if(mlang_getcurrentlang()=="Portuguese(Standard)")
{
	$fieldLabelsClones["Portuguese(Standard)"] = array();
	$fieldToolTipsClones["Portuguese(Standard)"] = array();
	$placeHoldersClones["Portuguese(Standard)"] = array();
	$pageTitlesClones["Portuguese(Standard)"] = array();
	$fieldLabelsClones["Portuguese(Standard)"]["CodClone"] = "Cod Clone";
	$fieldToolTipsClones["Portuguese(Standard)"]["CodClone"] = "";
	$placeHoldersClones["Portuguese(Standard)"]["CodClone"] = "";
	$fieldLabelsClones["Portuguese(Standard)"]["Clone"] = "Clone";
	$fieldToolTipsClones["Portuguese(Standard)"]["Clone"] = "";
	$placeHoldersClones["Portuguese(Standard)"]["Clone"] = "";
	if (count($fieldToolTipsClones["Portuguese(Standard)"]))
		$tdataClones[".isUseToolTips"] = true;
}


	$tdataClones[".NCSearch"] = true;


	$tdataClones[".scrollGridBody"] = true;

$tdataClones[".shortTableName"] = "Clones";
$tdataClones[".nSecOptions"] = 0;

$tdataClones[".mainTableOwnerID"] = "";
$tdataClones[".entityType"] = 0;

$tdataClones[".strOriginalTableName"] = "Clones";

	



$tdataClones[".showAddInPopup"] = true;

$tdataClones[".showEditInPopup"] = false;

$tdataClones[".showViewInPopup"] = false;

//page's base css files names
$popupPagesLayoutNames = array();
			;
$popupPagesLayoutNames["add"] = "login";
$tdataClones[".popupPagesLayoutNames"] = $popupPagesLayoutNames;


$tdataClones[".listAjax"] = false;
//	temporary
$tdataClones[".listAjax"] = false;

	$tdataClones[".audit"] = true;

	$tdataClones[".locking"] = true;


$pages = $tdataClones[".defaultPages"];

if( $pages[PAGE_EDIT] ) {
	$tdataClones[".edit"] = true;
	$tdataClones[".afterEditAction"] = 1;
	$tdataClones[".closePopupAfterEdit"] = 1;
	$tdataClones[".afterEditActionDetTable"] = "";
}

if( $pages[PAGE_ADD] ) {
$tdataClones[".add"] = true;
$tdataClones[".afterAddAction"] = 1;
$tdataClones[".closePopupAfterAdd"] = 1;
$tdataClones[".afterAddActionDetTable"] = "";
}

if( $pages[PAGE_LIST] ) {
	$tdataClones[".list"] = true;
}



$tdataClones[".strSortControlSettingsJSON"] = "";




if( $pages[PAGE_VIEW] ) {
$tdataClones[".view"] = true;
}

if( $pages[PAGE_IMPORT] ) {
$tdataClones[".import"] = true;
}

if( $pages[PAGE_EXPORT] ) {
$tdataClones[".exportTo"] = true;
}

if( $pages[PAGE_PRINT] ) {
$tdataClones[".printFriendly"] = true;
}



$tdataClones[".showSimpleSearchOptions"] = true; // temp fix #13449

// Allow Show/Hide Fields in GRID
$tdataClones[".allowShowHideFields"] = true; // temp fix #13449
//

// Allow Fields Reordering in GRID
$tdataClones[".allowFieldsReordering"] = true; // temp fix #13449
//

$tdataClones[".isUseAjaxSuggest"] = true;

$tdataClones[".rowHighlite"] = true;



			

$tdataClones[".ajaxCodeSnippetAdded"] = false;

$tdataClones[".buttonsAdded"] = false;

$tdataClones[".addPageEvents"] = false;

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




$tdataClones[".allSearchFields"] = array();
$tdataClones[".filterFields"] = array();
$tdataClones[".requiredSearchFields"] = array();

$tdataClones[".googleLikeFields"] = array();
$tdataClones[".googleLikeFields"][] = "CodClone";
$tdataClones[".googleLikeFields"][] = "Clone";



$tdataClones[".tableType"] = "list";

$tdataClones[".printerPageOrientation"] = 0;
$tdataClones[".nPrinterPageScale"] = 100;

$tdataClones[".nPrinterSplitRecords"] = 40;

$tdataClones[".geocodingEnabled"] = false;










$tdataClones[".pageSize"] = 999;

$tdataClones[".warnLeavingPages"] = true;



$tstrOrderBy = "";
if(strlen($tstrOrderBy) && strtolower(substr($tstrOrderBy,0,8))!="order by")
	$tstrOrderBy = "order by ".$tstrOrderBy;
$tdataClones[".strOrderBy"] = $tstrOrderBy;

$tdataClones[".orderindexes"] = array();

$tdataClones[".sqlHead"] = "SELECT CodClone,  	Clone";
$tdataClones[".sqlFrom"] = "FROM Clones";
$tdataClones[".sqlWhereExpr"] = "";
$tdataClones[".sqlTail"] = "";










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

$tdataClones[".highlightSearchResults"] = true;

$tableKeysClones = array();
$tableKeysClones[] = "CodClone";
$tdataClones[".Keys"] = $tableKeysClones;


$tdataClones[".hideMobileList"] = array();




//	CodClone
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 1;
	$fdata["strName"] = "CodClone";
	$fdata["GoodName"] = "CodClone";
	$fdata["ownerTable"] = "Clones";
	$fdata["Label"] = GetFieldLabel("Clones","CodClone");
	$fdata["FieldType"] = 3;

	
		$fdata["AutoInc"] = true;

	
			

		$fdata["strField"] = "CodClone";

		$fdata["isSQLExpression"] = true;
	$fdata["FullName"] = "CodClone";

	
	
				$fdata["UploadFolder"] = "files";

//  Begin View Formats
	$fdata["ViewFormats"] = array();

	$vdata = array("ViewFormat" => "");

	
	
	
	
	
	
	
	
	
	
	
	
		$vdata["NeedEncode"] = true;

	
		$vdata["truncateText"] = true;
	$vdata["NumberOfChars"] = 80;

	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats
	$fdata["EditFormats"] = array();

	$edata = array("EditFormat" => "Text field");

	
		$edata["weekdayMessage"] = array("message" => "", "messageType" => "Text");
	$edata["weekdays"] = "[]";


	
	



		$edata["IsRequired"] = true;

	
	
	
			$edata["acceptFileTypes"] = ".+$";
		$edata["acceptFileTypesHtml"] = "";

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
			$edata["HTML5InuptType"] = "number";

		$edata["EditParams"] = "";
		
		$edata["controlWidth"] = 200;

//	Begin validation
	$edata["validateAs"] = array();
	$edata["validateAs"]["basicValidate"] = array();
	$edata["validateAs"]["customMessages"] = array();
				$edata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");
						$edata["validateAs"]["basicValidate"][] = "IsRequired";
		
	
	//	End validation

	
			
	
	
	
	$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats


	$fdata["isSeparate"] = false;




// the field's search options settings
		$fdata["defaultSearchOption"] = "Equals";

	// the end of search options settings


//Filters settings
	$fdata["filterTotals"] = 0;
		$fdata["filterMultiSelect"] = 0;
			$fdata["filterFormat"] = "Values list";
		$fdata["showCollapsed"] = false;

		$fdata["sortValueType"] = 0;
		$fdata["numberOfVisibleItems"] = 10;

		$fdata["filterBy"] = 0;

	

	
	
//end of Filters settings


	$tdataClones["CodClone"] = $fdata;
		$tdataClones[".searchableFields"][] = "CodClone";
//	Clone
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 2;
	$fdata["strName"] = "Clone";
	$fdata["GoodName"] = "Clone";
	$fdata["ownerTable"] = "Clones";
	$fdata["Label"] = GetFieldLabel("Clones","Clone");
	$fdata["FieldType"] = 200;

	
	
	
			

		$fdata["strField"] = "Clone";

		$fdata["isSQLExpression"] = true;
	$fdata["FullName"] = "Clone";

	
	
				$fdata["UploadFolder"] = "files";

//  Begin View Formats
	$fdata["ViewFormats"] = array();

	$vdata = array("ViewFormat" => "");

	
	
	
	
	
	
	
	
	
	
	
	
		$vdata["NeedEncode"] = true;

	
		$vdata["truncateText"] = true;
	$vdata["NumberOfChars"] = 80;

	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats
	$fdata["EditFormats"] = array();

	$edata = array("EditFormat" => "Text field");

	
		$edata["weekdayMessage"] = array("message" => "", "messageType" => "Text");
	$edata["weekdays"] = "[]";


	
	



	
	
	
	
			$edata["acceptFileTypes"] = ".+$";
		$edata["acceptFileTypesHtml"] = "";

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
			$edata["HTML5InuptType"] = "text";

		$edata["EditParams"] = "";
			$edata["EditParams"].= " maxlength=50";

		$edata["controlWidth"] = 200;

//	Begin validation
	$edata["validateAs"] = array();
	$edata["validateAs"]["basicValidate"] = array();
	$edata["validateAs"]["customMessages"] = array();
	
	
	//	End validation

	
			
	
	
	
	$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats


	$fdata["isSeparate"] = false;




// the field's search options settings
		$fdata["defaultSearchOption"] = "Equals";

	// the end of search options settings


//Filters settings
	$fdata["filterTotals"] = 0;
		$fdata["filterMultiSelect"] = 0;
			$fdata["filterFormat"] = "Values list";
		$fdata["showCollapsed"] = false;

		$fdata["sortValueType"] = 0;
		$fdata["numberOfVisibleItems"] = 10;

		$fdata["filterBy"] = 0;

	

	
	
//end of Filters settings


	$tdataClones["Clone"] = $fdata;
		$tdataClones[".searchableFields"][] = "Clone";


$tables_data["Clones"]=&$tdataClones;
$field_labels["Clones"] = &$fieldLabelsClones;
$fieldToolTips["Clones"] = &$fieldToolTipsClones;
$placeHolders["Clones"] = &$placeHoldersClones;
$page_titles["Clones"] = &$pageTitlesClones;

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

		$dIndex = 0;
	$detailsParam = array();
	$detailsParam["dDataSourceTable"]="Vinha Report Clone";
		$detailsParam["dOriginalTable"] = "Vinha";



		$detailsParam["dType"]=PAGE_REPORT;
			$detailsParam["dShortTable"] = "vinha_report_clone";
	$detailsParam["dCaptionTable"] = GetTableCaption("Vinha_Report_Clone");
	$detailsParam["masterKeys"] =array();
	$detailsParam["detailKeys"] =array();


		
	$detailsTablesData["Clones"][$dIndex] = $detailsParam;

	
		$detailsTablesData["Clones"][$dIndex]["masterKeys"] = array();

	$detailsTablesData["Clones"][$dIndex]["masterKeys"][]="CodClone";

				$detailsTablesData["Clones"][$dIndex]["detailKeys"] = array();

	$detailsTablesData["Clones"][$dIndex]["detailKeys"][]="Clone";

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



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


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










function createSqlQuery_Clones()
{
$proto1=array();
$proto1["m_strHead"] = "SELECT";
$proto1["m_strFieldList"] = "CodClone,  	Clone";
$proto1["m_strFrom"] = "FROM Clones";
$proto1["m_strWhere"] = "";
$proto1["m_strOrderBy"] = "";
	
		;
			$proto1["cipherer"] = null;
$proto3=array();
$proto3["m_sql"] = "";
$proto3["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

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

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

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

$proto1["m_having"] = $obj;
$proto1["m_fieldlist"] = array();
						$proto7=array();
			$obj = new SQLField(array(
	"m_strName" => "CodClone",
	"m_strTable" => "Clones",
	"m_srcTableName" => "Clones"
));

$proto7["m_sql"] = "CodClone";
$proto7["m_srcTableName"] = "Clones";
$proto7["m_expr"]=$obj;
$proto7["m_alias"] = "";
$obj = new SQLFieldListItem($proto7);

$proto1["m_fieldlist"][]=$obj;
						$proto9=array();
			$obj = new SQLField(array(
	"m_strName" => "Clone",
	"m_strTable" => "Clones",
	"m_srcTableName" => "Clones"
));

$proto9["m_sql"] = "Clone";
$proto9["m_srcTableName"] = "Clones";
$proto9["m_expr"]=$obj;
$proto9["m_alias"] = "";
$obj = new SQLFieldListItem($proto9);

$proto1["m_fieldlist"][]=$obj;
$proto1["m_fromlist"] = array();
												$proto11=array();
$proto11["m_link"] = "SQLL_MAIN";
			$proto12=array();
$proto12["m_strName"] = "Clones";
$proto12["m_srcTableName"] = "Clones";
$proto12["m_columns"] = array();
$proto12["m_columns"][] = "CodClone";
$proto12["m_columns"][] = "Clone";
$obj = new SQLTable($proto12);

$proto11["m_table"] = $obj;
$proto11["m_sql"] = "Clones";
$proto11["m_alias"] = "";
$proto11["m_srcTableName"] = "Clones";
$proto13=array();
$proto13["m_sql"] = "";
$proto13["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

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

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

$proto1["m_fromlist"][]=$obj;
$proto1["m_groupby"] = array();
$proto1["m_orderby"] = array();
$proto1["m_srcTableName"]="Clones";		
$obj = new SQLQuery($proto1);

	return $obj;
}
$queryData_Clones = createSqlQuery_Clones();


	
		;

		

$tdataClones[".sqlquery"] = $queryData_Clones;

$tableEvents["Clones"] = new eventsBase;
$tdataClones[".hasEvents"] = false;

?>