Feat: Refactor assignment filter to modal

This commit is contained in:
Björn Fromme
2023-10-24 11:40:40 +02:00
parent 5e35af9665
commit cb06bcd636
9 changed files with 119 additions and 89 deletions
+17 -5
View File
@@ -3,11 +3,23 @@
{% block title %}Einsatzübersicht{% endblock %}
{% block content %}
<h1 class="text-2xl font-bold pb-4">
Einsatzübersicht
</h1>
{% include '_partials/_filterpanel.html.twig' %}
<div class="flex items-start justify-between">
<h1 class="text-2xl font-bold pb-4">
Einsatzübersicht
</h1>
<button type="button"
class="{{ html_classes('btn btn--small', { 'btn--secondary': filterDto.active }) }}"
{{ stimulus_controller('modal-button', [], [], {'ajax-modal': '#ajax-modal'}) }}
{{ stimulus_action('modal-button', 'ajax', null, {
'title': 'Einsätze filtern',
'url': path('app_common_assignment_filter', { 'r': return_url() })
}) }}>
<div class="flex items-center space-x-1">
{{ icon('filter', 'w-5 h-5 shrink-0') }}
{% if filterDto.active %}<span>{{ filterDto.activeFiltersCount }} Filter aktiv</span>{% endif %}
</div>
</button>
</div>
<div class="data-table-wrapper">
<div class="data-table-wrapper__inner">