<?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
$employeeaddress_delete = new employeeaddress_delete();

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

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

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

// Page Rendering event
$employeeaddress_delete->Page_Render();
?>
<?php include_once "header.php" ?>
<script>

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

// Form_CustomValidate event
femployeeaddressdelete.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
femployeeaddressdelete.validateRequired = <?php echo json_encode(CLIENT_VALIDATE) ?>;

// Dynamic selection lists
femployeeaddressdelete.lists["x_EmployeeID"] = <?php echo $employeeaddress_delete->EmployeeID->Lookup->toClientList() ?>;
femployeeaddressdelete.lists["x_EmployeeID"].options = <?php echo JsonEncode($employeeaddress_delete->EmployeeID->lookupOptions()) ?>;
femployeeaddressdelete.lists["x_AddressTypeID"] = <?php echo $employeeaddress_delete->AddressTypeID->Lookup->toClientList() ?>;
femployeeaddressdelete.lists["x_AddressTypeID"].options = <?php echo JsonEncode($employeeaddress_delete->AddressTypeID->lookupOptions()) ?>;
femployeeaddressdelete.lists["x_Primary[]"] = <?php echo $employeeaddress_delete->Primary->Lookup->toClientList() ?>;
femployeeaddressdelete.lists["x_Primary[]"].options = <?php echo JsonEncode($employeeaddress_delete->Primary->options(FALSE, TRUE)) ?>;

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

// Write your client script here, no need to add script tags.
</script>
<?php $employeeaddress_delete->showPageHeader(); ?>
<?php
$employeeaddress_delete->showMessage();
?>
<form name="femployeeaddressdelete" id="femployeeaddressdelete" class="form-inline ew-form ew-delete-form" action="<?php echo CurrentPageName() ?>" method="post">
<?php if ($employeeaddress_delete->CheckToken) { ?>
<input type="hidden" name="<?php echo TOKEN_NAME ?>" value="<?php echo $employeeaddress_delete->Token ?>">
<?php } ?>
<input type="hidden" name="t" value="employeeaddress">
<input type="hidden" name="action" id="action" value="delete">
<?php foreach ($employeeaddress_delete->RecKeys as $key) { ?>
<?php $keyvalue = is_array($key) ? implode($COMPOSITE_KEY_SEPARATOR, $key) : $key; ?>
<input type="hidden" name="key_m[]" value="<?php echo HtmlEncode($keyvalue) ?>">
<?php } ?>
<div class="card ew-card ew-grid">
<div class="<?php if (IsResponsiveLayout()) { ?>table-responsive <?php } ?>card-body ew-grid-middle-panel">
<table class="table ew-table">
	<thead>
	<tr class="ew-table-header">
<?php if ($employeeaddress->EmployeeID->Visible) { // EmployeeID ?>
		<th class="<?php echo $employeeaddress->EmployeeID->headerCellClass() ?>"><span id="elh_employeeaddress_EmployeeID" class="employeeaddress_EmployeeID"><?php echo $employeeaddress->EmployeeID->caption() ?></span></th>
<?php } ?>
<?php if ($employeeaddress->AddressTypeID->Visible) { // AddressTypeID ?>
		<th class="<?php echo $employeeaddress->AddressTypeID->headerCellClass() ?>"><span id="elh_employeeaddress_AddressTypeID" class="employeeaddress_AddressTypeID"><?php echo $employeeaddress->AddressTypeID->caption() ?></span></th>
<?php } ?>
<?php if ($employeeaddress->Address->Visible) { // Address ?>
		<th class="<?php echo $employeeaddress->Address->headerCellClass() ?>"><span id="elh_employeeaddress_Address" class="employeeaddress_Address"><?php echo $employeeaddress->Address->caption() ?></span></th>
<?php } ?>
<?php if ($employeeaddress->City->Visible) { // City ?>
		<th class="<?php echo $employeeaddress->City->headerCellClass() ?>"><span id="elh_employeeaddress_City" class="employeeaddress_City"><?php echo $employeeaddress->City->caption() ?></span></th>
<?php } ?>
<?php if ($employeeaddress->Region->Visible) { // Region ?>
		<th class="<?php echo $employeeaddress->Region->headerCellClass() ?>"><span id="elh_employeeaddress_Region" class="employeeaddress_Region"><?php echo $employeeaddress->Region->caption() ?></span></th>
<?php } ?>
<?php if ($employeeaddress->PostalCode->Visible) { // PostalCode ?>
		<th class="<?php echo $employeeaddress->PostalCode->headerCellClass() ?>"><span id="elh_employeeaddress_PostalCode" class="employeeaddress_PostalCode"><?php echo $employeeaddress->PostalCode->caption() ?></span></th>
<?php } ?>
<?php if ($employeeaddress->Country->Visible) { // Country ?>
		<th class="<?php echo $employeeaddress->Country->headerCellClass() ?>"><span id="elh_employeeaddress_Country" class="employeeaddress_Country"><?php echo $employeeaddress->Country->caption() ?></span></th>
<?php } ?>
<?php if ($employeeaddress->Notes->Visible) { // Notes ?>
		<th class="<?php echo $employeeaddress->Notes->headerCellClass() ?>"><span id="elh_employeeaddress_Notes" class="employeeaddress_Notes"><?php echo $employeeaddress->Notes->caption() ?></span></th>
<?php } ?>
<?php if ($employeeaddress->Primary->Visible) { // Primary ?>
		<th class="<?php echo $employeeaddress->Primary->headerCellClass() ?>"><span id="elh_employeeaddress_Primary" class="employeeaddress_Primary"><?php echo $employeeaddress->Primary->caption() ?></span></th>
<?php } ?>
	</tr>
	</thead>
	<tbody>
<?php
$employeeaddress_delete->RecCnt = 0;
$i = 0;
while (!$employeeaddress_delete->Recordset->EOF) {
	$employeeaddress_delete->RecCnt++;
	$employeeaddress_delete->RowCnt++;

	// Set row properties
	$employeeaddress->resetAttributes();
	$employeeaddress->RowType = ROWTYPE_VIEW; // View

	// Get the field contents
	$employeeaddress_delete->loadRowValues($employeeaddress_delete->Recordset);

	// Render row
	$employeeaddress_delete->renderRow();
?>
	<tr<?php echo $employeeaddress->rowAttributes() ?>>
<?php if ($employeeaddress->EmployeeID->Visible) { // EmployeeID ?>
		<td<?php echo $employeeaddress->EmployeeID->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_EmployeeID" class="employeeaddress_EmployeeID">
<span<?php echo $employeeaddress->EmployeeID->viewAttributes() ?>>
<?php echo $employeeaddress->EmployeeID->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($employeeaddress->AddressTypeID->Visible) { // AddressTypeID ?>
		<td<?php echo $employeeaddress->AddressTypeID->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_AddressTypeID" class="employeeaddress_AddressTypeID">
<span<?php echo $employeeaddress->AddressTypeID->viewAttributes() ?>>
<?php echo $employeeaddress->AddressTypeID->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($employeeaddress->Address->Visible) { // Address ?>
		<td<?php echo $employeeaddress->Address->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_Address" class="employeeaddress_Address">
<span<?php echo $employeeaddress->Address->viewAttributes() ?>>
<?php echo $employeeaddress->Address->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($employeeaddress->City->Visible) { // City ?>
		<td<?php echo $employeeaddress->City->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_City" class="employeeaddress_City">
<span<?php echo $employeeaddress->City->viewAttributes() ?>>
<?php echo $employeeaddress->City->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($employeeaddress->Region->Visible) { // Region ?>
		<td<?php echo $employeeaddress->Region->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_Region" class="employeeaddress_Region">
<span<?php echo $employeeaddress->Region->viewAttributes() ?>>
<?php echo $employeeaddress->Region->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($employeeaddress->PostalCode->Visible) { // PostalCode ?>
		<td<?php echo $employeeaddress->PostalCode->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_PostalCode" class="employeeaddress_PostalCode">
<span<?php echo $employeeaddress->PostalCode->viewAttributes() ?>>
<?php echo $employeeaddress->PostalCode->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($employeeaddress->Country->Visible) { // Country ?>
		<td<?php echo $employeeaddress->Country->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_Country" class="employeeaddress_Country">
<span<?php echo $employeeaddress->Country->viewAttributes() ?>>
<?php echo $employeeaddress->Country->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($employeeaddress->Notes->Visible) { // Notes ?>
		<td<?php echo $employeeaddress->Notes->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_Notes" class="employeeaddress_Notes">
<span<?php echo $employeeaddress->Notes->viewAttributes() ?>>
<?php echo $employeeaddress->Notes->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($employeeaddress->Primary->Visible) { // Primary ?>
		<td<?php echo $employeeaddress->Primary->cellAttributes() ?>>
<span id="el<?php echo $employeeaddress_delete->RowCnt ?>_employeeaddress_Primary" class="employeeaddress_Primary">
<span<?php echo $employeeaddress->Primary->viewAttributes() ?>>
<?php if (ConvertToBool($employeeaddress->Primary->CurrentValue)) { ?>
<input type="checkbox" value="<?php echo $employeeaddress->Primary->getViewValue() ?>" disabled checked>
<?php } else { ?>
<input type="checkbox" value="<?php echo $employeeaddress->Primary->getViewValue() ?>" disabled>
<?php } ?>
</span>
</span>
</td>
<?php } ?>
	</tr>
<?php
	$employeeaddress_delete->Recordset->moveNext();
}
$employeeaddress_delete->Recordset->close();
?>
</tbody>
</table>
</div>
</div>
<div>
<button class="btn btn-primary ew-btn" name="btn-action" id="btn-action" type="submit"><?php echo $Language->phrase("DeleteBtn") ?></button>
<button class="btn btn-default ew-btn" name="btn-cancel" id="btn-cancel" type="button" data-href="<?php echo $employeeaddress_delete->getReturnUrl() ?>"><?php echo $Language->phrase("CancelBtn") ?></button>
</div>
</form>
<?php
$employeeaddress_delete->showPageFooter();
if (DEBUG_ENABLED)
	echo GetDebugMessage();
?>
<script>

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

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