Notes / snooze, update data migration

- WIP on finishing out request list
This commit is contained in:
2024-06-22 20:23:37 -04:00
parent 3ebb03d470
commit 2369827033
11 changed files with 189 additions and 24 deletions

View File

@@ -0,0 +1,28 @@
<?php declare(strict_types=1);
use MyPrayerJournal\{Auth, Layout, Request};
require '../../../start.php';
if ($_SERVER['REQUEST_METHOD'] <> 'GET') not_found();
Auth::requireUser(false);
$req = Request::byId($_GET['id']);
if (!$req) not_found();
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();