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

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

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

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

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

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

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

// Dynamic selection lists
fnoticesdelete.lists["x_CaseID"] = <?php echo $notices_delete->CaseID->Lookup->toClientList() ?>;
fnoticesdelete.lists["x_CaseID"].options = <?php echo JsonEncode($notices_delete->CaseID->lookupOptions()) ?>;
fnoticesdelete.autoSuggests["x_CaseID"] = <?php echo json_encode(["data" => "ajax=autosuggest"]) ?>;

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

// Write your client script here, no need to add script tags.
</script>
<?php $notices_delete->showPageHeader(); ?>
<?php
$notices_delete->showMessage();
?>
<form name="fnoticesdelete" id="fnoticesdelete" class="form-inline ew-form ew-delete-form" action="<?php echo CurrentPageName() ?>" method="post">
<?php if ($notices_delete->CheckToken) { ?>
<input type="hidden" name="<?php echo TOKEN_NAME ?>" value="<?php echo $notices_delete->Token ?>">
<?php } ?>
<input type="hidden" name="t" value="notices">
<input type="hidden" name="action" id="action" value="delete">
<?php foreach ($notices_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 ($notices->CaseID->Visible) { // CaseID ?>
		<th class="<?php echo $notices->CaseID->headerCellClass() ?>"><span id="elh_notices_CaseID" class="notices_CaseID"><?php echo $notices->CaseID->caption() ?></span></th>
<?php } ?>
<?php if ($notices->Notice->Visible) { // Notice ?>
		<th class="<?php echo $notices->Notice->headerCellClass() ?>"><span id="elh_notices_Notice" class="notices_Notice"><?php echo $notices->Notice->caption() ?></span></th>
<?php } ?>
<?php if ($notices->NoticeDate->Visible) { // NoticeDate ?>
		<th class="<?php echo $notices->NoticeDate->headerCellClass() ?>"><span id="elh_notices_NoticeDate" class="notices_NoticeDate"><?php echo $notices->NoticeDate->caption() ?></span></th>
<?php } ?>
<?php if ($notices->NoticeTime->Visible) { // NoticeTime ?>
		<th class="<?php echo $notices->NoticeTime->headerCellClass() ?>"><span id="elh_notices_NoticeTime" class="notices_NoticeTime"><?php echo $notices->NoticeTime->caption() ?></span></th>
<?php } ?>
<?php if ($notices->PostMan->Visible) { // PostMan ?>
		<th class="<?php echo $notices->PostMan->headerCellClass() ?>"><span id="elh_notices_PostMan" class="notices_PostMan"><?php echo $notices->PostMan->caption() ?></span></th>
<?php } ?>
	</tr>
	</thead>
	<tbody>
<?php
$notices_delete->RecCnt = 0;
$i = 0;
while (!$notices_delete->Recordset->EOF) {
	$notices_delete->RecCnt++;
	$notices_delete->RowCnt++;

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

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

	// Render row
	$notices_delete->renderRow();
?>
	<tr<?php echo $notices->rowAttributes() ?>>
<?php if ($notices->CaseID->Visible) { // CaseID ?>
		<td<?php echo $notices->CaseID->cellAttributes() ?>>
<span id="el<?php echo $notices_delete->RowCnt ?>_notices_CaseID" class="notices_CaseID">
<span<?php echo $notices->CaseID->viewAttributes() ?>>
<?php echo $notices->CaseID->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($notices->Notice->Visible) { // Notice ?>
		<td<?php echo $notices->Notice->cellAttributes() ?>>
<span id="el<?php echo $notices_delete->RowCnt ?>_notices_Notice" class="notices_Notice">
<span<?php echo $notices->Notice->viewAttributes() ?>>
<?php echo $notices->Notice->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($notices->NoticeDate->Visible) { // NoticeDate ?>
		<td<?php echo $notices->NoticeDate->cellAttributes() ?>>
<span id="el<?php echo $notices_delete->RowCnt ?>_notices_NoticeDate" class="notices_NoticeDate">
<span<?php echo $notices->NoticeDate->viewAttributes() ?>>
<?php echo $notices->NoticeDate->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($notices->NoticeTime->Visible) { // NoticeTime ?>
		<td<?php echo $notices->NoticeTime->cellAttributes() ?>>
<span id="el<?php echo $notices_delete->RowCnt ?>_notices_NoticeTime" class="notices_NoticeTime">
<span<?php echo $notices->NoticeTime->viewAttributes() ?>>
<?php echo $notices->NoticeTime->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($notices->PostMan->Visible) { // PostMan ?>
		<td<?php echo $notices->PostMan->cellAttributes() ?>>
<span id="el<?php echo $notices_delete->RowCnt ?>_notices_PostMan" class="notices_PostMan">
<span<?php echo $notices->PostMan->viewAttributes() ?>>
<?php echo $notices->PostMan->getViewValue() ?></span>
</span>
</td>
<?php } ?>
	</tr>
<?php
	$notices_delete->Recordset->moveNext();
}
$notices_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 $notices_delete->getReturnUrl() ?>"><?php echo $Language->phrase("CancelBtn") ?></button>
</div>
</form>
<?php
$notices_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
$notices_delete->terminate();
?>
