<?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_edit = new employeeaddress_edit();

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

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

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

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

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

// Validate form
femployeeaddressedit.validate = function() {
	if (!this.validateRequired)
		return true; // Ignore validation
	var $ = jQuery, fobj = this.getForm(), $fobj = $(fobj);
	if ($fobj.find("#confirm").val() == "F")
		return true;
	var elm, felm, uelm, addcnt = 0;
	var $k = $fobj.find("#" + this.formKeyCountName); // Get key_count
	var rowcnt = ($k[0]) ? parseInt($k.val(), 10) : 1;
	var startcnt = (rowcnt == 0) ? 0 : 1; // Check rowcnt == 0 => Inline-Add
	var gridinsert = ["insert", "gridinsert"].includes($fobj.find("#action").val()) && $k[0];
	for (var i = startcnt; i <= rowcnt; i++) {
		var infix = ($k[0]) ? String(i) : "";
		$fobj.data("rowindex", infix);
		<?php if ($employeeaddress_edit->AddressID->Required) { ?>
			elm = this.getElements("x" + infix + "_AddressID");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->AddressID->caption(), $employeeaddress->AddressID->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->EmployeeID->Required) { ?>
			elm = this.getElements("x" + infix + "_EmployeeID");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->EmployeeID->caption(), $employeeaddress->EmployeeID->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->AddressTypeID->Required) { ?>
			elm = this.getElements("x" + infix + "_AddressTypeID");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->AddressTypeID->caption(), $employeeaddress->AddressTypeID->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->Address->Required) { ?>
			elm = this.getElements("x" + infix + "_Address");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->Address->caption(), $employeeaddress->Address->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->City->Required) { ?>
			elm = this.getElements("x" + infix + "_City");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->City->caption(), $employeeaddress->City->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->Region->Required) { ?>
			elm = this.getElements("x" + infix + "_Region");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->Region->caption(), $employeeaddress->Region->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->PostalCode->Required) { ?>
			elm = this.getElements("x" + infix + "_PostalCode");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->PostalCode->caption(), $employeeaddress->PostalCode->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->Country->Required) { ?>
			elm = this.getElements("x" + infix + "_Country");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->Country->caption(), $employeeaddress->Country->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->Notes->Required) { ?>
			elm = this.getElements("x" + infix + "_Notes");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->Notes->caption(), $employeeaddress->Notes->RequiredErrorMessage)) ?>");
		<?php } ?>
		<?php if ($employeeaddress_edit->Primary->Required) { ?>
			elm = this.getElements("x" + infix + "_Primary[]");
			if (elm && !ew.isHidden(elm) && !ew.hasValue(elm))
				return this.onError(elm, "<?php echo JsEncode(str_replace("%s", $employeeaddress->Primary->caption(), $employeeaddress->Primary->RequiredErrorMessage)) ?>");
		<?php } ?>

			// Fire Form_CustomValidate event
			if (!this.Form_CustomValidate(fobj))
				return false;
	}

	// Process detail forms
	var dfs = $fobj.find("input[name='detailpage']").get();
	for (var i = 0; i < dfs.length; i++) {
		var df = dfs[i], val = df.value;
		if (val && ew.forms[val])
			if (!ew.forms[val].validate())
				return false;
	}
	return true;
}

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

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

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

// Write your client script here, no need to add script tags.
</script>
<?php $employeeaddress_edit->showPageHeader(); ?>
<?php
$employeeaddress_edit->showMessage();
?>
<?php if (!$employeeaddress_edit->IsModal) { ?>
<form name="ew-pager-form" class="form-inline ew-form ew-pager-form" action="<?php echo CurrentPageName() ?>">
<?php if (!isset($employeeaddress_edit->Pager)) $employeeaddress_edit->Pager = new PrevNextPager($employeeaddress_edit->StartRec, $employeeaddress_edit->DisplayRecs, $employeeaddress_edit->TotalRecs, $employeeaddress_edit->AutoHidePager) ?>
<?php if ($employeeaddress_edit->Pager->RecordCount > 0 && $employeeaddress_edit->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 ($employeeaddress_edit->Pager->FirstButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerFirst") ?>" href="<?php echo $employeeaddress_edit->pageUrl() ?>start=<?php echo $employeeaddress_edit->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 ($employeeaddress_edit->Pager->PrevButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerPrevious") ?>" href="<?php echo $employeeaddress_edit->pageUrl() ?>start=<?php echo $employeeaddress_edit->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 $employeeaddress_edit->Pager->CurrentPage ?>">
<div class="input-group-append">
<!-- next page button -->
	<?php if ($employeeaddress_edit->Pager->NextButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerNext") ?>" href="<?php echo $employeeaddress_edit->pageUrl() ?>start=<?php echo $employeeaddress_edit->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 ($employeeaddress_edit->Pager->LastButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerLast") ?>" href="<?php echo $employeeaddress_edit->pageUrl() ?>start=<?php echo $employeeaddress_edit->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 $employeeaddress_edit->Pager->PageCount ?></span>
<div class="clearfix"></div>
</div>
<?php } ?>
<div class="clearfix"></div>
</form>
<?php } ?>
<form name="femployeeaddressedit" id="femployeeaddressedit" class="<?php echo $employeeaddress_edit->FormClassName ?>" action="<?php echo CurrentPageName() ?>" method="post">
<?php if ($employeeaddress_edit->CheckToken) { ?>
<input type="hidden" name="<?php echo TOKEN_NAME ?>" value="<?php echo $employeeaddress_edit->Token ?>">
<?php } ?>
<input type="hidden" name="t" value="employeeaddress">
<input type="hidden" name="action" id="action" value="update">
<input type="hidden" name="modal" value="<?php echo (int)$employeeaddress_edit->IsModal ?>">
<?php if ($employeeaddress->getCurrentMasterTable() == "employees") { ?>
<input type="hidden" name="<?php echo TABLE_SHOW_MASTER ?>" value="employees">
<input type="hidden" name="fk_EmployeeID" value="<?php echo $employeeaddress->EmployeeID->getSessionValue() ?>">
<?php } ?>
<?php if (!$employeeaddress_edit->IsMobileOrModal) { ?>
<div class="ew-desktop"><!-- desktop -->
<?php } ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
<div class="ew-edit-div"><!-- page* -->
<?php } else { ?>
<table id="tbl_employeeaddressedit" class="table table-striped table-sm ew-desktop-table"><!-- table* -->
<?php } ?>
<?php if ($employeeaddress->EmployeeID->Visible) { // EmployeeID ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_EmployeeID" class="form-group row">
		<label id="elh_employeeaddress_EmployeeID" for="x_EmployeeID" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->EmployeeID->caption() ?><?php echo ($employeeaddress->EmployeeID->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->EmployeeID->cellAttributes() ?>>
<?php if ($employeeaddress->EmployeeID->getSessionValue() <> "") { ?>
<span id="el_employeeaddress_EmployeeID">
<span<?php echo $employeeaddress->EmployeeID->viewAttributes() ?>>
<input type="text" readonly class="form-control-plaintext" value="<?php echo RemoveHtml($employeeaddress->EmployeeID->ViewValue) ?>"></span>
</span>
<input type="hidden" id="x_EmployeeID" name="x_EmployeeID" value="<?php echo HtmlEncode($employeeaddress->EmployeeID->CurrentValue) ?>">
<?php } else { ?>
<span id="el_employeeaddress_EmployeeID">
<div class="input-group">
	<select class="custom-select ew-custom-select" data-table="employeeaddress" data-field="x_EmployeeID" data-value-separator="<?php echo $employeeaddress->EmployeeID->displayValueSeparatorAttribute() ?>" id="x_EmployeeID" name="x_EmployeeID"<?php echo $employeeaddress->EmployeeID->editAttributes() ?>>
		<?php echo $employeeaddress->EmployeeID->selectOptionListHtml("x_EmployeeID") ?>
	</select>
</div>
<?php echo $employeeaddress->EmployeeID->Lookup->getParamTag("p_x_EmployeeID") ?>
</span>
<?php } ?>
<?php echo $employeeaddress->EmployeeID->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_EmployeeID">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_EmployeeID"><?php echo $employeeaddress->EmployeeID->caption() ?><?php echo ($employeeaddress->EmployeeID->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->EmployeeID->cellAttributes() ?>>
<?php if ($employeeaddress->EmployeeID->getSessionValue() <> "") { ?>
<span id="el_employeeaddress_EmployeeID">
<span<?php echo $employeeaddress->EmployeeID->viewAttributes() ?>>
<input type="text" readonly class="form-control-plaintext" value="<?php echo RemoveHtml($employeeaddress->EmployeeID->ViewValue) ?>"></span>
</span>
<input type="hidden" id="x_EmployeeID" name="x_EmployeeID" value="<?php echo HtmlEncode($employeeaddress->EmployeeID->CurrentValue) ?>">
<?php } else { ?>
<span id="el_employeeaddress_EmployeeID">
<div class="input-group">
	<select class="custom-select ew-custom-select" data-table="employeeaddress" data-field="x_EmployeeID" data-value-separator="<?php echo $employeeaddress->EmployeeID->displayValueSeparatorAttribute() ?>" id="x_EmployeeID" name="x_EmployeeID"<?php echo $employeeaddress->EmployeeID->editAttributes() ?>>
		<?php echo $employeeaddress->EmployeeID->selectOptionListHtml("x_EmployeeID") ?>
	</select>
</div>
<?php echo $employeeaddress->EmployeeID->Lookup->getParamTag("p_x_EmployeeID") ?>
</span>
<?php } ?>
<?php echo $employeeaddress->EmployeeID->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress->AddressTypeID->Visible) { // AddressTypeID ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_AddressTypeID" class="form-group row">
		<label id="elh_employeeaddress_AddressTypeID" for="x_AddressTypeID" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->AddressTypeID->caption() ?><?php echo ($employeeaddress->AddressTypeID->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->AddressTypeID->cellAttributes() ?>>
<span id="el_employeeaddress_AddressTypeID">
<div class="input-group">
	<select class="custom-select ew-custom-select" data-table="employeeaddress" data-field="x_AddressTypeID" data-value-separator="<?php echo $employeeaddress->AddressTypeID->displayValueSeparatorAttribute() ?>" id="x_AddressTypeID" name="x_AddressTypeID"<?php echo $employeeaddress->AddressTypeID->editAttributes() ?>>
		<?php echo $employeeaddress->AddressTypeID->selectOptionListHtml("x_AddressTypeID") ?>
	</select>
</div>
<?php echo $employeeaddress->AddressTypeID->Lookup->getParamTag("p_x_AddressTypeID") ?>
</span>
<?php echo $employeeaddress->AddressTypeID->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_AddressTypeID">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_AddressTypeID"><?php echo $employeeaddress->AddressTypeID->caption() ?><?php echo ($employeeaddress->AddressTypeID->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->AddressTypeID->cellAttributes() ?>>
<span id="el_employeeaddress_AddressTypeID">
<div class="input-group">
	<select class="custom-select ew-custom-select" data-table="employeeaddress" data-field="x_AddressTypeID" data-value-separator="<?php echo $employeeaddress->AddressTypeID->displayValueSeparatorAttribute() ?>" id="x_AddressTypeID" name="x_AddressTypeID"<?php echo $employeeaddress->AddressTypeID->editAttributes() ?>>
		<?php echo $employeeaddress->AddressTypeID->selectOptionListHtml("x_AddressTypeID") ?>
	</select>
</div>
<?php echo $employeeaddress->AddressTypeID->Lookup->getParamTag("p_x_AddressTypeID") ?>
</span>
<?php echo $employeeaddress->AddressTypeID->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress->Address->Visible) { // Address ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_Address" class="form-group row">
		<label id="elh_employeeaddress_Address" for="x_Address" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->Address->caption() ?><?php echo ($employeeaddress->Address->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->Address->cellAttributes() ?>>
<span id="el_employeeaddress_Address">
<input type="text" data-table="employeeaddress" data-field="x_Address" name="x_Address" id="x_Address" size="30" maxlength="150" placeholder="<?php echo HtmlEncode($employeeaddress->Address->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->Address->EditValue ?>"<?php echo $employeeaddress->Address->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Address->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_Address">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_Address"><?php echo $employeeaddress->Address->caption() ?><?php echo ($employeeaddress->Address->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->Address->cellAttributes() ?>>
<span id="el_employeeaddress_Address">
<input type="text" data-table="employeeaddress" data-field="x_Address" name="x_Address" id="x_Address" size="30" maxlength="150" placeholder="<?php echo HtmlEncode($employeeaddress->Address->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->Address->EditValue ?>"<?php echo $employeeaddress->Address->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Address->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress->City->Visible) { // City ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_City" class="form-group row">
		<label id="elh_employeeaddress_City" for="x_City" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->City->caption() ?><?php echo ($employeeaddress->City->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->City->cellAttributes() ?>>
<span id="el_employeeaddress_City">
<input type="text" data-table="employeeaddress" data-field="x_City" name="x_City" id="x_City" size="30" maxlength="30" placeholder="<?php echo HtmlEncode($employeeaddress->City->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->City->EditValue ?>"<?php echo $employeeaddress->City->editAttributes() ?>>
</span>
<?php echo $employeeaddress->City->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_City">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_City"><?php echo $employeeaddress->City->caption() ?><?php echo ($employeeaddress->City->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->City->cellAttributes() ?>>
<span id="el_employeeaddress_City">
<input type="text" data-table="employeeaddress" data-field="x_City" name="x_City" id="x_City" size="30" maxlength="30" placeholder="<?php echo HtmlEncode($employeeaddress->City->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->City->EditValue ?>"<?php echo $employeeaddress->City->editAttributes() ?>>
</span>
<?php echo $employeeaddress->City->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress->Region->Visible) { // Region ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_Region" class="form-group row">
		<label id="elh_employeeaddress_Region" for="x_Region" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->Region->caption() ?><?php echo ($employeeaddress->Region->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->Region->cellAttributes() ?>>
<span id="el_employeeaddress_Region">
<input type="text" data-table="employeeaddress" data-field="x_Region" name="x_Region" id="x_Region" size="30" maxlength="30" placeholder="<?php echo HtmlEncode($employeeaddress->Region->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->Region->EditValue ?>"<?php echo $employeeaddress->Region->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Region->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_Region">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_Region"><?php echo $employeeaddress->Region->caption() ?><?php echo ($employeeaddress->Region->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->Region->cellAttributes() ?>>
<span id="el_employeeaddress_Region">
<input type="text" data-table="employeeaddress" data-field="x_Region" name="x_Region" id="x_Region" size="30" maxlength="30" placeholder="<?php echo HtmlEncode($employeeaddress->Region->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->Region->EditValue ?>"<?php echo $employeeaddress->Region->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Region->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress->PostalCode->Visible) { // PostalCode ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_PostalCode" class="form-group row">
		<label id="elh_employeeaddress_PostalCode" for="x_PostalCode" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->PostalCode->caption() ?><?php echo ($employeeaddress->PostalCode->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->PostalCode->cellAttributes() ?>>
<span id="el_employeeaddress_PostalCode">
<input type="text" data-table="employeeaddress" data-field="x_PostalCode" name="x_PostalCode" id="x_PostalCode" size="30" maxlength="10" placeholder="<?php echo HtmlEncode($employeeaddress->PostalCode->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->PostalCode->EditValue ?>"<?php echo $employeeaddress->PostalCode->editAttributes() ?>>
</span>
<?php echo $employeeaddress->PostalCode->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_PostalCode">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_PostalCode"><?php echo $employeeaddress->PostalCode->caption() ?><?php echo ($employeeaddress->PostalCode->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->PostalCode->cellAttributes() ?>>
<span id="el_employeeaddress_PostalCode">
<input type="text" data-table="employeeaddress" data-field="x_PostalCode" name="x_PostalCode" id="x_PostalCode" size="30" maxlength="10" placeholder="<?php echo HtmlEncode($employeeaddress->PostalCode->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->PostalCode->EditValue ?>"<?php echo $employeeaddress->PostalCode->editAttributes() ?>>
</span>
<?php echo $employeeaddress->PostalCode->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress->Country->Visible) { // Country ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_Country" class="form-group row">
		<label id="elh_employeeaddress_Country" for="x_Country" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->Country->caption() ?><?php echo ($employeeaddress->Country->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->Country->cellAttributes() ?>>
<span id="el_employeeaddress_Country">
<input type="text" data-table="employeeaddress" data-field="x_Country" name="x_Country" id="x_Country" size="30" maxlength="20" placeholder="<?php echo HtmlEncode($employeeaddress->Country->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->Country->EditValue ?>"<?php echo $employeeaddress->Country->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Country->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_Country">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_Country"><?php echo $employeeaddress->Country->caption() ?><?php echo ($employeeaddress->Country->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->Country->cellAttributes() ?>>
<span id="el_employeeaddress_Country">
<input type="text" data-table="employeeaddress" data-field="x_Country" name="x_Country" id="x_Country" size="30" maxlength="20" placeholder="<?php echo HtmlEncode($employeeaddress->Country->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->Country->EditValue ?>"<?php echo $employeeaddress->Country->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Country->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress->Notes->Visible) { // Notes ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_Notes" class="form-group row">
		<label id="elh_employeeaddress_Notes" for="x_Notes" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->Notes->caption() ?><?php echo ($employeeaddress->Notes->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->Notes->cellAttributes() ?>>
<span id="el_employeeaddress_Notes">
<input type="text" data-table="employeeaddress" data-field="x_Notes" name="x_Notes" id="x_Notes" size="30" maxlength="100" placeholder="<?php echo HtmlEncode($employeeaddress->Notes->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->Notes->EditValue ?>"<?php echo $employeeaddress->Notes->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Notes->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_Notes">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_Notes"><?php echo $employeeaddress->Notes->caption() ?><?php echo ($employeeaddress->Notes->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->Notes->cellAttributes() ?>>
<span id="el_employeeaddress_Notes">
<input type="text" data-table="employeeaddress" data-field="x_Notes" name="x_Notes" id="x_Notes" size="30" maxlength="100" placeholder="<?php echo HtmlEncode($employeeaddress->Notes->getPlaceHolder()) ?>" value="<?php echo $employeeaddress->Notes->EditValue ?>"<?php echo $employeeaddress->Notes->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Notes->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress->Primary->Visible) { // Primary ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
	<div id="r_Primary" class="form-group row">
		<label id="elh_employeeaddress_Primary" class="<?php echo $employeeaddress_edit->LeftColumnClass ?>"><?php echo $employeeaddress->Primary->caption() ?><?php echo ($employeeaddress->Primary->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></label>
		<div class="<?php echo $employeeaddress_edit->RightColumnClass ?>"><div<?php echo $employeeaddress->Primary->cellAttributes() ?>>
<span id="el_employeeaddress_Primary">
<?php
$selwrk = (ConvertToBool($employeeaddress->Primary->CurrentValue)) ? " checked" : "";
?>
<input type="checkbox" data-table="employeeaddress" data-field="x_Primary" name="x_Primary[]" id="x_Primary[]" value="1"<?php echo $selwrk ?><?php echo $employeeaddress->Primary->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Primary->CustomMsg ?></div></div>
	</div>
<?php } else { ?>
	<tr id="r_Primary">
		<td class="<?php echo $employeeaddress_edit->TableLeftColumnClass ?>"><span id="elh_employeeaddress_Primary"><?php echo $employeeaddress->Primary->caption() ?><?php echo ($employeeaddress->Primary->Required) ? $Language->phrase("FieldRequiredIndicator") : "" ?></span></td>
		<td<?php echo $employeeaddress->Primary->cellAttributes() ?>>
<span id="el_employeeaddress_Primary">
<?php
$selwrk = (ConvertToBool($employeeaddress->Primary->CurrentValue)) ? " checked" : "";
?>
<input type="checkbox" data-table="employeeaddress" data-field="x_Primary" name="x_Primary[]" id="x_Primary[]" value="1"<?php echo $selwrk ?><?php echo $employeeaddress->Primary->editAttributes() ?>>
</span>
<?php echo $employeeaddress->Primary->CustomMsg ?></td>
	</tr>
<?php } ?>
<?php } ?>
<?php if ($employeeaddress_edit->IsMobileOrModal) { ?>
</div><!-- /page* -->
<?php } else { ?>
</table><!-- /table* -->
<?php } ?>
<span id="el_employeeaddress_AddressID">
<input type="hidden" data-table="employeeaddress" data-field="x_AddressID" name="x_AddressID" id="x_AddressID" value="<?php echo HtmlEncode($employeeaddress->AddressID->CurrentValue) ?>">
</span>
<?php if (!$employeeaddress_edit->IsModal) { ?>
<div class="form-group row"><!-- buttons .form-group -->
	<div class="<?php echo $employeeaddress_edit->OffsetColumnClass ?>"><!-- buttons offset -->
<button class="btn btn-primary ew-btn" name="btn-action" id="btn-action" type="submit"><?php echo $Language->phrase("SaveBtn") ?></button>
<button class="btn btn-default ew-btn" name="btn-cancel" id="btn-cancel" type="button" data-href="<?php echo $employeeaddress_edit->getReturnUrl() ?>"><?php echo $Language->phrase("CancelBtn") ?></button>
	</div><!-- /buttons offset -->
</div><!-- /buttons .form-group -->
<?php } ?>
<?php if (!$employeeaddress_edit->IsMobileOrModal) { ?>
</div><!-- /desktop -->
<?php } ?>
<?php if (!$employeeaddress_edit->IsModal) { ?>
<?php if (!isset($employeeaddress_edit->Pager)) $employeeaddress_edit->Pager = new PrevNextPager($employeeaddress_edit->StartRec, $employeeaddress_edit->DisplayRecs, $employeeaddress_edit->TotalRecs, $employeeaddress_edit->AutoHidePager) ?>
<?php if ($employeeaddress_edit->Pager->RecordCount > 0 && $employeeaddress_edit->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 ($employeeaddress_edit->Pager->FirstButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerFirst") ?>" href="<?php echo $employeeaddress_edit->pageUrl() ?>start=<?php echo $employeeaddress_edit->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 ($employeeaddress_edit->Pager->PrevButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerPrevious") ?>" href="<?php echo $employeeaddress_edit->pageUrl() ?>start=<?php echo $employeeaddress_edit->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 $employeeaddress_edit->Pager->CurrentPage ?>">
<div class="input-group-append">
<!-- next page button -->
	<?php if ($employeeaddress_edit->Pager->NextButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerNext") ?>" href="<?php echo $employeeaddress_edit->pageUrl() ?>start=<?php echo $employeeaddress_edit->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 ($employeeaddress_edit->Pager->LastButton->Enabled) { ?>
	<a class="btn btn-default" title="<?php echo $Language->phrase("PagerLast") ?>" href="<?php echo $employeeaddress_edit->pageUrl() ?>start=<?php echo $employeeaddress_edit->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 $employeeaddress_edit->Pager->PageCount ?></span>
<div class="clearfix"></div>
</div>
<?php } ?>
<div class="clearfix"></div>
<?php } ?>
</form>
<?php
$employeeaddress_edit->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_edit->terminate();
?>
