feat: dedicated list view for document batch downloading
This commit is contained in:
@@ -0,0 +1,113 @@
|
||||
{% extends 'administrative/layout.html.twig' %}
|
||||
|
||||
{% block title %}Dokumentenübersicht{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="flex items-start justify-between pb-4">
|
||||
<h1 class="text-2xl font-bold">
|
||||
{% if type == constant('App\\Entity\\Upload::TYPE_INVOICE') %}
|
||||
Übersicht akzeptierte Honorarnoten
|
||||
{% elseif type == constant('App\\Entity\\Upload::TYPE_CONTRACT') %}
|
||||
Übersicht geprüfte Honorarverträge
|
||||
{% else %}
|
||||
Übersicht
|
||||
{% endif %}
|
||||
</h1>
|
||||
<div class="flex flex-col items-end space-y-2 md:flex-row md:items-center md:space-x-2 md:space-y-0">
|
||||
<a href="{{ path('app_administrative_document_batch_download', { 'type': type, 'status': status }) }}"
|
||||
class="btn btn--small">
|
||||
{{ icon('download', 'w-4 h-4 shrink-0') }}
|
||||
<span>alle herunterladen</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="data-table-wrapper">
|
||||
<div class="data-table-wrapper__inner">
|
||||
<table class="data-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>
|
||||
{{ knp_pagination_sortable(pagination, 'Einsatz­zeitraum', 'destination.dateFrom') }}
|
||||
</th>
|
||||
<th>
|
||||
{{ knp_pagination_sortable(pagination, 'Destination', 'destination.product') }}
|
||||
</th>
|
||||
<th>
|
||||
{{ knp_pagination_sortable(pagination, 'Jobprofil', 'job_profile.name') }}
|
||||
</th>
|
||||
<th>
|
||||
{{ knp_pagination_sortable(pagination, 'Dokument', 'upload.type') }}
|
||||
</th>
|
||||
<th>
|
||||
{{ knp_pagination_sortable(pagination, 'Teamer:in', 'teamer.lastName') }}
|
||||
</th>
|
||||
<th>
|
||||
{{ knp_pagination_sortable(pagination, 'Status', 'upload.status') }}
|
||||
</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for upload in pagination %}
|
||||
{% set disposition = upload.disposition %}
|
||||
{% set assignment = disposition.assignment %}
|
||||
<tr>
|
||||
<td>
|
||||
{{ assignment.destination.dateFrom|date('d.m.Y') }}
|
||||
-
|
||||
{{ assignment.destination.dateTo|date('d.m.Y') }}
|
||||
</td>
|
||||
<td>
|
||||
<div class="flex items-start space-x-2">
|
||||
{{ icon('flag-' ~ assignment.destination.country, 'w-5 h-5 shrink-0') }}
|
||||
<div class="flex-1">
|
||||
{{ assignment.destination.product }}
|
||||
<br>
|
||||
{{ assignment.destination.hotel }}
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
{{ assignment.jobProfile.name }}
|
||||
</td>
|
||||
<td>
|
||||
{{ ('label.document.type.' ~ upload.type)|trans }}
|
||||
</td>
|
||||
<td>
|
||||
{{ disposition.teamer }}
|
||||
</td>
|
||||
<td>
|
||||
{{ upload.status|upload_status_badge }}
|
||||
</td>
|
||||
<td>
|
||||
<div class="flex items-center space-x-2 justify-end">
|
||||
{% if is_granted('DELETE', upload) %}
|
||||
<button type="button"
|
||||
class="text-red-500"
|
||||
hx-get="{{ path('app_administrative_document_delete', { 'uuid': upload.uuid }) }}"
|
||||
hx-target="body"
|
||||
hx-swap="beforeend">
|
||||
{{ icon('delete') }}
|
||||
</button>
|
||||
{% endif %}
|
||||
<a href="{{ path('app_common_download', { 'uuid': upload.uuid, 'inline': false }) }}"
|
||||
target="_blank"
|
||||
title="Download">
|
||||
{{ icon('download') }}
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
{% else %}
|
||||
<tr>
|
||||
<td colspan="7">
|
||||
Keine Daten...
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{{ knp_pagination_render(pagination) }}
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -8,10 +8,6 @@
|
||||
Dokumentenübersicht
|
||||
</h1>
|
||||
<div class="flex flex-col items-end space-y-2 md:flex-row md:items-center md:space-x-2 md:space-y-0">
|
||||
<a href="{{ path('app_administrative_document_batch_download') }}" class="btn btn--small btn--secondary">
|
||||
{{ icon('download', 'w-4 h-4 shrink-0') }}
|
||||
<span>best. Honorarnoten</span>
|
||||
</a>
|
||||
<button type="button"
|
||||
class="{{ html_classes('btn btn--small', { 'btn--secondary': filterDto.active }) }}"
|
||||
title="Filter"
|
||||
|
||||
Reference in New Issue
Block a user