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

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

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

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

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

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

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

// Dynamic selection lists
// Form object for search

</script>
<script>

// Write your client script here, no need to add script tags.
</script>
<?php $casesort_delete->showPageHeader(); ?>
<?php
$casesort_delete->showMessage();
?>
<form name="fcasesortdelete" id="fcasesortdelete" class="form-inline ew-form ew-delete-form" action="<?php echo CurrentPageName() ?>" method="post">
<?php if ($casesort_delete->CheckToken) { ?>
<input type="hidden" name="<?php echo TOKEN_NAME ?>" value="<?php echo $casesort_delete->Token ?>">
<?php } ?>
<input type="hidden" name="t" value="casesort">
<input type="hidden" name="action" id="action" value="delete">
<?php foreach ($casesort_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 ($casesort->CaseSortID->Visible) { // CaseSortID ?>
		<th class="<?php echo $casesort->CaseSortID->headerCellClass() ?>"><span id="elh_casesort_CaseSortID" class="casesort_CaseSortID"><?php echo $casesort->CaseSortID->caption() ?></span></th>
<?php } ?>
<?php if ($casesort->CaseSort->Visible) { // CaseSort ?>
		<th class="<?php echo $casesort->CaseSort->headerCellClass() ?>"><span id="elh_casesort_CaseSort" class="casesort_CaseSort"><?php echo $casesort->CaseSort->caption() ?></span></th>
<?php } ?>
<?php if ($casesort->CaseSortEn->Visible) { // CaseSortEn ?>
		<th class="<?php echo $casesort->CaseSortEn->headerCellClass() ?>"><span id="elh_casesort_CaseSortEn" class="casesort_CaseSortEn"><?php echo $casesort->CaseSortEn->caption() ?></span></th>
<?php } ?>
<?php if ($casesort->Notes->Visible) { // Notes ?>
		<th class="<?php echo $casesort->Notes->headerCellClass() ?>"><span id="elh_casesort_Notes" class="casesort_Notes"><?php echo $casesort->Notes->caption() ?></span></th>
<?php } ?>
	</tr>
	</thead>
	<tbody>
<?php
$casesort_delete->RecCnt = 0;
$i = 0;
while (!$casesort_delete->Recordset->EOF) {
	$casesort_delete->RecCnt++;
	$casesort_delete->RowCnt++;

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

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

	// Render row
	$casesort_delete->renderRow();
?>
	<tr<?php echo $casesort->rowAttributes() ?>>
<?php if ($casesort->CaseSortID->Visible) { // CaseSortID ?>
		<td<?php echo $casesort->CaseSortID->cellAttributes() ?>>
<span id="el<?php echo $casesort_delete->RowCnt ?>_casesort_CaseSortID" class="casesort_CaseSortID">
<span<?php echo $casesort->CaseSortID->viewAttributes() ?>>
<?php echo $casesort->CaseSortID->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($casesort->CaseSort->Visible) { // CaseSort ?>
		<td<?php echo $casesort->CaseSort->cellAttributes() ?>>
<span id="el<?php echo $casesort_delete->RowCnt ?>_casesort_CaseSort" class="casesort_CaseSort">
<span<?php echo $casesort->CaseSort->viewAttributes() ?>>
<?php echo $casesort->CaseSort->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($casesort->CaseSortEn->Visible) { // CaseSortEn ?>
		<td<?php echo $casesort->CaseSortEn->cellAttributes() ?>>
<span id="el<?php echo $casesort_delete->RowCnt ?>_casesort_CaseSortEn" class="casesort_CaseSortEn">
<span<?php echo $casesort->CaseSortEn->viewAttributes() ?>>
<?php echo $casesort->CaseSortEn->getViewValue() ?></span>
</span>
</td>
<?php } ?>
<?php if ($casesort->Notes->Visible) { // Notes ?>
		<td<?php echo $casesort->Notes->cellAttributes() ?>>
<span id="el<?php echo $casesort_delete->RowCnt ?>_casesort_Notes" class="casesort_Notes">
<span<?php echo $casesort->Notes->viewAttributes() ?>>
<?php echo $casesort->Notes->getViewValue() ?></span>
</span>
</td>
<?php } ?>
	</tr>
<?php
	$casesort_delete->Recordset->moveNext();
}
$casesort_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 $casesort_delete->getReturnUrl() ?>"><?php echo $Language->phrase("CancelBtn") ?></button>
</div>
</form>
<?php
$casesort_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
$casesort_delete->terminate();
?>
