<?php



$tdatatb_agenda_exame = array();
$tdatatb_agenda_exame[".searchableFields"] = array();
$tdatatb_agenda_exame[".ShortName"] = "tb_agenda_exame";
$tdatatb_agenda_exame[".OwnerID"] = "";
$tdatatb_agenda_exame[".OriginalTable"] = "tb_agenda_exame";


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

//	field labels
$fieldLabelstb_agenda_exame = array();
$fieldToolTipstb_agenda_exame = array();
$pageTitlestb_agenda_exame = array();
$placeHolderstb_agenda_exame = array();

if(mlang_getcurrentlang()=="English")
{
	$fieldLabelstb_agenda_exame["English"] = array();
	$fieldToolTipstb_agenda_exame["English"] = array();
	$placeHolderstb_agenda_exame["English"] = array();
	$pageTitlestb_agenda_exame["English"] = array();
	$fieldLabelstb_agenda_exame["English"]["agendaID"] = "ID";
	$fieldToolTipstb_agenda_exame["English"]["agendaID"] = "";
	$placeHolderstb_agenda_exame["English"]["agendaID"] = "";
	$fieldLabelstb_agenda_exame["English"]["exameID"] = "Exame ID";
	$fieldToolTipstb_agenda_exame["English"]["exameID"] = "";
	$placeHolderstb_agenda_exame["English"]["exameID"] = "";
	$fieldLabelstb_agenda_exame["English"]["laboratorio"] = "Laboratório ";
	$fieldToolTipstb_agenda_exame["English"]["laboratorio"] = "";
	$placeHolderstb_agenda_exame["English"]["laboratorio"] = "";
	$fieldLabelstb_agenda_exame["English"]["data"] = "Data";
	$fieldToolTipstb_agenda_exame["English"]["data"] = "";
	$placeHolderstb_agenda_exame["English"]["data"] = "";
	$fieldLabelstb_agenda_exame["English"]["horario"] = "Horário ";
	$fieldToolTipstb_agenda_exame["English"]["horario"] = "";
	$placeHolderstb_agenda_exame["English"]["horario"] = "";
	$fieldLabelstb_agenda_exame["English"]["preparacao"] = "Preparação ";
	$fieldToolTipstb_agenda_exame["English"]["preparacao"] = "";
	$placeHolderstb_agenda_exame["English"]["preparacao"] = "";
	$fieldLabelstb_agenda_exame["English"]["valor"] = "Valor";
	$fieldToolTipstb_agenda_exame["English"]["valor"] = "";
	$placeHolderstb_agenda_exame["English"]["valor"] = "";
	$fieldLabelstb_agenda_exame["English"]["status"] = "Status";
	$fieldToolTipstb_agenda_exame["English"]["status"] = "";
	$placeHolderstb_agenda_exame["English"]["status"] = "";
	$fieldLabelstb_agenda_exame["English"]["data_resultado"] = "Data Resultado";
	$fieldToolTipstb_agenda_exame["English"]["data_resultado"] = "";
	$placeHolderstb_agenda_exame["English"]["data_resultado"] = "";
	$fieldLabelstb_agenda_exame["English"]["Tipo_retirada"] = "Tipo Retirada";
	$fieldToolTipstb_agenda_exame["English"]["Tipo_retirada"] = "";
	$placeHolderstb_agenda_exame["English"]["Tipo_retirada"] = "";
	$fieldLabelstb_agenda_exame["English"]["copia_pdf"] = "Copia Pdf";
	$fieldToolTipstb_agenda_exame["English"]["copia_pdf"] = "";
	$placeHolderstb_agenda_exame["English"]["copia_pdf"] = "";
	if (count($fieldToolTipstb_agenda_exame["English"]))
		$tdatatb_agenda_exame[".isUseToolTips"] = true;
}


	$tdatatb_agenda_exame[".NCSearch"] = true;



$tdatatb_agenda_exame[".shortTableName"] = "tb_agenda_exame";
$tdatatb_agenda_exame[".nSecOptions"] = 0;

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

$tdatatb_agenda_exame[".strOriginalTableName"] = "tb_agenda_exame";

	



$tdatatb_agenda_exame[".showAddInPopup"] = false;

$tdatatb_agenda_exame[".showEditInPopup"] = false;

$tdatatb_agenda_exame[".showViewInPopup"] = false;

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


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

	$tdatatb_agenda_exame[".audit"] = false;

	$tdatatb_agenda_exame[".locking"] = false;


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

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

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

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



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




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

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

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

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



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

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

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

$tdatatb_agenda_exame[".isUseAjaxSuggest"] = true;

$tdatatb_agenda_exame[".rowHighlite"] = true;





$tdatatb_agenda_exame[".ajaxCodeSnippetAdded"] = false;

$tdatatb_agenda_exame[".buttonsAdded"] = false;

$tdatatb_agenda_exame[".addPageEvents"] = false;

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


$tdatatb_agenda_exame[".badgeColor"] = "8fbc8b";


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

$tdatatb_agenda_exame[".googleLikeFields"] = array();
$tdatatb_agenda_exame[".googleLikeFields"][] = "agendaID";
$tdatatb_agenda_exame[".googleLikeFields"][] = "exameID";
$tdatatb_agenda_exame[".googleLikeFields"][] = "laboratorio";
$tdatatb_agenda_exame[".googleLikeFields"][] = "data";
$tdatatb_agenda_exame[".googleLikeFields"][] = "horario";
$tdatatb_agenda_exame[".googleLikeFields"][] = "preparacao";
$tdatatb_agenda_exame[".googleLikeFields"][] = "valor";
$tdatatb_agenda_exame[".googleLikeFields"][] = "status";
$tdatatb_agenda_exame[".googleLikeFields"][] = "data_resultado";
$tdatatb_agenda_exame[".googleLikeFields"][] = "Tipo_retirada";
$tdatatb_agenda_exame[".googleLikeFields"][] = "copia_pdf";



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

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

$tdatatb_agenda_exame[".nPrinterSplitRecords"] = 40;

$tdatatb_agenda_exame[".geocodingEnabled"] = false;










$tdatatb_agenda_exame[".pageSize"] = 20;

$tdatatb_agenda_exame[".warnLeavingPages"] = true;



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

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

$tdatatb_agenda_exame[".sqlHead"] = "SELECT agendaID,  	exameID,  	laboratorio,  	`data`,  	horario,  	preparacao,  	valor,  	status,  	data_resultado,  	Tipo_retirada,  	copia_pdf";
$tdatatb_agenda_exame[".sqlFrom"] = "FROM tb_agenda_exame";
$tdatatb_agenda_exame[".sqlWhereExpr"] = "";
$tdatatb_agenda_exame[".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;
$tdatatb_agenda_exame[".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;
$tdatatb_agenda_exame[".arrGroupsPerPage"] = $arrGPP;

$tdatatb_agenda_exame[".highlightSearchResults"] = true;

$tableKeystb_agenda_exame = array();
$tableKeystb_agenda_exame[] = "agendaID";
$tdatatb_agenda_exame[".Keys"] = $tableKeystb_agenda_exame;


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




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

	
		$fdata["AutoInc"] = true;

	
			

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

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

	
	
				$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


	$tdatatb_agenda_exame["agendaID"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "agendaID";
//	exameID
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 2;
	$fdata["strName"] = "exameID";
	$fdata["GoodName"] = "exameID";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","exameID");
	$fdata["FieldType"] = 3;

	
	
	
			

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

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

	
	
				$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["controlWidth"] = 200;

//	Begin validation
	$edata["validateAs"] = array();
	$edata["validateAs"]["basicValidate"] = array();
	$edata["validateAs"]["customMessages"] = array();
				$edata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");
							
	
	//	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


	$tdatatb_agenda_exame["exameID"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "exameID";
//	laboratorio
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 3;
	$fdata["strName"] = "laboratorio";
	$fdata["GoodName"] = "laboratorio";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","laboratorio");
	$fdata["FieldType"] = 3;

	
	
	
			

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

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

	
	
				$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"] = "tb_laborartorios";
			$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
		$edata["LCType"] = 0;

	
		
	$edata["LinkField"] = "laborat_ID";
	$edata["LinkFieldType"] = 0;
	$edata["DisplayField"] = "laboratorio";

	

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

	
	
	
	

	
	
		$edata["SelectSize"] = 1;

// End Lookup Settings


		$edata["IsRequired"] = true;

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

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
	
	
		$edata["controlWidth"] = 200;

//	Begin validation
	$edata["validateAs"] = array();
	$edata["validateAs"]["basicValidate"] = array();
	$edata["validateAs"]["customMessages"] = array();
						$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 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


	$tdatatb_agenda_exame["laboratorio"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "laboratorio";
//	data
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 4;
	$fdata["strName"] = "data";
	$fdata["GoodName"] = "data";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","data");
	$fdata["FieldType"] = 7;

	
	
	
			

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

		$fdata["isSQLExpression"] = true;
	$fdata["FullName"] = "`data`";

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

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

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

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

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


	
	



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

		$edata["maxNumberOfFiles"] = 1;

	
	
		$edata["DateEditType"] = 13;
	$edata["InitialYearFactor"] = 100;
	$edata["LastYearFactor"] = 10;

	
	
	
		$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("Equals", "More than", "Less than", "Between", EMPTY_SEARCH, 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


	$tdatatb_agenda_exame["data"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "data";
//	horario
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 5;
	$fdata["strName"] = "horario";
	$fdata["GoodName"] = "horario";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","horario");
	$fdata["FieldType"] = 134;

	
	
	
			

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

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

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

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

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

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

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


	
	



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

		$edata["maxNumberOfFiles"] = 1;

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

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

	
			
				$hours = 24;
	$edata["FormatTimeAttrs"] = array("useTimePicker" => 0,
									  "hours" => $hours,
									  "minutes" => 1,
									  "showSeconds" => 0);

	
	
	$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("Equals", "More than", "Less than", "Between", EMPTY_SEARCH, 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


	$tdatatb_agenda_exame["horario"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "horario";
//	preparacao
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 6;
	$fdata["strName"] = "preparacao";
	$fdata["GoodName"] = "preparacao";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","preparacao");
	$fdata["FieldType"] = 200;

	
	
	
			

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

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

	
	
				$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 area");

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


	
	



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

		$edata["maxNumberOfFiles"] = 1;

	
	
	
				$edata["nRows"] = 100;
			$edata["nCols"] = 200;

	
	
		$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


	$tdatatb_agenda_exame["preparacao"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "preparacao";
//	valor
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 7;
	$fdata["strName"] = "valor";
	$fdata["GoodName"] = "valor";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","valor");
	$fdata["FieldType"] = 14;

	
	
	
			

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

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

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

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

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

	
	
	
	
	
	
	
	
	
	
	
	
		$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["controlWidth"] = 200;

//	Begin validation
	$edata["validateAs"] = array();
	$edata["validateAs"]["basicValidate"] = array();
	$edata["validateAs"]["customMessages"] = array();
				$edata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");
							
	
	//	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


	$tdatatb_agenda_exame["valor"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "valor";
//	status
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 8;
	$fdata["strName"] = "status";
	$fdata["GoodName"] = "status";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","status");
	$fdata["FieldType"] = 3;

	
	
	
			

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

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

	
	
				$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"] = 0;
			$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
		$edata["LCType"] = 0;

	
	
		$edata["LookupValues"] = array();
	$edata["LookupValues"][] = "Agendado";
	$edata["LookupValues"][] = "Aguardado Vaga";
	$edata["LookupValues"][] = "Realizado";

	
		$edata["SelectSize"] = 1;

// End Lookup Settings


		$edata["IsRequired"] = true;

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

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
	
	
		$edata["controlWidth"] = 200;

//	Begin validation
	$edata["validateAs"] = array();
	$edata["validateAs"]["basicValidate"] = array();
	$edata["validateAs"]["customMessages"] = array();
						$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 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


	$tdatatb_agenda_exame["status"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "status";
//	data_resultado
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 9;
	$fdata["strName"] = "data_resultado";
	$fdata["GoodName"] = "data_resultado";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","data_resultado");
	$fdata["FieldType"] = 7;

	
	
	
			

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

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

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

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

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

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

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


	
	



		$edata["IsRequired"] = true;

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

		$edata["maxNumberOfFiles"] = 1;

	
	
		$edata["DateEditType"] = 5;
	$edata["InitialYearFactor"] = 100;
	$edata["LastYearFactor"] = 10;

	
	
	
		$edata["controlWidth"] = 200;

//	Begin validation
	$edata["validateAs"] = array();
	$edata["validateAs"]["basicValidate"] = array();
	$edata["validateAs"]["customMessages"] = array();
						$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 default search options list
				$fdata["searchOptionsList"] = array("Equals", "More than", "Less than", "Between", EMPTY_SEARCH, 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


	$tdatatb_agenda_exame["data_resultado"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "data_resultado";
//	Tipo_retirada
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 10;
	$fdata["strName"] = "Tipo_retirada";
	$fdata["GoodName"] = "Tipo_retirada";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","Tipo_retirada");
	$fdata["FieldType"] = 200;

	
	
	
			

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

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

	
	
				$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"] = 0;
			$edata["autoCompleteFieldsOnEdit"] = 0;
	$edata["autoCompleteFields"] = array();
		$edata["LCType"] = 0;

	
	
		$edata["LookupValues"] = array();
	$edata["LookupValues"][] = "Retirar";
	$edata["LookupValues"][] = "Envio Digital";
	$edata["LookupValues"][] = "Envio Digital/Médico";

	
		$edata["SelectSize"] = 1;

// End Lookup Settings


		$edata["IsRequired"] = true;

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

		$edata["maxNumberOfFiles"] = 1;

	
	
	
	
	
	
		$edata["controlWidth"] = 200;

//	Begin validation
	$edata["validateAs"] = array();
	$edata["validateAs"]["basicValidate"] = array();
	$edata["validateAs"]["customMessages"] = array();
						$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 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


	$tdatatb_agenda_exame["Tipo_retirada"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "Tipo_retirada";
//	copia_pdf
//	Custom field settings
	$fdata = array();
	$fdata["Index"] = 11;
	$fdata["strName"] = "copia_pdf";
	$fdata["GoodName"] = "copia_pdf";
	$fdata["ownerTable"] = "tb_agenda_exame";
	$fdata["Label"] = GetFieldLabel("tb_agenda_exame","copia_pdf");
	$fdata["FieldType"] = 201;

	
	
	
			

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

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

	
	
				$fdata["UploadFolder"] = "uploads\\exames\\protocolos";

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

	$vdata = array("ViewFormat" => "File-based Image");

	
	
				$vdata["ShowThumbnail"] = true;
	$vdata["ThumbWidth"] = 200;
	$vdata["ThumbHeight"] = 150;
	$vdata["ImageWidth"] = 600;
	$vdata["ImageHeight"] = 400;

			$vdata["multipleImgMode"] = 1;
	$vdata["maxImages"] = 0;

			$vdata["showGallery"] = true;
	$vdata["galleryMode"] = 2;
	$vdata["captionMode"] = 2;
	$vdata["captionField"] = "";

	$vdata["imageBorder"] = 1;
	$vdata["imageFullWidth"] = 1;


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

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

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

	$edata = array("EditFormat" => "Document upload");

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


	
	



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

		$edata["maxNumberOfFiles"] = 0;

	
	
	
	
	
	
		$edata["controlWidth"] = 200;

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

		$edata["CreateThumbnail"] = true;
	$edata["StrThumbnail"] = "th";
			$edata["ThumbnailSize"] = 600;

			
	
	
	
	$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


	$tdatatb_agenda_exame["copia_pdf"] = $fdata;
		$tdatatb_agenda_exame[".searchableFields"][] = "copia_pdf";


$tables_data["tb_agenda_exame"]=&$tdatatb_agenda_exame;
$field_labels["tb_agenda_exame"] = &$fieldLabelstb_agenda_exame;
$fieldToolTips["tb_agenda_exame"] = &$fieldToolTipstb_agenda_exame;
$placeHolders["tb_agenda_exame"] = &$placeHolderstb_agenda_exame;
$page_titles["tb_agenda_exame"] = &$pageTitlestb_agenda_exame;

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

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



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

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


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










function createSqlQuery_tb_agenda_exame()
{
$proto0=array();
$proto0["m_strHead"] = "SELECT";
$proto0["m_strFieldList"] = "agendaID,  	exameID,  	laboratorio,  	`data`,  	horario,  	preparacao,  	valor,  	status,  	data_resultado,  	Tipo_retirada,  	copia_pdf";
$proto0["m_strFrom"] = "FROM tb_agenda_exame";
$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" => "agendaID",
	"m_strTable" => "tb_agenda_exame",
	"m_srcTableName" => "tb_agenda_exame"
));

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

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

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

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

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

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

$proto12["m_sql"] = "`data`";
$proto12["m_srcTableName"] = "tb_agenda_exame";
$proto12["m_expr"]=$obj;
$proto12["m_alias"] = "";
$obj = new SQLFieldListItem($proto12);

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

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

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

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

$proto0["m_fieldlist"][]=$obj;
						$proto18=array();
			$obj = new SQLField(array(
	"m_strName" => "valor",
	"m_strTable" => "tb_agenda_exame",
	"m_srcTableName" => "tb_agenda_exame"
));

$proto18["m_sql"] = "valor";
$proto18["m_srcTableName"] = "tb_agenda_exame";
$proto18["m_expr"]=$obj;
$proto18["m_alias"] = "";
$obj = new SQLFieldListItem($proto18);

$proto0["m_fieldlist"][]=$obj;
						$proto20=array();
			$obj = new SQLField(array(
	"m_strName" => "status",
	"m_strTable" => "tb_agenda_exame",
	"m_srcTableName" => "tb_agenda_exame"
));

$proto20["m_sql"] = "status";
$proto20["m_srcTableName"] = "tb_agenda_exame";
$proto20["m_expr"]=$obj;
$proto20["m_alias"] = "";
$obj = new SQLFieldListItem($proto20);

$proto0["m_fieldlist"][]=$obj;
						$proto22=array();
			$obj = new SQLField(array(
	"m_strName" => "data_resultado",
	"m_strTable" => "tb_agenda_exame",
	"m_srcTableName" => "tb_agenda_exame"
));

$proto22["m_sql"] = "data_resultado";
$proto22["m_srcTableName"] = "tb_agenda_exame";
$proto22["m_expr"]=$obj;
$proto22["m_alias"] = "";
$obj = new SQLFieldListItem($proto22);

$proto0["m_fieldlist"][]=$obj;
						$proto24=array();
			$obj = new SQLField(array(
	"m_strName" => "Tipo_retirada",
	"m_strTable" => "tb_agenda_exame",
	"m_srcTableName" => "tb_agenda_exame"
));

$proto24["m_sql"] = "Tipo_retirada";
$proto24["m_srcTableName"] = "tb_agenda_exame";
$proto24["m_expr"]=$obj;
$proto24["m_alias"] = "";
$obj = new SQLFieldListItem($proto24);

$proto0["m_fieldlist"][]=$obj;
						$proto26=array();
			$obj = new SQLField(array(
	"m_strName" => "copia_pdf",
	"m_strTable" => "tb_agenda_exame",
	"m_srcTableName" => "tb_agenda_exame"
));

$proto26["m_sql"] = "copia_pdf";
$proto26["m_srcTableName"] = "tb_agenda_exame";
$proto26["m_expr"]=$obj;
$proto26["m_alias"] = "";
$obj = new SQLFieldListItem($proto26);

$proto0["m_fieldlist"][]=$obj;
$proto0["m_fromlist"] = array();
												$proto28=array();
$proto28["m_link"] = "SQLL_MAIN";
			$proto29=array();
$proto29["m_strName"] = "tb_agenda_exame";
$proto29["m_srcTableName"] = "tb_agenda_exame";
$proto29["m_columns"] = array();
$proto29["m_columns"][] = "agendaID";
$proto29["m_columns"][] = "exameID";
$proto29["m_columns"][] = "laboratorio";
$proto29["m_columns"][] = "data";
$proto29["m_columns"][] = "horario";
$proto29["m_columns"][] = "preparacao";
$proto29["m_columns"][] = "valor";
$proto29["m_columns"][] = "status";
$proto29["m_columns"][] = "data_resultado";
$proto29["m_columns"][] = "Tipo_retirada";
$proto29["m_columns"][] = "copia_pdf";
$obj = new SQLTable($proto29);

$proto28["m_table"] = $obj;
$proto28["m_sql"] = "tb_agenda_exame";
$proto28["m_alias"] = "";
$proto28["m_srcTableName"] = "tb_agenda_exame";
$proto30=array();
$proto30["m_sql"] = "";
$proto30["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

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

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

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

	return $obj;
}
$queryData_tb_agenda_exame = createSqlQuery_tb_agenda_exame();


	
		;

											

$tdatatb_agenda_exame[".sqlquery"] = $queryData_tb_agenda_exame;

$tableEvents["tb_agenda_exame"] = new eventsBase;
$tdatatb_agenda_exame[".hasEvents"] = false;

?>