1
0
Fork 0
This repository has been archived on 2024-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
Accommodation_Management/view/date_accomodation.php

46 lines
2.3 KiB
PHP
Raw Normal View History

2021-01-11 17:30:13 +01:00
<?php
require_once('template/head.php');
?>
2021-01-14 19:01:32 +01:00
<div class="container-fluid section">
2021-01-16 16:12:28 +01:00
<form action="" method="POST">
<div class="card border border-dark mb-3">
<div class="card-body text-dark">
<h3 class="card-title">Gestion des disponibilités de "<?= $accomodation->getName() ?>"</h3>
<div style="margin: auto;">
<?php
$rowCount = 0;
$maxPerRow = 4;
$mdCalc = ceil(12 / $maxPerRow);
foreach ($allRange as $date => $vol) {
if ($rowCount == 0) {
echo '<div class="row" style="padding-top: 15px">';
}
?>
<div class="col-md-<?= $mdCalc ?>">
<label for="<?= $date; ?>"><?=dateToFrench($date, "j F Y");?></label>
<div class="input-group mb-3">
<span class="input-group-text" id="lit<?= $date; ?>">Nb de Lits</span>
<input type="text" class="form-control" placeholder="0" aria-label="lit<?= $date; ?>" name="<?= $date; ?>-beds" value="<?=$vol['beds']?>">
</div>
<div class="input-group mb-3">
<span class="input-group-text" id="<?= $date; ?>">Nb de Chambres</span>
<input type="text" class="form-control" placeholder="0" aria-label="<?= $date; ?>" name="<?= $date; ?>-rooms" value="<?=$vol['rooms']?>">
</div>
</div>
<?php
$rowCount++;
if ($rowCount == $maxPerRow) {
echo '</div>';
$rowCount = 0;
}
}
?>
</div>
</div>
<button type="submit" class="btn-success"><h1>VALIDER</h1></button>
</div>
2021-01-14 19:01:32 +01:00
</form>
</div>
2021-01-11 17:30:13 +01:00
<?php
require_once('template/footer.php');
?>