feat(11-01): UIE-02 — dedicated Add Printer page at GET /printers/new
- Create imptune/templates/printers_new.html: full page extending base.html
with plain <form action="/printers" method="post"> (no HTMX, browser follows 303)
and inline driver upload sub-form
- Update imptune/templates/printers.html: remove inline Add Printer form,
add <a href="/printers/new" role="button">Add Printer</a> link
- Add GET /printers/new route in imptune/api/pages.py (placed before /{printer_id})
- Change POST /printers to always return RedirectResponse(url='/printers', status_code=303)
- Update existing POST /printers tests to assert 303 + follow_redirects=False
- Update test_printer_form.py to check /printers/new instead of /printers (UIE-02 arch)
- UIE-02 tests GREEN; UIE-01/03 scaffolds remain RED (expected — not yet implemented)
This commit is contained in:
@@ -3,10 +3,7 @@
|
||||
{% block content %}
|
||||
<h1>Printers</h1>
|
||||
|
||||
<section>
|
||||
<h2>Add Printer</h2>
|
||||
{% include "partials/printer_form.html" %}
|
||||
</section>
|
||||
<p><a href="/printers/new" role="button">Add Printer</a></p>
|
||||
|
||||
<section>
|
||||
<h2>Printer Library</h2>
|
||||
|
||||
Reference in New Issue
Block a user