<?php
$tdatadependencias = array();
$tdatadependencias[".searchableFields"] = array();
$tdatadependencias[".ShortName"] = "dependencias";
$tdatadependencias[".OwnerID"] = "";
$tdatadependencias[".OriginalTable"] = "dependencias";


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

//	field labels
$fieldLabelsdependencias = array();
$fieldToolTipsdependencias = array();
$pageTitlesdependencias = array();
$placeHoldersdependencias = array();

if(mlang_getcurrentlang()=="Spanish")
{
	$fieldLabelsdependencias["Spanish"] = array();
	$fieldToolTipsdependencias["Spanish"] = array();
	$placeHoldersdependencias["Spanish"] = array();
	$pageTitlesdependencias["Spanish"] = array();
	$fieldLabelsdependencias["Spanish"]["id"] = "Id";
	$fieldToolTipsdependencias["Spanish"]["id"] = "";
	$placeHoldersdependencias["Spanish"]["id"] = "";
	$fieldLabelsdependencias["Spanish"]["dependencia"] = "Dependencia";
	$fieldToolTipsdependencias["Spanish"]["dependencia"] = "";
	$placeHoldersdependencias["Spanish"]["dependencia"] = "";
	$fieldLabelsdependencias["Spanish"]["nivel"] = "Nivel";
	$fieldToolTipsdependencias["Spanish"]["nivel"] = "";
	$placeHoldersdependencias["Spanish"]["nivel"] = "";
	$fieldLabelsdependencias["Spanish"]["pais"] = "Pais";
	$fieldToolTipsdependencias["Spanish"]["pais"] = "";
	$placeHoldersdependencias["Spanish"]["pais"] = "";
	$fieldLabelsdependencias["Spanish"]["municipio"] = "Municipio";
	$fieldToolTipsdependencias["Spanish"]["municipio"] = "";
	$placeHoldersdependencias["Spanish"]["municipio"] = "";
	$fieldLabelsdependencias["Spanish"]["entidad"] = "Entidad";
	$fieldToolTipsdependencias["Spanish"]["entidad"] = "";
	$placeHoldersdependencias["Spanish"]["entidad"] = "";
	if (count($fieldToolTipsdependencias["Spanish"]))
		$tdatadependencias[".isUseToolTips"] = true;
}


	$tdatadependencias[".NCSearch"] = true;



$tdatadependencias[".shortTableName"] = "dependencias";
$tdatadependencias[".nSecOptions"] = 0;

$tdatadependencias[".mainTableOwnerID"] = "";
$tdatadependencias[".entityType"] = 0;
$tdatadependencias[".connId"] = "omega2_at_localhost";


$tdatadependencias[".strOriginalTableName"] = "dependencias";

	



$tdatadependencias[".showAddInPopup"] = false;

$tdatadependencias[".showEditInPopup"] = false;

$tdatadependencias[".showViewInPopup"] = false;

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


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

	$tdatadependencias[".audit"] = false;

	$tdatadependencias[".locking"] = false;


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

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

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

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



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




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

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

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

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



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

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

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

$tdatadependencias[".isUseAjaxSuggest"] = true;

$tdatadependencias[".rowHighlite"] = true;





$tdatadependencias[".ajaxCodeSnippetAdded"] = false;

$tdatadependencias[".buttonsAdded"] = false;

$tdatadependencias[".addPageEvents"] = false;

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


$tdatadependencias[".badgeColor"] = "cd853f";


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

$tdatadependencias[".googleLikeFields"] = array();
$tdatadependencias[".googleLikeFields"][] = "id";
$tdatadependencias[".googleLikeFields"][] = "dependencia";
$tdatadependencias[".googleLikeFields"][] = "nivel";
$tdatadependencias[".googleLikeFields"][] = "pais";
$tdatadependencias[".googleLikeFields"][] = "entidad";
$tdatadependencias[".googleLikeFields"][] = "municipio";



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

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

$tdatadependencias[".nPrinterSplitRecords"] = 40;

$tdatadependencias[".geocodingEnabled"] = false;










$tdatadependencias[".pageSize"] = 20;

$tdatadependencias[".warnLeavingPages"] = true;



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

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


$tdatadependencias[".sqlHead"] = "SELECT id,  	dependencia,  	nivel,  	pais,  	entidad,  	municipio";
$tdatadependencias[".sqlFrom"] = "FROM dependencias";
$tdatadependencias[".sqlWhereExpr"] = "";
$tdatadependencias[".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;
$tdatadependencias[".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;
$tdatadependencias[".arrGroupsPerPage"] = $arrGPP;

$tdatadependencias[".highlightSearchResults"] = true;

$tableKeysdependencias = array();
$tableKeysdependencias[] = "id";
$tdatadependencias[".Keys"] = $tableKeysdependencias;


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




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

	
		$fdata["AutoInc"] = true;

	
			

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

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

	
	
				$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"] = "text";

		$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"] = "Contains";

			// the default search options list
				$fdata["searchOptionsList"] = array("Contains", "Equals", "Starts with", "More than", "Less than", "Between", "Empty", NOT_EMPTY);
// 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


	$tdatadependencias["id"] = $fdata;
		$tdatadependencias[".searchableFields"][] = "id";
//	dependencia
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 2;
	$fdata["strName"] = "dependencia";
	$fdata["GoodName"] = "dependencia";
	$fdata["ownerTable"] = "dependencias";
	$fdata["Label"] = GetFieldLabel("dependencias","dependencia");
	$fdata["FieldType"] = 200;

	
	
	
			

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

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

	
	
				$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=150";

		$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"] = "Contains";

			// the default search options list
				$fdata["searchOptionsList"] = array("Contains", "Equals", "Starts with", "More than", "Less than", "Between", "Empty", NOT_EMPTY);
// 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


	$tdatadependencias["dependencia"] = $fdata;
		$tdatadependencias[".searchableFields"][] = "dependencia";
//	nivel
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 3;
	$fdata["strName"] = "nivel";
	$fdata["GoodName"] = "nivel";
	$fdata["ownerTable"] = "dependencias";
	$fdata["Label"] = GetFieldLabel("dependencias","nivel");
	$fdata["FieldType"] = 3;

	
	
	
			

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

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

	
	
				$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" => "Lookup wizard");

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


	
	

// Begin Lookup settings
				$edata["LookupType"] = 2;
	$edata["LookupTable"] = "cat_niveldependencia";
			$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
		$edata["LCType"] = 0;

	
		
	$edata["LinkField"] = "id";
	$edata["LinkFieldType"] = 0;
	$edata["DisplayField"] = "nivel_dependencia";

	

	
	$edata["LookupOrderBy"] = "";

	
	
	
	

	
	
		$edata["SelectSize"] = 1;

// End Lookup Settings


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

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
	
	
		$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 default search options list
				$fdata["searchOptionsList"] = array("Contains", "Equals", "Starts with", "More than", "Less than", "Between", "Empty", NOT_EMPTY);
// 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


	$tdatadependencias["nivel"] = $fdata;
		$tdatadependencias[".searchableFields"][] = "nivel";
//	pais
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 4;
	$fdata["strName"] = "pais";
	$fdata["GoodName"] = "pais";
	$fdata["ownerTable"] = "dependencias";
	$fdata["Label"] = GetFieldLabel("dependencias","pais");
	$fdata["FieldType"] = 3;

	
	
	
			

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

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

	
	
				$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" => "Lookup wizard");

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


	
	

// Begin Lookup settings
				$edata["LookupType"] = 2;
	$edata["LookupTable"] = "cat_paises";
			$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
		$edata["LCType"] = 1;

	
		
	$edata["LinkField"] = "id";
	$edata["LinkFieldType"] = 0;
	$edata["DisplayField"] = "pais";

	

	
	$edata["LookupOrderBy"] = "";

	
	
	
	
				//dependent dropdowns @deprecated data ?
	$edata["DependentLookups"] = array();
	$edata["DependentLookups"][] = "entidad";

	
	
	
// End Lookup Settings


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

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
	
	
		$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 default search options list
				$fdata["searchOptionsList"] = array("Contains", "Equals", "Starts with", "More than", "Less than", "Between", "Empty", NOT_EMPTY);
// 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


	$tdatadependencias["pais"] = $fdata;
		$tdatadependencias[".searchableFields"][] = "pais";
//	entidad
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 5;
	$fdata["strName"] = "entidad";
	$fdata["GoodName"] = "entidad";
	$fdata["ownerTable"] = "dependencias";
	$fdata["Label"] = GetFieldLabel("dependencias","entidad");
	$fdata["FieldType"] = 3;

	
	
	
			

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

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

	
	
				$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" => "Lookup wizard");

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


	
	

// Begin Lookup settings
				$edata["LookupType"] = 2;
	$edata["LookupTable"] = "cat_entidad";
			$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
		$edata["LCType"] = 0;

	
		
	$edata["LinkField"] = "id";
	$edata["LinkFieldType"] = 0;
	$edata["DisplayField"] = "entidad";

	

	
	$edata["LookupOrderBy"] = "entidad";

	
		$edata["UseCategory"] = true;
	$edata["categoryFields"] = array();
	$edata["categoryFields"][] = array( "main" => "pais", "lookup" => "pais" );

	
	
				//dependent dropdowns @deprecated data ?
	$edata["DependentLookups"] = array();
	$edata["DependentLookups"][] = "municipio";

	
	
		$edata["SelectSize"] = 1;

// End Lookup Settings


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

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
	
	
		$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 default search options list
				$fdata["searchOptionsList"] = array("Contains", "Equals", "Starts with", "More than", "Less than", "Between", "Empty", NOT_EMPTY);
// 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


	$tdatadependencias["entidad"] = $fdata;
		$tdatadependencias[".searchableFields"][] = "entidad";
//	municipio
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 6;
	$fdata["strName"] = "municipio";
	$fdata["GoodName"] = "municipio";
	$fdata["ownerTable"] = "dependencias";
	$fdata["Label"] = GetFieldLabel("dependencias","municipio");
	$fdata["FieldType"] = 3;

	
	
	
			

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

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

	
	
				$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" => "Lookup wizard");

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


	
	

// Begin Lookup settings
				$edata["LookupType"] = 2;
	$edata["LookupTable"] = "cat_municipio";
			$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
		$edata["LCType"] = 0;

	
		
	$edata["LinkField"] = "id";
	$edata["LinkFieldType"] = 0;
	$edata["DisplayField"] = "municipio";

	

	
	$edata["LookupOrderBy"] = "";

	
		$edata["UseCategory"] = true;
	$edata["categoryFields"] = array();
	$edata["categoryFields"][] = array( "main" => "entidad", "lookup" => "entidad" );

	
	

	
	
		$edata["SelectSize"] = 1;

// End Lookup Settings


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

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
	
	
		$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 default search options list
				$fdata["searchOptionsList"] = array("Contains", "Equals", "Starts with", "More than", "Less than", "Between", "Empty", NOT_EMPTY);
// 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


	$tdatadependencias["municipio"] = $fdata;
		$tdatadependencias[".searchableFields"][] = "municipio";


$tables_data["dependencias"]=&$tdatadependencias;
$field_labels["dependencias"] = &$fieldLabelsdependencias;
$fieldToolTips["dependencias"] = &$fieldToolTipsdependencias;
$placeHolders["dependencias"] = &$placeHoldersdependencias;
$page_titles["dependencias"] = &$pageTitlesdependencias;

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

		$dIndex = 0;
	$detailsParam = array();
	$detailsParam["dDataSourceTable"]="cat_oficinas";
		$detailsParam["dOriginalTable"] = "cat_oficinas";



		
		$detailsParam["dType"]=PAGE_LIST;
	$detailsParam["dShortTable"] = "cat_oficinas";
	$detailsParam["dCaptionTable"] = GetTableCaption("cat_oficinas");
	$detailsParam["masterKeys"] =array();
	$detailsParam["detailKeys"] =array();


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

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

	$detailsTablesData["dependencias"][$dIndex]["masterKeys"][]="id";

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

	$detailsTablesData["dependencias"][$dIndex]["detailKeys"][]="dependencia";

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



	
				$strOriginalDetailsTable="cat_niveldependencia";
	$masterParams = array();
	$masterParams["mDataSourceTable"]="cat_niveldependencia";
	$masterParams["mOriginalTable"]= $strOriginalDetailsTable;
	$masterParams["mShortTable"]= "cat_niveldependencia";
	$masterParams["masterKeys"]= array();
	$masterParams["detailKeys"]= array();

	$masterParams["type"] = PAGE_LIST;
					$masterTablesData["dependencias"][0] = $masterParams;
				$masterTablesData["dependencias"][0]["masterKeys"] = array();
	$masterTablesData["dependencias"][0]["masterKeys"][]="id";
				$masterTablesData["dependencias"][0]["detailKeys"] = array();
	$masterTablesData["dependencias"][0]["detailKeys"][]="nivel";
		
// -----------------end  prepare master-details data arrays ------------------------------//



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











function createSqlQuery_dependencias()
{
$proto0=array();
$proto0["m_strHead"] = "SELECT";
$proto0["m_strFieldList"] = "id,  	dependencia,  	nivel,  	pais,  	entidad,  	municipio";
$proto0["m_strFrom"] = "FROM dependencias";
$proto0["m_strWhere"] = "";
$proto0["m_strOrderBy"] = "";
	
		;
			$proto0["cipherer"] = null;
$proto2=array();
$proto2["m_sql"] = "";
$proto2["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

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

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

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

$proto0["m_having"] = $obj;
$proto0["m_fieldlist"] = array();
						$proto6=array();
			$obj = new SQLField(array(
	"m_strName" => "id",
	"m_strTable" => "dependencias",
	"m_srcTableName" => "dependencias"
));

$proto6["m_sql"] = "id";
$proto6["m_srcTableName"] = "dependencias";
$proto6["m_expr"]=$obj;
$proto6["m_alias"] = "";
$obj = new SQLFieldListItem($proto6);

$proto0["m_fieldlist"][]=$obj;
						$proto8=array();
			$obj = new SQLField(array(
	"m_strName" => "dependencia",
	"m_strTable" => "dependencias",
	"m_srcTableName" => "dependencias"
));

$proto8["m_sql"] = "dependencia";
$proto8["m_srcTableName"] = "dependencias";
$proto8["m_expr"]=$obj;
$proto8["m_alias"] = "";
$obj = new SQLFieldListItem($proto8);

$proto0["m_fieldlist"][]=$obj;
						$proto10=array();
			$obj = new SQLField(array(
	"m_strName" => "nivel",
	"m_strTable" => "dependencias",
	"m_srcTableName" => "dependencias"
));

$proto10["m_sql"] = "nivel";
$proto10["m_srcTableName"] = "dependencias";
$proto10["m_expr"]=$obj;
$proto10["m_alias"] = "";
$obj = new SQLFieldListItem($proto10);

$proto0["m_fieldlist"][]=$obj;
						$proto12=array();
			$obj = new SQLField(array(
	"m_strName" => "pais",
	"m_strTable" => "dependencias",
	"m_srcTableName" => "dependencias"
));

$proto12["m_sql"] = "pais";
$proto12["m_srcTableName"] = "dependencias";
$proto12["m_expr"]=$obj;
$proto12["m_alias"] = "";
$obj = new SQLFieldListItem($proto12);

$proto0["m_fieldlist"][]=$obj;
						$proto14=array();
			$obj = new SQLField(array(
	"m_strName" => "entidad",
	"m_strTable" => "dependencias",
	"m_srcTableName" => "dependencias"
));

$proto14["m_sql"] = "entidad";
$proto14["m_srcTableName"] = "dependencias";
$proto14["m_expr"]=$obj;
$proto14["m_alias"] = "";
$obj = new SQLFieldListItem($proto14);

$proto0["m_fieldlist"][]=$obj;
						$proto16=array();
			$obj = new SQLField(array(
	"m_strName" => "municipio",
	"m_strTable" => "dependencias",
	"m_srcTableName" => "dependencias"
));

$proto16["m_sql"] = "municipio";
$proto16["m_srcTableName"] = "dependencias";
$proto16["m_expr"]=$obj;
$proto16["m_alias"] = "";
$obj = new SQLFieldListItem($proto16);

$proto0["m_fieldlist"][]=$obj;
$proto0["m_fromlist"] = array();
												$proto18=array();
$proto18["m_link"] = "SQLL_MAIN";
			$proto19=array();
$proto19["m_strName"] = "dependencias";
$proto19["m_srcTableName"] = "dependencias";
$proto19["m_columns"] = array();
$proto19["m_columns"][] = "id";
$proto19["m_columns"][] = "dependencia";
$proto19["m_columns"][] = "nivel";
$proto19["m_columns"][] = "pais";
$proto19["m_columns"][] = "entidad";
$proto19["m_columns"][] = "municipio";
$obj = new SQLTable($proto19);

$proto18["m_table"] = $obj;
$proto18["m_sql"] = "dependencias";
$proto18["m_alias"] = "";
$proto18["m_srcTableName"] = "dependencias";
$proto20=array();
$proto20["m_sql"] = "";
$proto20["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

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

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

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

	return $obj;
}
$queryData_dependencias = createSqlQuery_dependencias();


	
		;

						

$tdatadependencias[".sqlquery"] = $queryData_dependencias;



$tableEvents["dependencias"] = new eventsBase;
$tdatadependencias[".hasEvents"] = false;

?>