Fixing imports
This commit is contained in:
1 parent
8d37b2ad67
commit
3ebe9a0894
6 files changed
+316
No files matched your search
@@ -0,0 +1,14 @@
|
||||
{% if total %}
|
||||
<p style="color:var(--color-danger,#c00)">
|
||||
Purge complete: {{ total }} row(s) deleted.
|
||||
</p>
|
||||
<ul class="muted">
|
||||
{% for label, n in counts.items() %}
|
||||
{% if n %}
|
||||
<li>{{ label }}: {{ n }}</li>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% else %}
|
||||
<p class="muted">Nothing to purge — the database was already clean.</p>
|
||||
{% endif %}
|
||||
@@ -0,0 +1,32 @@
|
||||
{% extends "base.html" %}
|
||||
{% block title %}Danger Zone · {{ app_name }}{% endblock %}
|
||||
{% block body %}
|
||||
{% include "_nav.html" %}
|
||||
<main class="container">
|
||||
<h1>Danger Zone</h1>
|
||||
|
||||
<div class="card" style="border: 1px solid var(--color-danger, #c00)">
|
||||
<h2>Purge database</h2>
|
||||
<p>
|
||||
Permanently deletes every part, taxonomy entry, attachment point, fit,
|
||||
and imported part in the database — manufacturers, part colours, part
|
||||
types, sub part types, scope models, ISO/UNC threads, clamp/static
|
||||
connections, attachment point names, augmented parts, scope info,
|
||||
attachment points, fits, fit notes, and imported parts.
|
||||
</p>
|
||||
<p>
|
||||
<strong>Not</strong> deleted: users, roles & permissions, refresh
|
||||
tokens, the audit log, and the OData connection configuration.
|
||||
</p>
|
||||
<p class="muted">This cannot be undone. Take a database backup first if you might need this data again.</p>
|
||||
<button class="btn btn-danger"
|
||||
hx-post="/admin/danger-zone/purge"
|
||||
hx-target="#purge-result"
|
||||
hx-swap="innerHTML"
|
||||
hx-confirm="This will PERMANENTLY delete all parts, taxonomy, attachment points, fits, and imported parts. Users and the OData configuration are kept. This cannot be undone. Continue?">
|
||||
Purge all part/fit data
|
||||
</button>
|
||||
<div id="purge-result" style="margin-top:1rem"></div>
|
||||
</div>
|
||||
</main>
|
||||
{% endblock %}
|
||||
Reference in new issue
Block a user