feat: restyle admin views in corporate design

This commit is contained in:
fromme committed 2026-11-13 11:51:46 +01:00
1 parent c660bd68de
commit 558e45fe5f
19 files changed
+100 -101

No files matched your search

@@ -10,7 +10,7 @@
{{ booking.recordLabel }} · {% include 'admin/accommodation_booking/_status_label.html.twig' %}
{{ booking.groupName }}
</twig:page:heading>
<p class="text-sm text-gray-500 mb-6">{{ booking.accommodation.name }}</p>
<p class="text-sm text-muted mb-6">{{ booking.accommodation.name }}</p>
{# Same arrangement as the edit form: what was booked in the main column, status, the next
step and the actions in a sidebar that stays in view on wide screens. #}
@@ -102,50 +102,50 @@
<aside class="space-y-6 xl:sticky xl:top-8">
<twig:form:section title="Status">
<dl class="grid grid-cols-2 gap-y-1 text-sm">
<dt class="text-gray-500">Status</dt>
<dt class="text-muted">Status</dt>
<dd>{% include 'admin/accommodation_booking/_status_label.html.twig' %}</dd>
<dt class="text-gray-500">Herkunft</dt>
<dt class="text-muted">Herkunft</dt>
<dd>{{ booking.origin.label }}</dd>
{% if booking.managedBy is not null %}
<dt class="text-gray-500">Bearbeiter:in</dt>
<dt class="text-muted">Bearbeiter:in</dt>
<dd>{{ booking.managedBy.displayName }}</dd>
{% endif %}
{% if booking.acceptedAt is not null %}
<dt class="text-gray-500">Angenommen</dt>
<dt class="text-muted">Angenommen</dt>
<dd>{{ booking.acceptedAt | date('d.m.Y, H:i') }}</dd>
{% endif %}
{% if booking.confirmedAt is not null %}
<dt class="text-gray-500">Bestätigt</dt>
<dt class="text-muted">Bestätigt</dt>
<dd>{{ booking.confirmedAt | date('d.m.Y, H:i') }}</dd>
{% endif %}
<dt class="text-gray-500">Eingegangen</dt>
<dt class="text-muted">Eingegangen</dt>
<dd>{{ booking.createdAt | date('d.m.Y, H:i') }}</dd>
{% if booking.updatedAt is not null and booking.updatedAt != booking.createdAt %}
<dt class="text-gray-500">Aktualisiert</dt>
<dt class="text-muted">Aktualisiert</dt>
<dd>{{ booking.updatedAt | date('d.m.Y, H:i') }}</dd>
{% endif %}
</dl>
</twig:form:section>
{# One pink button per page, for the next step; everything else is grey, and the one
{# One magenta button per page, for the next step; everything else is secondary, and the one
destructive action is set apart below the others. #}
{% set has_next_step = booking.draft or booking.requested or booking.received %}
{% if booking.draft or booking.requested %}
<twig:form:section title="Nächster Schritt: Angebot">
<p class="text-sm text-gray-500 mb-3">
<p class="text-sm text-muted mb-3">
Das Angebot wurde dem Kunden noch nicht zugestellt. Beim Versand wird der Zugangslink
erzeugt und die Buchung wartet anschließend auf die Annahme durch den Kunden.
</p>
<div class="flex flex-col gap-2">
<button type="button"
class="button button--primary button--small w-full"
class="btn-primary w-full"
hx-get="{{ path('app_admin_accommodationbooking_send_offer', { id: booking.id }) }}"
hx-target="body"
hx-swap="beforeend">
Angebot per E-Mail senden
</button>
<button type="button"
class="button button--neutral button--small w-full"
class="btn-secondary w-full"
hx-get="{{ path('app_admin_accommodationbooking_generate_access_link', { id: booking.id }) }}"
hx-target="body"
hx-swap="beforeend">
@@ -155,11 +155,11 @@
</twig:form:section>
{% elseif booking.received %}
<twig:form:section title="Nächster Schritt: Bestätigung">
<p class="text-sm text-gray-500 mb-3">
<p class="text-sm text-muted mb-3">
Die Buchung des Kunden ist eingegangen, aber es wurde noch keine Bestätigung verschickt.
</p>
<button type="button"
class="button button--primary button--small w-full"
class="btn-primary w-full"
hx-get="{{ path('app_admin_accommodationbooking_confirm', { id: booking.id }) }}"
hx-target="body"
hx-swap="beforeend">
@@ -170,13 +170,13 @@
<twig:form:section title="Zugangslink">
{% if not booking.customerAccessible %}
<p class="text-sm text-gray-500">
<p class="text-sm text-muted">
Ein Zugangslink wird beim Versand des Angebots erzeugt.
</p>
{% elseif accessLink %}
<div class="grid grid-cols-2 gap-2">
<button type="button"
class="button button--neutral button--small sm:text-xs w-full"
class="btn-secondary w-full"
data-controller="clipboard"
data-clipboard-content-value="{{ accessLink }}"
data-clipboard-label-value="Kopiert!"
@@ -184,21 +184,21 @@
{{ icon('copy', 'w-4 h-4') }} Link kopieren
</button>
<button type="button"
class="button button--neutral button--small sm:text-xs w-full"
class="btn-secondary w-full"
hx-get="{{ path('app_admin_accommodationbooking_send_access_link', { id: booking.id }) }}"
hx-target="body"
hx-swap="beforeend">
Link senden
</button>
</div>
<p class="text-xs text-gray-500 mt-2">
<p class="text-xs text-muted mt-2">
Gültig bis {{ accessLinkExpiresAt | date('d.m.Y') }}
{% if accessLinkExpiresAt < date() %}
<span class="text-red-600 font-medium">(abgelaufen)</span>
{% endif %}
</p>
{% else %}
<p class="text-sm text-gray-500">
<p class="text-sm text-muted">
Der Zugangslink wird beim Versand des Angebots erzeugt.
</p>
{% endif %}
@@ -207,23 +207,23 @@
<twig:form:section title="Aktionen">
<div class="flex flex-col gap-2">
<a href="{{ path('app_admin_accommodationbooking_edit', edit_params) }}"
class="button {{ has_next_step ? 'button--neutral' : 'button--primary' }} button--small w-full">
class="{{ has_next_step ? 'btn-secondary' : 'btn-primary' }} w-full">
bearbeiten
</a>
<button type="button"
class="button button--neutral button--small w-full"
class="btn-secondary w-full"
hx-get="{{ path('app_admin_accommodationbooking_duplicate', edit_params) }}"
hx-target="body"
hx-swap="beforeend">
duplizieren
</button>
<a href="{{ path('app_admin_accommodationbooking_pdf', { 'id': booking.id }) }}"
class="button button--neutral button--small w-full">
class="btn-secondary w-full">
PDF herunterladen
</a>
</div>
{% if not booking.confirmed and not booking.discarded %}
<div class="mt-4 pt-3 border-t border-gray-200 text-center">
<div class="mt-4 pt-3 border-t border-line text-center">
<button type="button"
class="text-sm font-medium text-red-600 hover:underline"
hx-get="{{ path('app_admin_accommodationbooking_discard', { id: booking.id }) }}"
@@ -235,7 +235,7 @@
{% endif %}
</twig:form:section>
<a href="{{ returnUrl }}" class="inline-block text-sm text-gray-500 hover:text-gray-900 hover:underline">
<a href="{{ returnUrl }}" class="inline-block text-sm text-muted hover:text-ink hover:underline">
← zurück
</a>
</aside>