2019-09-12 13:35:16 +00:00
|
|
|
<?php require_once "header.php"; ?>
|
|
|
|
|
2019-09-24 10:04:42 +00:00
|
|
|
<div class="mt-4 mb-4">
|
|
|
|
<h1 class="display-4">Calendrier</h1>
|
|
|
|
</div>
|
|
|
|
|
2019-09-18 22:46:32 +00:00
|
|
|
<?php if (isset($_GET["edit"])) { ?>
|
2019-09-24 10:04:42 +00:00
|
|
|
|
|
|
|
<form method="POST">
|
|
|
|
<div class="form-group row">
|
|
|
|
<label for="inscription">Fin des inscriptions :</label>
|
|
|
|
<div class="form-group col-md-10">
|
|
|
|
<input class="form-control" type="date" id="inscription" name="date_inscription"
|
|
|
|
value="<?= substr($CONFIG->getInscriptionDate(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="inscription" name="time_inscription"
|
|
|
|
value="<?= substr($CONFIG->getInscriptionDate(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group row">
|
|
|
|
<label for="phase1">Dates de la phase 1 :</label>
|
|
|
|
<div class="form-group col-md-5">
|
|
|
|
<input class="form-control" type="date" id="phase1" name="date_start_phase1"
|
|
|
|
value="<?= substr($CONFIG->getStartPhase1Date(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="phase1" name="time_start_phase1"
|
|
|
|
value="<?= substr($CONFIG->getStartPhase1Date(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
<div class="form-group col-md-5">
|
|
|
|
<input class="form-control" type="date" id="phase1" name="date_end_phase1"
|
|
|
|
value="<?= substr($CONFIG->getEndPhase1Date(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="phase1" name="time_end_phase1"
|
|
|
|
value="<?= substr($CONFIG->getEndPhase1Date(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group row">
|
|
|
|
<label for="phase2">Dates de la phase 2 :</label>
|
|
|
|
<div class="form-group col-md-5">
|
|
|
|
<input class="form-control" type="date" id="phase2" name="date_start_phase2"
|
|
|
|
value="<?= substr($CONFIG->getStartPhase2Date(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="phase1" name="time_start_phase2"
|
|
|
|
value="<?= substr($CONFIG->getStartPhase2Date(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
<div class="form-group col-md-5">
|
|
|
|
<input class="form-control" type="date" id="phase2" name="date_end_phase2"
|
|
|
|
value="<?= substr($CONFIG->getEndPhase2Date(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="phase2" name="time_end_phase2"
|
|
|
|
value="<?= substr($CONFIG->getEndPhase2Date(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group row">
|
|
|
|
<label for="phase3">Dates de la phase 3 :</label>
|
|
|
|
<div class="form-group col-md-5">
|
|
|
|
<input class="form-control" type="date" id="phase3" name="date_start_phase3"
|
|
|
|
value="<?= substr($CONFIG->getStartPhase3Date(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="phase3" name="time_start_phase3"
|
|
|
|
value="<?= substr($CONFIG->getStartPhase3Date(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
<div class="form-group col-md-5">
|
|
|
|
<input class="form-control" type="date" id="phase3" name="date_end_phase3"
|
|
|
|
value="<?= substr($CONFIG->getEndPhase3Date(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="phase3" name="time_end_phase3"
|
|
|
|
value="<?= substr($CONFIG->getEndPhase3Date(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group row">
|
|
|
|
<label for="phase4">Dates de la phase 4 :</label>
|
|
|
|
<div class="form-group col-md-5">
|
|
|
|
<input class="form-control" type="date" id="phase4" name="date_start_phase4"
|
|
|
|
value="<?= substr($CONFIG->getStartPhase4Date(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="phase4" name="time_start_phase4"
|
|
|
|
value="<?= substr($CONFIG->getStartPhase4Date(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
<div class="form-group col-md-5">
|
|
|
|
<input class="form-control" type="date" id="phase4" name="date_end_phase4"
|
|
|
|
value="<?= substr($CONFIG->getEndPhase4Date(), 0, 10) ?>"/>
|
|
|
|
<input class="form-control" type="time" id="phase4" name="time_end_phase4"
|
|
|
|
value="<?= substr($CONFIG->getEndPhase4Date(), 11, 5) ?>"/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group row">
|
|
|
|
<input class="btn btn-primary btn-lg btn-block" type="submit" name="update_calendar"
|
|
|
|
value="Mettre à jour le calendrier"/>
|
|
|
|
</div>
|
2019-09-18 22:46:32 +00:00
|
|
|
</form>
|
2019-09-24 10:04:42 +00:00
|
|
|
|
|
|
|
<?php } else { ?>
|
|
|
|
|
|
|
|
<div class="alert alert-<?= Phase::getCurrentPhase() == Phase::INSCRIPTION ? "warning" : "success" ?>">
|
2019-10-04 20:36:23 +00:00
|
|
|
<?= Phase::getTranslatedName(Phase::INSCRIPTION) ?> :
|
2019-09-24 10:04:42 +00:00
|
|
|
<strong><?= formatDate($CONFIG->getInscriptionDate(), true) ?></strong>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="alert alert-<?= Phase::getCurrentPhase() < Phase::PHASE1 ? "danger" : (Phase::getCurrentPhase() == Phase::PHASE1 ? "warning" : "success") ?>">
|
2019-10-04 20:36:23 +00:00
|
|
|
<?= Phase::getTranslatedName(Phase::PHASE1) ?> :
|
2019-09-26 20:24:18 +00:00
|
|
|
Du <strong><?= formatDate($CONFIG->getStartPhase1Date(), true) ?></strong> au
|
|
|
|
<strong><?= formatDate($CONFIG->getEndPhase1Date(), true) ?></strong>
|
2019-09-24 10:04:42 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="alert alert-<?= Phase::getCurrentPhase() < Phase::PHASE2 ? "danger" : (Phase::getCurrentPhase() == Phase::PHASE2 ? "warning" : "success") ?>">
|
2019-10-04 20:36:23 +00:00
|
|
|
<?= Phase::getTranslatedName(Phase::PHASE2) ?> :
|
2019-09-24 10:04:42 +00:00
|
|
|
Du <strong><?= formatDate($CONFIG->getStartPhase2Date(), true) ?></strong> au
|
|
|
|
<strong><?= formatDate($CONFIG->getEndPhase2Date(), true) ?></strong>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="alert alert-<?= Phase::getCurrentPhase() < Phase::PHASE3 ? "danger" : (Phase::getCurrentPhase() == Phase::PHASE3 ? "warning" : "success") ?>">
|
2019-10-04 20:36:23 +00:00
|
|
|
<?= Phase::getTranslatedName(Phase::PHASE3) ?> :
|
2019-09-24 10:04:42 +00:00
|
|
|
Du <strong><?= formatDate($CONFIG->getStartPhase3Date(), true) ?></strong> au
|
|
|
|
<strong><?= formatDate($CONFIG->getEndPhase3Date(), true) ?></strong>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="alert alert-<?= Phase::getCurrentPhase() < Phase::PHASE4 ? "danger" : (Phase::getCurrentPhase() == Phase::PHASE4 ? "warning" : "success") ?>">
|
2019-10-04 20:36:23 +00:00
|
|
|
<?= Phase::getTranslatedName(Phase::PHASE4) ?> :
|
2019-09-24 10:04:42 +00:00
|
|
|
Du <strong><?= formatDate($CONFIG->getStartPhase4Date(), true) ?></strong> au
|
|
|
|
<strong><?= formatDate($CONFIG->getEndPhase4Date(), true) ?></strong>
|
|
|
|
</div>
|
2019-09-18 22:46:32 +00:00
|
|
|
|
2019-10-04 20:36:23 +00:00
|
|
|
<?php if ($_SESSION["role"] == Role::ADMIN) { ?>
|
2019-09-24 10:04:42 +00:00
|
|
|
<!--suppress HtmlUnknownTarget -->
|
|
|
|
<a href="/calendrier/modifier">
|
2019-10-04 20:36:23 +00:00
|
|
|
<button class="btn btn-primary btn-lg btn-block">Modifier le calendrier</button>
|
2019-09-24 10:04:42 +00:00
|
|
|
</a>
|
2019-10-04 20:36:23 +00:00
|
|
|
<?php } ?>
|
|
|
|
|
|
|
|
<hr/>
|
|
|
|
|
2019-10-05 16:26:36 +00:00
|
|
|
<a href="https://correspondances-maths.fr/participer/" target="_blank">
|
2019-10-04 20:36:23 +00:00
|
|
|
<button class="btn btn-primary btn-lg btn-block">
|
|
|
|
Comment participer aux Correspondances ?
|
|
|
|
</button>
|
|
|
|
</a>
|
|
|
|
|
|
|
|
<?php }
|
2019-09-18 22:46:32 +00:00
|
|
|
|
|
|
|
require_once "footer.php";
|