<?php
namespace PHPMaker2019\project_germanos;

// Session
if (session_status() !== PHP_SESSION_ACTIVE)
	session_start(); // Init session data

// Output buffering
ob_start(); 

// Autoload
include_once "autoload.php";
?>
<?php

// Write header
WriteHeader(FALSE);

// Create page object
$employeecontact_view = new employeecontact_view();

// Run the page
$employeecontact_view->run();

// Setup login status
SetupLoginStatus();
SetClientVar("login", LoginStatus());

// Global Page Rendering event (in userfn*.php)
Page_Rendering();

// Page Rendering event
$employeecontact_view->Page_Render();
?>
<?php include_once "header.php" ?>
<?php if (!$employeecontact->isExport()) { ?>
<script>

// Form object
currentPageID = ew.PAGE_ID = "view";
var femployeecontactview = currentForm = new ew.Form("femployeecontactview", "view");

// Form_CustomValidate event
femployeecontactview.Form_CustomValidate = function(fobj) { // DO NOT CHANGE THIS LINE!

	// Your custom validation code here, return false if invalid.
	return true;
}

// Use JavaScript validation or not
femployeecontactview.validateRequired = <?php echo json_encode(CLIENT_VALIDATE) ?>;

// Dynamic selection lists
femployeecontactview.lists["x_EmployeeID"] = <?php echo $employeecontact_view->EmployeeID->Lookup->toClientList() ?>;
femployeecontactview.lists["x_EmployeeID"].options = <?php echo JsonEncode($employeecontact_view->EmployeeID->lookupOptions()) ?>;
femployeecontactview.lists["x_ContactTypeID"] = <?php echo $employeecontact_view->ContactTypeID->Lookup->toClientList() ?>;
femployeecontactview.lists["x_ContactTypeID"].options = <?php echo JsonEncode($employeecontact_view->ContactTypeID->lookupOptions()) ?>;
femployeecontactview.lists["x_Primary[]"] = <?php echo $employeecontact_view->Primary->Lookup->toClientList() ?>;
femployeecontactview.lists["x_Primary[]"].options = <?php echo JsonEncode($employeecontact_view->Primary->options(FALSE, TRUE)) ?>;

// Form object for search
</script>
<script>

// Write your client script here, no need to add script tags.
</script>
<?php } ?>
<?php if (!$employeecontact->isExport()) { ?>
<div class="btn-toolbar ew-toolbar">
<?php $employeecontact_view->ExportOptions->render("body") ?>
<?php $employeecontact_view->OtherOptions->render("body") ?>
<div class="clearfix"></div>
</div>
<?php } ?>
<?php $employeecontact_view->showPageHeader(); ?>
<?php
$employeecontact_view->showMessage();
?>
<?php if (!$employeecontact_view->IsModal) { ?>
<?php if (!$employeecontact->isExport()) { ?>
<form name="ew-pager-form" class="form-inline ew-form ew-pager-form" action="<?php echo CurrentPageName() ?>">
<?php if (!isset($employeecontact_view->Pager)) $employeecontact_view->Pager = new PrevNextPager($employeecontact_view->StartRec, $employeecontact_view->DisplayRecs, $employeecontact_view->TotalRecs, $employeecontact_view->AutoHidePager) ?>
<?php if ($employeecontact_view->Pager->RecordCount > 0 && $employeecontact_view->Pager->Visible) { ?>
<div class="ew-pager">
<span><?php echo $Language->Phrase("Page") ?>&nbsp;</span>
<div class="ew-prev-next"><div class="input-group input-group-sm">
<div class="input-group-prepend">
<!-- first page button -->
	<?php if ($employeecontact_view->Pager->FirstButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerFirst") ?>" href="<?php echo $employeecontact_view->pageUrl() ?>start=<?php echo $employeecontact_view->Pager->FirstButton->Start ?>"><i class="icon-first ew-icon"></i></a>
	<?php } else { ?>
	<a class="btn btn-default disabled" title="<?php echo $Language->phrase("PagerFirst") ?>"><i class="icon-first ew-icon"></i></a>
	<?php } ?>
<!-- previous page button -->
	<?php if ($employeecontact_view->Pager->PrevButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerPrevious") ?>" href="<?php echo $employeecontact_view->pageUrl() ?>start=<?php echo $employeecontact_view->Pager->PrevButton->Start ?>"><i class="icon-prev ew-icon"></i></a>
	<?php } else { ?>
	<a class="btn btn-default disabled" title="<?php echo $Language->phrase("PagerPrevious") ?>"><i class="icon-prev ew-icon"></i></a>
	<?php } ?>
</div>
<!-- current page number -->
	<input class="form-control" type="text" name="<?php echo TABLE_PAGE_NO ?>" value="<?php echo $employeecontact_view->Pager->CurrentPage ?>">
<div class="input-group-append">
<!-- next page button -->
	<?php if ($employeecontact_view->Pager->NextButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerNext") ?>" href="<?php echo $employeecontact_view->pageUrl() ?>start=<?php echo $employeecontact_view->Pager->NextButton->Start ?>"><i class="icon-next ew-icon"></i></a>
	<?php } else { ?>
	<a class="btn btn-default disabled" title="<?php echo $Language->phrase("PagerNext") ?>"><i class="icon-next ew-icon"></i></a>
	<?php } ?>
<!-- last page button -->
	<?php if ($employeecontact_view->Pager->LastButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerLast") ?>" href="<?php echo $employeecontact_view->pageUrl() ?>start=<?php echo $employeecontact_view->Pager->LastButton->Start ?>"><i class="icon-last ew-icon"></i></a>
	<?php } else { ?>
	<a class="btn btn-default disabled" title="<?php echo $Language->phrase("PagerLast") ?>"><i class="icon-last ew-icon"></i></a>
	<?php } ?>
</div>
</div>
</div>
<span>&nbsp;<?php echo $Language->Phrase("of") ?>&nbsp;<?php echo $employeecontact_view->Pager->PageCount ?></span>
<div class="clearfix"></div>
</div>
<?php } ?>
<div class="clearfix"></div>
</form>
<?php } ?>
<?php } ?>
<form name="femployeecontactview" id="femployeecontactview" class="form-inline ew-form ew-view-form" action="<?php echo CurrentPageName() ?>" method="post">
<?php if ($employeecontact_view->CheckToken) { ?>
<input type="hidden" name="<?php echo TOKEN_NAME ?>" value="<?php echo $employeecontact_view->Token ?>">
<?php } ?>
<input type="hidden" name="t" value="employeecontact">
<input type="hidden" name="modal" value="<?php echo (int)$employeecontact_view->IsModal ?>">
<table class="table table-striped table-sm ew-view-table">
<?php if ($employeecontact->EmployeeID->Visible) { // EmployeeID ?>
	<tr id="r_EmployeeID">
		<td class="<?php echo $employeecontact_view->TableLeftColumnClass ?>"><span id="elh_employeecontact_EmployeeID"><?php echo $employeecontact->EmployeeID->caption() ?></span></td>
		<td data-name="EmployeeID"<?php echo $employeecontact->EmployeeID->cellAttributes() ?>>
<span id="el_employeecontact_EmployeeID">
<span<?php echo $employeecontact->EmployeeID->viewAttributes() ?>>
<?php echo $employeecontact->EmployeeID->getViewValue() ?></span>
</span>
</td>
	</tr>
<?php } ?>
<?php if ($employeecontact->ContactTypeID->Visible) { // ContactTypeID ?>
	<tr id="r_ContactTypeID">
		<td class="<?php echo $employeecontact_view->TableLeftColumnClass ?>"><span id="elh_employeecontact_ContactTypeID"><?php echo $employeecontact->ContactTypeID->caption() ?></span></td>
		<td data-name="ContactTypeID"<?php echo $employeecontact->ContactTypeID->cellAttributes() ?>>
<span id="el_employeecontact_ContactTypeID">
<span<?php echo $employeecontact->ContactTypeID->viewAttributes() ?>>
<?php echo $employeecontact->ContactTypeID->getViewValue() ?></span>
</span>
</td>
	</tr>
<?php } ?>
<?php if ($employeecontact->Contact->Visible) { // Contact ?>
	<tr id="r_Contact">
		<td class="<?php echo $employeecontact_view->TableLeftColumnClass ?>"><span id="elh_employeecontact_Contact"><?php echo $employeecontact->Contact->caption() ?></span></td>
		<td data-name="Contact"<?php echo $employeecontact->Contact->cellAttributes() ?>>
<span id="el_employeecontact_Contact">
<span<?php echo $employeecontact->Contact->viewAttributes() ?>>
<?php echo $employeecontact->Contact->getViewValue() ?></span>
</span>
</td>
	</tr>
<?php } ?>
<?php if ($employeecontact->Notes->Visible) { // Notes ?>
	<tr id="r_Notes">
		<td class="<?php echo $employeecontact_view->TableLeftColumnClass ?>"><span id="elh_employeecontact_Notes"><?php echo $employeecontact->Notes->caption() ?></span></td>
		<td data-name="Notes"<?php echo $employeecontact->Notes->cellAttributes() ?>>
<span id="el_employeecontact_Notes">
<span<?php echo $employeecontact->Notes->viewAttributes() ?>>
<?php echo $employeecontact->Notes->getViewValue() ?></span>
</span>
</td>
	</tr>
<?php } ?>
<?php if ($employeecontact->Primary->Visible) { // Primary ?>
	<tr id="r_Primary">
		<td class="<?php echo $employeecontact_view->TableLeftColumnClass ?>"><span id="elh_employeecontact_Primary"><?php echo $employeecontact->Primary->caption() ?></span></td>
		<td data-name="Primary"<?php echo $employeecontact->Primary->cellAttributes() ?>>
<span id="el_employeecontact_Primary">
<span<?php echo $employeecontact->Primary->viewAttributes() ?>>
<?php if (ConvertToBool($employeecontact->Primary->CurrentValue)) { ?>
<input type="checkbox" value="<?php echo $employeecontact->Primary->getViewValue() ?>" disabled checked>
<?php } else { ?>
<input type="checkbox" value="<?php echo $employeecontact->Primary->getViewValue() ?>" disabled>
<?php } ?>
</span>
</span>
</td>
	</tr>
<?php } ?>
</table>
<?php if (!$employeecontact_view->IsModal) { ?>
<?php if (!$employeecontact->isExport()) { ?>
<?php if (!isset($employeecontact_view->Pager)) $employeecontact_view->Pager = new PrevNextPager($employeecontact_view->StartRec, $employeecontact_view->DisplayRecs, $employeecontact_view->TotalRecs, $employeecontact_view->AutoHidePager) ?>
<?php if ($employeecontact_view->Pager->RecordCount > 0 && $employeecontact_view->Pager->Visible) { ?>
<div class="ew-pager">
<span><?php echo $Language->Phrase("Page") ?>&nbsp;</span>
<div class="ew-prev-next"><div class="input-group input-group-sm">
<div class="input-group-prepend">
<!-- first page button -->
	<?php if ($employeecontact_view->Pager->FirstButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerFirst") ?>" href="<?php echo $employeecontact_view->pageUrl() ?>start=<?php echo $employeecontact_view->Pager->FirstButton->Start ?>"><i class="icon-first ew-icon"></i></a>
	<?php } else { ?>
	<a class="btn btn-default disabled" title="<?php echo $Language->phrase("PagerFirst") ?>"><i class="icon-first ew-icon"></i></a>
	<?php } ?>
<!-- previous page button -->
	<?php if ($employeecontact_view->Pager->PrevButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerPrevious") ?>" href="<?php echo $employeecontact_view->pageUrl() ?>start=<?php echo $employeecontact_view->Pager->PrevButton->Start ?>"><i class="icon-prev ew-icon"></i></a>
	<?php } else { ?>
	<a class="btn btn-default disabled" title="<?php echo $Language->phrase("PagerPrevious") ?>"><i class="icon-prev ew-icon"></i></a>
	<?php } ?>
</div>
<!-- current page number -->
	<input class="form-control" type="text" name="<?php echo TABLE_PAGE_NO ?>" value="<?php echo $employeecontact_view->Pager->CurrentPage ?>">
<div class="input-group-append">
<!-- next page button -->
	<?php if ($employeecontact_view->Pager->NextButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerNext") ?>" href="<?php echo $employeecontact_view->pageUrl() ?>start=<?php echo $employeecontact_view->Pager->NextButton->Start ?>"><i class="icon-next ew-icon"></i></a>
	<?php } else { ?>
	<a class="btn btn-default disabled" title="<?php echo $Language->phrase("PagerNext") ?>"><i class="icon-next ew-icon"></i></a>
	<?php } ?>
<!-- last page button -->
	<?php if ($employeecontact_view->Pager->LastButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerLast") ?>" href="<?php echo $employeecontact_view->pageUrl() ?>start=<?php echo $employeecontact_view->Pager->LastButton->Start ?>"><i class="icon-last ew-icon"></i></a>
	<?php } else { ?>
	<a class="btn btn-default disabled" title="<?php echo $Language->phrase("PagerLast") ?>"><i class="icon-last ew-icon"></i></a>
	<?php } ?>
</div>
</div>
</div>
<span>&nbsp;<?php echo $Language->Phrase("of") ?>&nbsp;<?php echo $employeecontact_view->Pager->PageCount ?></span>
<div class="clearfix"></div>
</div>
<?php } ?>
<div class="clearfix"></div>
<?php } ?>
<?php } ?>
</form>
<?php
$employeecontact_view->showPageFooter();
if (DEBUG_ENABLED)
	echo GetDebugMessage();
?>
<?php if (!$employeecontact->isExport()) { ?>
<script>

// Write your table-specific startup script here
// document.write("page loaded");

</script>
<?php } ?>
<?php include_once "footer.php" ?>
<?php
$employeecontact_view->terminate();
?>
