Feature: Filter, wie viele Tage zukünftig Check In / Check Out Angezeigt werden soll
This commit is contained in:
2024-02-29 11:48:04 +01:00
parent 3bc9208c65
commit 8e4bbf130f
4 changed files with 120 additions and 91 deletions

View File

@@ -1,11 +1,9 @@
<?php
require('config.php');
require('EpiApi.php');
require('vendor/autoload.php');
$Epi = new Epirent();
?>
@@ -21,42 +19,47 @@ $Epi = new Epirent();
<!-- Bootstrap -->
<link rel="stylesheet" href="vendor/twbs/bootstrap/dist/css/bootstrap.min.css" >
<script src="scripts/jquery-3.5.1.min.js"></script>
<link href="css/sticky-footer.css" rel="stylesheet">
<link href="css/sticky-footer.css" rel="stylesheet">
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
<script type="text/javascript">
$(document).ready(function(){
refreshCheckOutTable();
refreshCheckInTable();
});
function refreshCheckOutTable(){
$('#getCheckOutTableHolder').load('sources/getCheckOutTable.php', function(){
setTimeout(refreshCheckOutTable, 5000);
});
}
function refreshCheckInTable(){
$('#getCheckInTableHolder').load('sources/getCheckInTable.php', function(){
setTimeout(refreshCheckInTable, 5000);
});
}
</script>
<script type="text/javascript">
$(document).ready(function () {
refreshCheckOutTable();
refreshCheckInTable();
});
function refreshCheckOutTable() {
$('#getCheckOutTableHolder').load('sources/getCheckOutTable.php', function () {
setTimeout(refreshCheckOutTable, 5000);
});
}
function refreshCheckInTable() {
$('#getCheckInTableHolder').load('sources/getCheckInTable.php', function () {
setTimeout(refreshCheckInTable, 5000);
});
}
</script>
</head>
<body style="background-color: black;">
<div class="container-fluid">
<div class="row">
<div class="col-lg">
<h2 class="text-light">Check-Out</h2>
<h2 class="text-light">Check-Out
<?php
if (CheckOut_FutureDays != -1) {
echo "in den nächsten " . CheckOut_FutureDays . " Tagen";
}
?></h2>
<table class="table table-dark">
<thead>
<tr>
@@ -68,7 +71,7 @@ $Epi = new Epirent();
</tr>
</thead>
<tbody id="getCheckOutTableHolder">
</tbody>
</table>
@@ -77,7 +80,12 @@ $Epi = new Epirent();
</div>
<div class="col-lg">
<h2 class="text-light">Check-In</h2>
<h2 class="text-light">Check-In
<?php
if (CheckIn_FutureDays != -1) {
echo "in den nächsten " . CheckIn_FutureDays . " Tagen";
}
?></h2>
<table class="table table-dark">
<thead>
<tr>
@@ -88,8 +96,8 @@ $Epi = new Epirent();
<th scope="col">Dispo-Ende<br><i>RP-Ende</i></th>
</tr>
</thead>
<tbody id="getCheckInTableHolder">
<tbody id="getCheckInTableHolder">
</tbody>
</table>
</div>