<?php
require_once(getabspath("classes/cipherer.php"));
$tdatasenuc_plantoes_aluno = array();
	$tdatasenuc_plantoes_aluno[".NumberOfChars"] = 80; 
	$tdatasenuc_plantoes_aluno[".ShortName"] = "senuc_plantoes_aluno";
	$tdatasenuc_plantoes_aluno[".OwnerID"] = "id_nucleo";
	$tdatasenuc_plantoes_aluno[".OriginalTable"] = "senuc_plantoes_aluno";

//	field labels
$fieldLabelssenuc_plantoes_aluno = array();
if(mlang_getcurrentlang()=="Portuguese(Brazil)")
{
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"] = array();
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"] = array();
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["id"] = "Id";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["id"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["id_plantao"] = "Plantao";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["id_plantao"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["id_aluno"] = "Aluno";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["id_aluno"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["ano"] = "Ano";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["ano"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["mes"] = "Mes";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["mes"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["dias_abertura"] = "Dias Abertura";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["dias_abertura"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["presencas"] = "Presencas";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["presencas"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["id_nucleo"] = "Nucleo";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["id_nucleo"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["operador"] = "Operador";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["operador"] = "";
	$fieldLabelssenuc_plantoes_aluno["Portuguese(Brazil)"]["data_insert"] = "Data Insert";
	$fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]["data_insert"] = "";
	if (count($fieldToolTipssenuc_plantoes_aluno["Portuguese(Brazil)"]))
		$tdatasenuc_plantoes_aluno[".isUseToolTips"] = true;
}
	
	
	$tdatasenuc_plantoes_aluno[".NCSearch"] = true;



$tdatasenuc_plantoes_aluno[".shortTableName"] = "senuc_plantoes_aluno";
$tdatasenuc_plantoes_aluno[".nSecOptions"] = 1;
$tdatasenuc_plantoes_aluno[".recsPerRowList"] = 1;
$tdatasenuc_plantoes_aluno[".mainTableOwnerID"] = "id_nucleo";
$tdatasenuc_plantoes_aluno[".moveNext"] = 1;
$tdatasenuc_plantoes_aluno[".nType"] = 0;

$tdatasenuc_plantoes_aluno[".strOriginalTableName"] = "senuc_plantoes_aluno";




$tdatasenuc_plantoes_aluno[".showAddInPopup"] = true;

$tdatasenuc_plantoes_aluno[".showEditInPopup"] = true;

$tdatasenuc_plantoes_aluno[".showViewInPopup"] = true;

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

$tdatasenuc_plantoes_aluno[".listAjax"] = false;

	$tdatasenuc_plantoes_aluno[".audit"] = false;

	$tdatasenuc_plantoes_aluno[".locking"] = false;

$tdatasenuc_plantoes_aluno[".listIcons"] = true;
$tdatasenuc_plantoes_aluno[".view"] = true;

$tdatasenuc_plantoes_aluno[".exportTo"] = true;

$tdatasenuc_plantoes_aluno[".printFriendly"] = true;


$tdatasenuc_plantoes_aluno[".showSimpleSearchOptions"] = false;

$tdatasenuc_plantoes_aluno[".showSearchPanel"] = true;

if (isMobile())
	$tdatasenuc_plantoes_aluno[".isUseAjaxSuggest"] = false;
else 
	$tdatasenuc_plantoes_aluno[".isUseAjaxSuggest"] = true;

$tdatasenuc_plantoes_aluno[".rowHighlite"] = true;

// button handlers file names

$tdatasenuc_plantoes_aluno[".addPageEvents"] = false;

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




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

$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "id_plantao";
$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "id_aluno";
$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "ano";
$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "mes";
$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "dias_abertura";
$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "presencas";
$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "operador";
$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "data_insert";
$tdatasenuc_plantoes_aluno[".allSearchFields"][] = "id_nucleo";

$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "id";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "id_plantao";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "id_aluno";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "ano";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "mes";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "dias_abertura";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "presencas";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "id_nucleo";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "operador";
$tdatasenuc_plantoes_aluno[".googleLikeFields"][] = "data_insert";


$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "id_plantao";
$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "id_aluno";
$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "ano";
$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "mes";
$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "dias_abertura";
$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "presencas";
$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "operador";
$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "data_insert";
$tdatasenuc_plantoes_aluno[".advSearchFields"][] = "id_nucleo";

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

	



// Access doesn't support subqueries from the same table as main



$tdatasenuc_plantoes_aluno[".pageSize"] = 20;

$tstrOrderBy = "ORDER BY ano,mes DESC";
if(strlen($tstrOrderBy) && strtolower(substr($tstrOrderBy,0,8))!="order by")
	$tstrOrderBy = "order by ".$tstrOrderBy;
$tdatasenuc_plantoes_aluno[".strOrderBy"] = $tstrOrderBy;

$tdatasenuc_plantoes_aluno[".orderindexes"] = array();
$tdatasenuc_plantoes_aluno[".orderindexes"][] = array(4, (1 ? "ASC" : "DESC"), "ano");
$tdatasenuc_plantoes_aluno[".orderindexes"][] = array(5, (0 ? "ASC" : "DESC"), "mes");

$tdatasenuc_plantoes_aluno[".sqlHead"] = "SELECT id,   id_plantao,   id_aluno,   ano,   mes,   dias_abertura,   presencas,   id_nucleo,   operador,   data_insert";
$tdatasenuc_plantoes_aluno[".sqlFrom"] = "FROM senuc_plantoes_aluno";
$tdatasenuc_plantoes_aluno[".sqlWhereExpr"] = "";
$tdatasenuc_plantoes_aluno[".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;
$tdatasenuc_plantoes_aluno[".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;
$tdatasenuc_plantoes_aluno[".arrGroupsPerPage"] = $arrGPP;

$tableKeyssenuc_plantoes_aluno = array();
$tableKeyssenuc_plantoes_aluno[] = "id";
$tdatasenuc_plantoes_aluno[".Keys"] = $tableKeyssenuc_plantoes_aluno;

$tdatasenuc_plantoes_aluno[".listFields"] = array();
$tdatasenuc_plantoes_aluno[".listFields"][] = "id_plantao";
$tdatasenuc_plantoes_aluno[".listFields"][] = "id_aluno";
$tdatasenuc_plantoes_aluno[".listFields"][] = "ano";
$tdatasenuc_plantoes_aluno[".listFields"][] = "mes";
$tdatasenuc_plantoes_aluno[".listFields"][] = "dias_abertura";
$tdatasenuc_plantoes_aluno[".listFields"][] = "presencas";
$tdatasenuc_plantoes_aluno[".listFields"][] = "operador";
$tdatasenuc_plantoes_aluno[".listFields"][] = "data_insert";
$tdatasenuc_plantoes_aluno[".listFields"][] = "id_nucleo";

$tdatasenuc_plantoes_aluno[".viewFields"] = array();
$tdatasenuc_plantoes_aluno[".viewFields"][] = "id_plantao";
$tdatasenuc_plantoes_aluno[".viewFields"][] = "id_aluno";
$tdatasenuc_plantoes_aluno[".viewFields"][] = "ano";
$tdatasenuc_plantoes_aluno[".viewFields"][] = "mes";
$tdatasenuc_plantoes_aluno[".viewFields"][] = "dias_abertura";
$tdatasenuc_plantoes_aluno[".viewFields"][] = "presencas";
$tdatasenuc_plantoes_aluno[".viewFields"][] = "operador";
$tdatasenuc_plantoes_aluno[".viewFields"][] = "data_insert";
$tdatasenuc_plantoes_aluno[".viewFields"][] = "id_nucleo";

$tdatasenuc_plantoes_aluno[".addFields"] = array();

$tdatasenuc_plantoes_aluno[".inlineAddFields"] = array();

$tdatasenuc_plantoes_aluno[".editFields"] = array();

$tdatasenuc_plantoes_aluno[".inlineEditFields"] = array();

$tdatasenuc_plantoes_aluno[".exportFields"] = array();
$tdatasenuc_plantoes_aluno[".exportFields"][] = "id_plantao";
$tdatasenuc_plantoes_aluno[".exportFields"][] = "id_aluno";
$tdatasenuc_plantoes_aluno[".exportFields"][] = "ano";
$tdatasenuc_plantoes_aluno[".exportFields"][] = "mes";
$tdatasenuc_plantoes_aluno[".exportFields"][] = "dias_abertura";
$tdatasenuc_plantoes_aluno[".exportFields"][] = "presencas";
$tdatasenuc_plantoes_aluno[".exportFields"][] = "operador";
$tdatasenuc_plantoes_aluno[".exportFields"][] = "data_insert";
$tdatasenuc_plantoes_aluno[".exportFields"][] = "id_nucleo";

$tdatasenuc_plantoes_aluno[".printFields"] = array();
$tdatasenuc_plantoes_aluno[".printFields"][] = "id_plantao";
$tdatasenuc_plantoes_aluno[".printFields"][] = "id_aluno";
$tdatasenuc_plantoes_aluno[".printFields"][] = "ano";
$tdatasenuc_plantoes_aluno[".printFields"][] = "mes";
$tdatasenuc_plantoes_aluno[".printFields"][] = "dias_abertura";
$tdatasenuc_plantoes_aluno[".printFields"][] = "presencas";
$tdatasenuc_plantoes_aluno[".printFields"][] = "operador";
$tdatasenuc_plantoes_aluno[".printFields"][] = "data_insert";
$tdatasenuc_plantoes_aluno[".printFields"][] = "id_nucleo";

//	id
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 1;
	$fdata["strName"] = "id";
	$fdata["GoodName"] = "id";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Id"; 
	$fdata["FieldType"] = 3;
	
		
		
		
		
		
		
		
		
		
		
		
		$fdata["strField"] = "id"; 
		$fdata["FullName"] = "id";
	
		
		
				
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Text field");
	
		
		
	
//	Begin Lookup settings
	//	End Lookup Settings

		$edata["IsRequired"] = true; 
	
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		$edata["EditParams"] = "";
			
		
//	Begin validation
	$edata["validateAs"] = array();
				$edata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						$edata["validateAs"]["basicValidate"][] = "IsRequired";
	
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["id"] = $fdata;
//	id_plantao
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 2;
	$fdata["strName"] = "id_plantao";
	$fdata["GoodName"] = "id_plantao";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Plantao"; 
	$fdata["FieldType"] = 3;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "id_plantao"; 
		$fdata["FullName"] = "id_plantao";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Lookup wizard");
	
		
		
	
//	Begin Lookup settings
								$edata["LookupType"] = 2;
	$edata["freeInput"] = 0;
	$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
				
		
			
	$edata["LinkField"] = "id";
	$edata["LinkFieldType"] = 3;
	$edata["DisplayField"] = "materia";
	
		
	$edata["LookupTable"] = "senuc_plantoes";
	$edata["LookupOrderBy"] = "";
	
		
		
		
		
		
				
	
	
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		
		
//	Begin validation
	$edata["validateAs"] = array();
						
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["id_plantao"] = $fdata;
//	id_aluno
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 3;
	$fdata["strName"] = "id_aluno";
	$fdata["GoodName"] = "id_aluno";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Aluno"; 
	$fdata["FieldType"] = 3;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "id_aluno"; 
		$fdata["FullName"] = "id_aluno";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Lookup wizard");
	
		
		
	
//	Begin Lookup settings
								$edata["LookupType"] = 2;
	$edata["freeInput"] = 0;
	$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
				
		
			
	$edata["LinkField"] = "id";
	$edata["LinkFieldType"] = 3;
	$edata["DisplayField"] = "nome";
	
		
	$edata["LookupTable"] = "senuc_aluno";
	$edata["LookupOrderBy"] = "";
	
		
		
		
		
		
				
	
	
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		
		
//	Begin validation
	$edata["validateAs"] = array();
						
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["id_aluno"] = $fdata;
//	ano
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 4;
	$fdata["strName"] = "ano";
	$fdata["GoodName"] = "ano";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Ano"; 
	$fdata["FieldType"] = 3;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "ano"; 
		$fdata["FullName"] = "ano";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Text field");
	
		
		
	
//	Begin Lookup settings
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		$edata["EditParams"] = "";
			
		
//	Begin validation
	$edata["validateAs"] = array();
				$edata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["ano"] = $fdata;
//	mes
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 5;
	$fdata["strName"] = "mes";
	$fdata["GoodName"] = "mes";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Mes"; 
	$fdata["FieldType"] = 3;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "mes"; 
		$fdata["FullName"] = "mes";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Text field");
	
		
		
	
//	Begin Lookup settings
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		$edata["EditParams"] = "";
			
		
//	Begin validation
	$edata["validateAs"] = array();
				$edata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["mes"] = $fdata;
//	dias_abertura
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 6;
	$fdata["strName"] = "dias_abertura";
	$fdata["GoodName"] = "dias_abertura";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Dias Abertura"; 
	$fdata["FieldType"] = 3;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "dias_abertura"; 
		$fdata["FullName"] = "dias_abertura";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Text field");
	
		
		
	
//	Begin Lookup settings
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		$edata["EditParams"] = "";
			
		
//	Begin validation
	$edata["validateAs"] = array();
				$edata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["dias_abertura"] = $fdata;
//	presencas
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 7;
	$fdata["strName"] = "presencas";
	$fdata["GoodName"] = "presencas";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Presencas"; 
	$fdata["FieldType"] = 3;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "presencas"; 
		$fdata["FullName"] = "presencas";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Text field");
	
		
		
	
//	Begin Lookup settings
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		$edata["EditParams"] = "";
			
		
//	Begin validation
	$edata["validateAs"] = array();
				$edata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["presencas"] = $fdata;
//	id_nucleo
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 8;
	$fdata["strName"] = "id_nucleo";
	$fdata["GoodName"] = "id_nucleo";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Nucleo"; 
	$fdata["FieldType"] = 3;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "id_nucleo"; 
		$fdata["FullName"] = "id_nucleo";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Lookup wizard");
	
		
		
	
//	Begin Lookup settings
								$edata["LookupType"] = 2;
	$edata["freeInput"] = 0;
	$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
				
		
			
	$edata["LinkField"] = "id";
	$edata["LinkFieldType"] = 3;
	$edata["DisplayField"] = "nome";
	
		
	$edata["LookupTable"] = "senuc_nucleo";
	$edata["LookupOrderBy"] = "";
	
		
		
		
		
		
				
	
	
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		
		
//	Begin validation
	$edata["validateAs"] = array();
						
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["id_nucleo"] = $fdata;
//	operador
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 9;
	$fdata["strName"] = "operador";
	$fdata["GoodName"] = "operador";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Operador"; 
	$fdata["FieldType"] = 3;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "operador"; 
		$fdata["FullName"] = "operador";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Lookup wizard");
	
		
		
	
//	Begin Lookup settings
								$edata["LookupType"] = 2;
	$edata["freeInput"] = 0;
	$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
				
		
			
	$edata["LinkField"] = "id";
	$edata["LinkFieldType"] = 3;
	$edata["DisplayField"] = "username";
	
		
	$edata["LookupTable"] = "senuc_login";
	$edata["LookupOrderBy"] = "";
	
		
		
		
		
		
				
	
	
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		
		
		
		
//	Begin validation
	$edata["validateAs"] = array();
						
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["operador"] = $fdata;
//	data_insert
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 10;
	$fdata["strName"] = "data_insert";
	$fdata["GoodName"] = "data_insert";
	$fdata["ownerTable"] = "senuc_plantoes_aluno";
	$fdata["Label"] = "Data Insert"; 
	$fdata["FieldType"] = 135;
	
		
		
		$fdata["bListPage"] = true; 
	
		
		
		
		
		$fdata["bViewPage"] = true; 
	
		$fdata["bAdvancedSearch"] = true; 
	
		$fdata["bPrinterPage"] = true; 
	
		$fdata["bExportPage"] = true; 
	
		$fdata["strField"] = "data_insert"; 
		$fdata["FullName"] = "data_insert";
	
		
		
				$fdata["FieldPermissions"] = true;
	
				$fdata["UploadFolder"] = "files";
		
//  Begin View Formats
	$fdata["ViewFormats"] = array();
	
	$vdata = array("ViewFormat" => "Short Date");
	
		
		
		
			
		
		
		
		
		
		
		$vdata["NeedEncode"] = true;
	
	$fdata["ViewFormats"]["view"] = $vdata;
//  End View Formats

//	Begin Edit Formats 	
	$fdata["EditFormats"] = array();
	
	$edata = array("EditFormat" => "Date");
	
		
		
	
//	Begin Lookup settings
	//	End Lookup Settings

		
		
		
		
			$edata["acceptFileTypes"] = ".+$";
	
		$edata["maxNumberOfFiles"] = 1;
	
		
		
		$edata["DateEditType"] = 13; 
	$edata["InitialYearFactor"] = 100; 
	$edata["LastYearFactor"] = 10; 
	
		
		
		
//	Begin validation
	$edata["validateAs"] = array();
		
	//	End validation
	
		
				
		$fdata["EditFormats"]["edit"] = $edata;
//	End Edit Formats
	
		$fdata["isSeparate"] = false;
	
		
		
	$tdatasenuc_plantoes_aluno["data_insert"] = $fdata;

	
$tables_data["senuc_plantoes_aluno"]=&$tdatasenuc_plantoes_aluno;
$field_labels["senuc_plantoes_aluno"] = &$fieldLabelssenuc_plantoes_aluno;
$fieldToolTips["senuc_plantoes_aluno"] = &$fieldToolTipssenuc_plantoes_aluno;

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

$mIndex = 1-1;
			$strOriginalDetailsTable="senuc_aluno";
	$masterParams["mDataSourceTable"]="senuc_aluno";
	$masterParams["mOriginalTable"]= $strOriginalDetailsTable;
	$masterParams["mShortTable"]= "senuc_aluno";
	$masterParams["masterKeys"]= array();
	$masterParams["detailKeys"]= array();
	$masterParams["dispChildCount"]= "1";
	$masterParams["hideChild"]= "1";
	$masterParams["dispInfo"]= "1";
	$masterParams["previewOnList"]= 1;
	$masterParams["previewOnAdd"]= 0;
	$masterParams["previewOnEdit"]= 0;
	$masterParams["previewOnView"]= 0;
	$masterTablesData["senuc_plantoes_aluno"][$mIndex] = $masterParams;	
		$masterTablesData["senuc_plantoes_aluno"][$mIndex]["masterKeys"][]="id";
		$masterTablesData["senuc_plantoes_aluno"][$mIndex]["detailKeys"][]="id_aluno";

$mIndex = 2-1;
			$strOriginalDetailsTable="senuc_plantoes";
	$masterParams["mDataSourceTable"]="senuc_plantoes";
	$masterParams["mOriginalTable"]= $strOriginalDetailsTable;
	$masterParams["mShortTable"]= "senuc_plantoes";
	$masterParams["masterKeys"]= array();
	$masterParams["detailKeys"]= array();
	$masterParams["dispChildCount"]= "1";
	$masterParams["hideChild"]= "0";
	$masterParams["dispInfo"]= "1";
	$masterParams["previewOnList"]= 1;
	$masterParams["previewOnAdd"]= 0;
	$masterParams["previewOnEdit"]= 0;
	$masterParams["previewOnView"]= 0;
	$masterTablesData["senuc_plantoes_aluno"][$mIndex] = $masterParams;	
		$masterTablesData["senuc_plantoes_aluno"][$mIndex]["masterKeys"][]="id";
		$masterTablesData["senuc_plantoes_aluno"][$mIndex]["detailKeys"][]="id_plantao";

$mIndex = 3-1;
			$strOriginalDetailsTable="senuc_nucleo";
	$masterParams["mDataSourceTable"]="senuc_nucleo";
	$masterParams["mOriginalTable"]= $strOriginalDetailsTable;
	$masterParams["mShortTable"]= "senuc_nucleo";
	$masterParams["masterKeys"]= array();
	$masterParams["detailKeys"]= array();
	$masterParams["dispChildCount"]= "1";
	$masterParams["hideChild"]= "0";
	$masterParams["dispInfo"]= "1";
	$masterParams["previewOnList"]= 1;
	$masterParams["previewOnAdd"]= 0;
	$masterParams["previewOnEdit"]= 0;
	$masterParams["previewOnView"]= 0;
	$masterTablesData["senuc_plantoes_aluno"][$mIndex] = $masterParams;	
		$masterTablesData["senuc_plantoes_aluno"][$mIndex]["masterKeys"][]="id";
		$masterTablesData["senuc_plantoes_aluno"][$mIndex]["detailKeys"][]="id_nucleo";

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

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










function createSqlQuery_senuc_plantoes_aluno()
{
$proto0=array();
$proto0["m_strHead"] = "SELECT";
$proto0["m_strFieldList"] = "id,   id_plantao,   id_aluno,   ano,   mes,   dias_abertura,   presencas,   id_nucleo,   operador,   data_insert";
$proto0["m_strFrom"] = "FROM senuc_plantoes_aluno";
$proto0["m_strWhere"] = "";
$proto0["m_strOrderBy"] = "ORDER BY ano,mes DESC";
$proto0["m_strTail"] = "";
$proto0["cipherer"] = null;
$proto1=array();
$proto1["m_sql"] = "";
$proto1["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

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

$proto0["m_where"] = $obj;
$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"] = "0";
$proto3["m_inBrackets"] = "0";
$proto3["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto3);

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

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

$proto0["m_fieldlist"][]=$obj;
						$proto7=array();
			$obj = new SQLField(array(
	"m_strName" => "id_plantao",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
						$proto9=array();
			$obj = new SQLField(array(
	"m_strName" => "id_aluno",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
						$proto11=array();
			$obj = new SQLField(array(
	"m_strName" => "ano",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
						$proto13=array();
			$obj = new SQLField(array(
	"m_strName" => "mes",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
						$proto15=array();
			$obj = new SQLField(array(
	"m_strName" => "dias_abertura",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
						$proto17=array();
			$obj = new SQLField(array(
	"m_strName" => "presencas",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
						$proto19=array();
			$obj = new SQLField(array(
	"m_strName" => "id_nucleo",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
						$proto21=array();
			$obj = new SQLField(array(
	"m_strName" => "operador",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
						$proto23=array();
			$obj = new SQLField(array(
	"m_strName" => "data_insert",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_fieldlist"][]=$obj;
$proto0["m_fromlist"] = array();
												$proto25=array();
$proto25["m_link"] = "SQLL_MAIN";
			$proto26=array();
$proto26["m_strName"] = "senuc_plantoes_aluno";
$proto26["m_columns"] = array();
$proto26["m_columns"][] = "id";
$proto26["m_columns"][] = "id_plantao";
$proto26["m_columns"][] = "id_aluno";
$proto26["m_columns"][] = "ano";
$proto26["m_columns"][] = "mes";
$proto26["m_columns"][] = "dias_abertura";
$proto26["m_columns"][] = "presencas";
$proto26["m_columns"][] = "id_nucleo";
$proto26["m_columns"][] = "operador";
$proto26["m_columns"][] = "data_insert";
$obj = new SQLTable($proto26);

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

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

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

$proto0["m_fromlist"][]=$obj;
$proto0["m_groupby"] = array();
$proto0["m_orderby"] = array();
												$proto29=array();
						$obj = new SQLField(array(
	"m_strName" => "ano",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

$proto0["m_orderby"][]=$obj;					
												$proto31=array();
						$obj = new SQLField(array(
	"m_strName" => "mes",
	"m_strTable" => "senuc_plantoes_aluno"
));

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

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

	return $obj;
}
$queryData_senuc_plantoes_aluno = createSqlQuery_senuc_plantoes_aluno();
										$tdatasenuc_plantoes_aluno[".sqlquery"] = $queryData_senuc_plantoes_aluno;
	
if(isset($tdatasenuc_plantoes_aluno["field2"])){
	$tdatasenuc_plantoes_aluno["field2"]["LookupTable"] = "carscars_view";
	$tdatasenuc_plantoes_aluno["field2"]["LookupOrderBy"] = "name";
	$tdatasenuc_plantoes_aluno["field2"]["LookupType"] = 4;
	$tdatasenuc_plantoes_aluno["field2"]["LinkField"] = "email";
	$tdatasenuc_plantoes_aluno["field2"]["DisplayField"] = "name";
	$tdatasenuc_plantoes_aluno[".hasCustomViewField"] = true;
}

$tableEvents["senuc_plantoes_aluno"] = new eventsBase;
$tdatasenuc_plantoes_aluno[".hasEvents"] = false;

$cipherer = new RunnerCipherer("senuc_plantoes_aluno");

?>