Owner settings: add a real delete for Mitarbeiter (barbers)
Test backoffice (smb-crm) / test (push) Successful in 1m40s
Test backoffice (smb-crm) / test (push) Successful in 1m40s
Rename + active-toggle already existed (this session, earlier commit) -- this adds a genuine, permanent delete alongside them, guarded by a confirm() prompt that points to the "Aktiv" checkbox as the reversible alternative for someone just temporarily off. Existing bookings against a deleted resource are left as-is (no FK in this schema, matching its existing convention) -- the owner agenda already falls back to the raw resource_id for a booking whose resource no longer resolves, same as it does today for a deactivated one. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -140,6 +140,12 @@
|
||||
<button type="submit" class="btn btn-small">Speichern</button>
|
||||
</form>
|
||||
|
||||
<form class="inline" method="post"
|
||||
action="{{ url_for('owner_settings.delete_resource', resource_id=r.resource_id) }}"
|
||||
onsubmit="return confirm('{{ r.name }} wirklich löschen? Das kann nicht rückgängig gemacht werden. Zum vorübergehenden Entfernen stattdessen oben „Aktiv" abwählen.');">
|
||||
<button type="submit" class="btn btn-danger btn-small">Mitarbeiter löschen</button>
|
||||
</form>
|
||||
|
||||
<form method="post" action="{{ url_for('owner_settings.update_resource_hours', resource_id=r.resource_id) }}">
|
||||
{% set hours = hours_by_resource.get(r.resource_id, {}) %}
|
||||
{% set day_names = {0: 'Montag', 1: 'Dienstag', 2: 'Mittwoch', 3: 'Donnerstag',
|
||||
|
||||
Reference in New Issue
Block a user