WIP: Implement disposition process
This commit is contained in:
@@ -6,98 +6,146 @@
|
||||
<h1 class="text-2xl font-bold pb-8">
|
||||
Einsatzübersicht
|
||||
</h1>
|
||||
<div class="grid grid-cols-3 gap-8 items-start">
|
||||
<div class="bg-gray-100 rounded-md p-4">
|
||||
{% include '_partials/_assignment_info.html.twig' %}
|
||||
</div>
|
||||
<div class="col-span-2">
|
||||
<h2 class="font-bold text-lg pb-4">
|
||||
Bewerbungen
|
||||
</h2>
|
||||
<div class="data-table-wrapper w-full">
|
||||
<div class="data-table-wrapper__inner">
|
||||
<table class="data-table">
|
||||
<thead>
|
||||
<div class="bg-gray-100 rounded-md p-4 mb-8">
|
||||
{% include '_partials/_assignment_info_compact.html.twig' %}
|
||||
</div>
|
||||
<div class="col-span-2">
|
||||
<h2 class="font-bold text-lg pb-4">
|
||||
Bewerbungen
|
||||
</h2>
|
||||
<div class="data-table-wrapper w-full">
|
||||
<div class="data-table-wrapper__inner">
|
||||
<table class="data-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="w-1/3">
|
||||
Name
|
||||
</th>
|
||||
<th class="w-1/3">
|
||||
Anmerkungen
|
||||
</th>
|
||||
<th class="w-1/6">
|
||||
Status
|
||||
</th>
|
||||
<th class="w-1/6"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for application in applications %}
|
||||
<tr>
|
||||
<th>
|
||||
Name
|
||||
</th>
|
||||
<th>
|
||||
Anmerkungen
|
||||
</th>
|
||||
<th>
|
||||
Status
|
||||
</th>
|
||||
<th></th>
|
||||
<td>
|
||||
<a href="{{ path('app_admin_teamer_profile', { 'uuid': application.teamer.uuid, 'r': return_url() }) }}">
|
||||
{{ application.teamer }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
{{ application.requests|nl2br|default('-') }}
|
||||
</td>
|
||||
<td>
|
||||
{{ ('label.application.status.' ~ application.status)|trans }}
|
||||
</td>
|
||||
<td>
|
||||
<div class="flex items-center justify-end space-x-2">
|
||||
{% if is_granted('DISPOSE', application) %}
|
||||
<button type="button"
|
||||
class="btn"
|
||||
{{ stimulus_controller('modal-button', [], [], {'confirmation-modal': '#confirmation-modal'}) }}
|
||||
{{ stimulus_action('modal-button', 'confirmation', null, {
|
||||
'title': 'Bist du sicher?',
|
||||
'content': 'Möchtest du den Teamer ' ~ application.teamer ~ ' wirklich einteilen?',
|
||||
'target-url': path('app_admin_application_dispose', { 'uuid': application.uuid })
|
||||
}) }}>
|
||||
einteilen
|
||||
</button>
|
||||
{% endif %}
|
||||
{% if is_granted('REJECT', application) %}
|
||||
<button type="button" class="btn btn--secondary"
|
||||
{{ stimulus_controller('modal-button', [], [], {'confirmation-modal': '#confirmation-modal'}) }}
|
||||
{{ stimulus_action('modal-button', 'confirmation', null, {
|
||||
'title': 'Bist du sicher?',
|
||||
'content': 'Möchtest du die Bewerbung von ' ~ application.teamer ~ ' wirklich ablehnen?',
|
||||
'target-url': path('app_admin_application_reject', { 'uuid': application.uuid })
|
||||
}) }}>
|
||||
ablehnen
|
||||
</button>
|
||||
{% endif %}
|
||||
{% if is_granted('DELETE', application) %}
|
||||
<button type="button" class="btn btn--secondary"
|
||||
{{ stimulus_controller('modal-button', [], [], {'confirmation-modal': '#confirmation-modal'}) }}
|
||||
{{ stimulus_action('modal-button', 'confirmation', null, {
|
||||
'title': 'Bist du sicher?',
|
||||
'content': 'Möchtest du die Bewerbung von ' ~ application.teamer ~ ' wirklich löschen?',
|
||||
'target-url': path('app_admin_application_delete', { 'uuid': application.uuid })
|
||||
}) }}>
|
||||
löschen
|
||||
</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for application in applications %}
|
||||
<tr>
|
||||
<td>
|
||||
<a href="{{ path('app_admin_teamer_profile', { 'uuid': application.teamer.uuid, 'r': return_url() }) }}">
|
||||
{{ application.teamer }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
{{ application.requests|nl2br|default('-') }}
|
||||
</td>
|
||||
<td>
|
||||
{{ ('label.application.status.' ~ application.status)|trans }}
|
||||
</td>
|
||||
<td>
|
||||
<div class="flex items-center justify-end space-x-2">
|
||||
{% if is_granted('DISPOSE', application) %}
|
||||
<button type="button"
|
||||
class="btn"
|
||||
{{ stimulus_controller('modal-button', [], [], {'confirmation-modal': '#confirmation-modal'}) }}
|
||||
{{ stimulus_action('modal-button', 'confirmation', null, {
|
||||
'title': 'Bist du sicher?',
|
||||
'content': 'Möchtest du den Teamer ' ~ application.teamer ~ ' wirklich einteilen?',
|
||||
'target-url': path('app_admin_application_dispose', { 'uuid': application.uuid })
|
||||
}) }}>
|
||||
einteilen
|
||||
</button>
|
||||
{% endif %}
|
||||
{% if is_granted('REJECT', application) %}
|
||||
<button type="button" class="btn btn--secondary"
|
||||
{{ stimulus_controller('modal-button', [], [], {'confirmation-modal': '#confirmation-modal'}) }}
|
||||
{{ stimulus_action('modal-button', 'confirmation', null, {
|
||||
'title': 'Bist du sicher?',
|
||||
'content': 'Möchtest du die Bewerbung von ' ~ application.teamer ~ ' wirklich ablehnen?',
|
||||
'target-url': path('app_admin_application_reject', { 'uuid': application.uuid })
|
||||
}) }}>
|
||||
ablehnen
|
||||
</button>
|
||||
{% endif %}
|
||||
{% if is_granted('DELETE', application) %}
|
||||
<button type="button" class="btn btn--secondary"
|
||||
{{ stimulus_controller('modal-button', [], [], {'confirmation-modal': '#confirmation-modal'}) }}
|
||||
{{ stimulus_action('modal-button', 'confirmation', null, {
|
||||
'title': 'Bist du sicher?',
|
||||
'content': 'Möchtest du die Bewerbung von ' ~ application.teamer ~ ' wirklich löschen?',
|
||||
'target-url': path('app_admin_application_delete', { 'uuid': application.uuid })
|
||||
}) }}>
|
||||
löschen
|
||||
</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
{% else %}
|
||||
<tr>
|
||||
<td colspan="3">
|
||||
Bisher liegen keine Bewerbungen vor...
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{% else %}
|
||||
<tr>
|
||||
<td colspan="3">
|
||||
Es liegen keine Bewerbungen vor...
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<a href="{{ returnUrl }}" class="underline">
|
||||
zurück
|
||||
</a>
|
||||
</div>
|
||||
<h2 class="font-bold text-lg pb-4">
|
||||
Einteilungen
|
||||
</h2>
|
||||
<div class="data-table-wrapper w-full">
|
||||
<div class="data-table-wrapper__inner">
|
||||
<table class="data-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="w-1/3">
|
||||
Name
|
||||
</th>
|
||||
<th class="w-1/3">
|
||||
Anmerkungen
|
||||
</th>
|
||||
<th class="w-1/6">
|
||||
Status
|
||||
</th>
|
||||
<th class="w-1/6"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for disposition in dispositions %}
|
||||
<tr>
|
||||
<td>
|
||||
<a href="{{ path('app_admin_teamer_profile', { 'uuid': disposition.teamer.uuid, 'r': return_url() }) }}">
|
||||
{{ disposition.teamer }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
{{ disposition.remarks|nl2br|default('-') }}
|
||||
</td>
|
||||
<td>
|
||||
{{ ('label.disposition.status.' ~ disposition.status)|trans }}
|
||||
</td>
|
||||
<td>
|
||||
<div class="flex items-center justify-end space-x-2">
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
{% else %}
|
||||
<tr>
|
||||
<td colspan="3">
|
||||
Es gibt noch keine Einteilungen...
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<a href="{{ returnUrl }}" class="underline">
|
||||
zurück
|
||||
</a>
|
||||
</div>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user