25 lines
857 B
PHP
25 lines
857 B
PHP
<?php declare(strict_types=1);
|
|
|
|
use MyPrayerJournal\UI\Layout;
|
|
|
|
require '../../../start.php';
|
|
|
|
$req = validate_request($_GET['id'], ['GET'], false);
|
|
|
|
Layout::bareHead(); ?>
|
|
<form hx-post="/request/note?id=<?=$req->id?>">
|
|
<div class="form-floating pb-3">
|
|
<textarea id=notes name=notes class=form-control style="min-height: 8rem;" placeholder=Notes autofocus
|
|
required></textarea>
|
|
<label for=notes>Notes</label>
|
|
</div>
|
|
<p class=text-end><button type=submit class="btn btn-primary">Add Notes</button>
|
|
</form>
|
|
<hr style="margin: .5rem -1rem">
|
|
<div id=priorNotes>
|
|
<p class="text-center pt-3">
|
|
<button type=button class="btn btn-secondary" hx-get="/components/request/notes?id=<?=$req->id?>"
|
|
hx-swap=outerHTML hx-target=#priorNotes>Load Prior Notes</button>
|
|
</div><?php
|
|
Layout::bareFoot();
|