85 lines
3.7 KiB
Twig
85 lines
3.7 KiB
Twig
{% extends 'admin/layout.html.twig' %}
|
|
|
|
{% block title %}Einstellungen - Verfügbarkeiten/Zeiträume{% endblock %}
|
|
|
|
{% block content %}
|
|
<h1 class="text-2xl font-bold pb-8">
|
|
Verfügbarkeiten/Zeiträume
|
|
</h1>
|
|
<div class="data-table-wrapper">
|
|
<div class="data-table-wrapper__inner">
|
|
<table class="data-table">
|
|
<thead>
|
|
<tr>
|
|
<th class="w-1/4">
|
|
{{ knp_pagination_sortable(pagination, 'Datum von', 'availability.dateFrom') }}
|
|
</th>
|
|
<th class="w-1/4">
|
|
{{ knp_pagination_sortable(pagination, 'Datum bis', 'availability.dateTo') }}
|
|
</th>
|
|
<th class="w-1/4">
|
|
{{ knp_pagination_sortable(pagination, 'Beschreibung', 'availability.description') }}
|
|
</th>
|
|
<th></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for availability in pagination %}
|
|
<tr>
|
|
<td>
|
|
{{ availability.dateFrom|date('d.m.Y') }}
|
|
</td>
|
|
<td>
|
|
{{ availability.dateTo|date('d.m.Y') }}
|
|
</td>
|
|
<td>
|
|
{{ availability.description|default('-') }}
|
|
</td>
|
|
<td>
|
|
<div class="flex items-center space-x-2 justify-end">
|
|
<button type="button"
|
|
class="text-red-500"
|
|
title="Zeitraum löschen"
|
|
hx-get="{{ path('app_admin_system_availability_delete', { 'id': availability.id }) }}"
|
|
hx-target="body"
|
|
hx-swap="beforeend">
|
|
{{ icon('delete') }}
|
|
</button>
|
|
<button type="button"
|
|
title="Verfügbarkeit bearbeiten"
|
|
hx-get="{{ path('app_admin_system_availability_edit', { 'id': availability.id }) }}"
|
|
hx-target="body"
|
|
hx-swap="beforeend">
|
|
{{ icon('edit') }}
|
|
</button>
|
|
<button type="button"
|
|
title="Verfügbarkeit duplizieren"
|
|
hx-get="{{ path('app_admin_system_availability_duplicate', { 'id': availability.id }) }}"
|
|
hx-target="body"
|
|
hx-swap="beforeend">
|
|
{{ icon('copy') }}
|
|
</button>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
{% else %}
|
|
<tr>
|
|
<td colspan="3">
|
|
Keine Daten...
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
{{ knp_pagination_render(pagination) }}
|
|
</div>
|
|
</div>
|
|
<button type="button"
|
|
class="btn"
|
|
title="Zeitraum hinzufügen"
|
|
hx-get="{{ path('app_admin_system_availability_create') }}"
|
|
hx-target="body"
|
|
hx-swap="beforeend">
|
|
Zeitraum hinzufügen
|
|
</button>
|
|
{% endblock %} |