29 lines
1.1 KiB
PHP
29 lines
1.1 KiB
PHP
<?php require __DIR__ . '/../php/dashboard.php' ?>
|
|
|
|
<header>
|
|
<h1>Gymrooster</h1>
|
|
<h3>Welkom <?=$docent['naam']?></h3>
|
|
<h3><?=date("D d M Y", strtotime($date))?></h3>
|
|
<a href="/dashboard?date=<?=date("Y-m-d", strtotime("-1 day", strtotime($date)))?>">< Dag eerder</a>
|
|
<a href="/dashboard?date=<?=date("Y-m-d", strtotime("+1 day", strtotime($date)))?>">Dag later ></a>
|
|
</header>
|
|
|
|
<form id="submitForm" action="update?date=<?=$date?>&docent=<?=$docent['id']?>" method="post">
|
|
<textarea name="opmerking" placeholder="Opmerkingen"><?=$rooster['opmerking']?></textarea><br>
|
|
<select name="locatie">
|
|
<?php if ($rooster['locatie'] === "1"): ?>
|
|
<option value="1">Binnen</option>
|
|
<option value="2">Buiten</option>
|
|
<?php else: ?>
|
|
<option value="2">Buiten</option>
|
|
<option value="1">Binnen</option>
|
|
<?php endif; ?>
|
|
</select>
|
|
<button type="submit">Opslaan</button>
|
|
</form>
|
|
|
|
<script>
|
|
document.getElementById('submitForm').addEventListener('submit', function(e) {
|
|
document.querySelectorAll('#submitForm button')[0].innerHTML = "✓ Opgeslagen";
|
|
});
|
|
</script>
|