style: restyle the teamer assignment, placement and application pages

This commit is contained in:
fromme committed 2026-11-12 11:25:30 +01:00
1 parent 64fac372c0
commit 8b44c7f14d
5 files changed
+89 -129

No files matched your search

+30 -80
View File
@@ -1,94 +1,44 @@
<dl class="divide-y divide-gray-100">
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
Jobprofil
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
{{ assignment.jobProfile.name }}
{% if assignment.jobProfileInfo %}
<div class="pt-2">
{{ assignment.jobProfileInfo|nl2br }}
</div>
{% endif %}
</dd>
</div>
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
Destination
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
{{ assignment.destination.product }}
</dd>
</div>
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
Einsatztermin
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
{{ assignment.destination.dateFrom|date('d.m.Y') }} - {{ assignment.destination.dateTo|date('d.m.Y') }}
</dd>
</div>
<dl class="grid grid-cols-[minmax(0,9rem)_minmax(0,1fr)] gap-x-4 gap-y-3">
<dt class="text-muted">Jobprofil</dt>
<dd class="break-words">
<span class="font-bold">{{ assignment.jobProfile.name }}</span>
{% if assignment.jobProfileInfo %}
<div class="pt-2">
{{ assignment.jobProfileInfo|nl2br }}
</div>
{% endif %}
</dd>
<dt class="text-muted">Destination</dt>
<dd class="break-words">{{ assignment.destination.product }}</dd>
<dt class="text-muted">Einsatztermin</dt>
<dd>{{ assignment.destination.dateFrom|date('d.m.Y') }} - {{ assignment.destination.dateTo|date('d.m.Y') }}</dd>
{% if assignment.pickup %}
{% set pickup = assignment.destination.pickup(assignment.pickup) %}
{% if pickup is not null %}
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
Busbegleitung
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
ab {{ pickup.city }}, {{ pickup.street }}
</dd>
</div>
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
Busabfahrt
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
{{ pickup.time }} Uhr
</dd>
</div>
<dt class="text-muted">Busbegleitung</dt>
<dd class="break-words">ab {{ pickup.city }}, {{ pickup.street }}</dd>
<dt class="text-muted">Busabfahrt</dt>
<dd>{{ pickup.time }} Uhr</dd>
{% endif %}
{% endif %}
{% if application is defined and application is not null and application.pickup is not null %}
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
Gewählter Zustieg
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
{{ application.pickup|bpn_pickup_label }}
</dd>
</div>
<dt class="text-muted">Gewählter Zustieg</dt>
<dd class="break-words">{{ application.pickup|bpn_pickup_label }}</dd>
{% endif %}
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
Du bekommst
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
{{ assignment.benefits|nl2list }}
</dd>
</div>
<dt class="text-muted">Du bekommst</dt>
<dd>{{ assignment.benefits|nl2list }}</dd>
{% if assignment.fees|length %}
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
Honorar
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
{% for fee in assignment.fees %}
{{ fee.name }} {{ fee.value|format_money }}
{% endfor %}
</dd>
</div>
<dt class="text-muted">Honorar</dt>
<dd>
{% for fee in assignment.fees %}
<div>{{ fee.name }} {{ fee.value|format_money }}</div>
{% endfor %}
</dd>
{% endif %}
{% if additional is defined %}
{% for item in additional %}
<div class="py-6 first:pt-0 last:pb-0 sm:grid sm:grid-cols-3 sm:gap-4">
<dt class="text-sm font-bold leading-6 text-gray-900">
{{ item.type }}
</dt>
<dd class="mt-1 text-sm leading-6 text-gray-700 sm:col-span-2 sm:mt-0">
{{ item.description|raw }}
</dd>
</div>
<dt class="text-muted">{{ item.type }}</dt>
<dd class="break-words">{{ item.description|raw }}</dd>
{% endfor %}
{% endif %}
</dl>
@@ -1,32 +1,30 @@
<ul class="pb-8">
{% macro check(met) %}
{% if met %}
{{ icon('check', 'w-5 h-5 text-emerald-700 shrink-0') }}
<span class="sr-only">erfüllt</span>
{% else %}
{{ icon('close', 'w-5 h-5 text-red-700 shrink-0') }}
<span class="sr-only">nicht erfüllt</span>
{% endif %}
{% endmacro %}
<ul class="divide-y divide-line pb-6">
{% set pickup = assignment.destination.pickup(assignment.pickup) %}
{% if pickup is not null %}
<li class="py-2">
<div class="flex items-center justify-between">
<span class="flex-1">Busbegleitung ab {{ pickup.city }}</span>
{% if has_pickup(assignment.pickup, teamer) %}
{{ icon('check', 'w-5 h-5 text-green-500 shrink-0') }}
{% else %}
{{ icon('close', 'w-5 h-5 text-red-500 shrink-0') }}
{% endif %}
</div>
<li class="flex items-center justify-between gap-x-4 py-2">
<span class="flex-1">Busbegleitung ab {{ pickup.city }}</span>
{{ _self.check(has_pickup(assignment.pickup, teamer)) }}
</li>
{% endif %}
{% for training in assignment.jobProfile.requiredTrainings %}
<li class="py-2">
<div class="flex items-center justify-between">
<span class="flex-1">{{ training.name }} absolviert</span>
{% if teamer.trainingAttendance(training) %}
{{ icon('check', 'w-5 h-5 text-green-500 shrink-0') }}
{% else %}
{{ icon('close', 'w-5 h-5 text-red-500 shrink-0') }}
{% endif %}
</div>
<li class="flex items-center justify-between gap-x-4 py-2">
<span class="flex-1">{{ training.name }} absolviert</span>
{{ _self.check(teamer.trainingAttendance(training)) }}
</li>
{% if not loop.last %}
<li>
oder
</li>
<li class="py-1 text-xs font-bold uppercase tracking-wide text-muted">
oder
</li>
{% endif %}
{% endfor %}
</ul>
@@ -7,11 +7,12 @@
Bewerbung
</h1>
<div class="grid lg:grid-cols-2 gap-8 items-start">
<div class="card p-4">
<section class="card p-5">
<h2 class="section-title pb-4">Einsatz</h2>
{% include '_partials/_assignment_info.html.twig' %}
</div>
<div>
<h2 class="text-xl font-bold pb-2">
</section>
<div class="card p-5">
<h2 class="section-title pb-2">
Voraussetzungen für diesen Einsatz
</h2>
{% include '_partials/_assignment_requirements_info.html.twig' %}
@@ -26,7 +27,7 @@
{% endif %}
{{ form_row(form.requests) }}
</div>
<button type="submit" class="btn">
<button type="submit" class="btn btn--cta">
Bewerbung abschicken!
</button>
{{ form_rest(form) }}
+32 -21
View File
@@ -3,13 +3,23 @@
{% block title %}Einsatzübersicht{% endblock %}
{% block content %}
<h1 class="text-2xl font-bold pb-8">
Einsatzübersicht
</h1>
<div class="grid lg:grid-cols-2 gap-8 items-start">
{% include '_partials/_assignment_info.html.twig' %}
<div>
<h2 class="text-xl font-bold pb-2">
<a href="{{ returnUrl }}" class="inline-flex items-center gap-x-1 pb-4 text-sm font-bold text-brand hover:text-brand-dark">
{{ icon('arrow-left', 'w-4 h-4 shrink-0') }}
<span>zurück</span>
</a>
<div class="pb-6">
<h1 class="text-2xl font-bold">{{ assignment.jobProfile.name }}</h1>
<p class="text-muted">
{{ assignment.destination.product }} · {{ assignment.destination.dateFrom|date('d.m.Y') }} - {{ assignment.destination.dateTo|date('d.m.Y') }}
</p>
</div>
<div class="grid lg:grid-cols-2 gap-6 items-start">
<section class="card p-5">
<h2 class="section-title pb-4">Einsatz</h2>
{% include '_partials/_assignment_info.html.twig' %}
</section>
<section class="card p-5">
<h2 class="section-title pb-2">
Voraussetzungen für diesen Einsatz
</h2>
{% include '_partials/_assignment_requirements_info.html.twig' %}
@@ -20,13 +30,13 @@
{% if application.status == constant('App\\Entity\\Application::STATUS_REJECTED') %}
<twig:MessageBox message="Deine Bewerbung wurde leider abgelehnt." type="error"/>
{% if application.comment and application.commentVisible %}
<strong>Begründung:</strong> {{ application.comment|nl2br}}
<p><strong>Begründung:</strong> {{ application.comment|nl2br}}</p>
{% endif %}
{% endif %}
{% if application.status == constant('App\\Entity\\Application::STATUS_PENDING') %}
<twig:MessageBox message="Deine Bewerbung befindet sich in Bearbeitung."/>
{% if application.comment and application.commentVisible %}
<strong>Begründung:</strong> {{ application.comment|nl2br}}
<p><strong>Begründung:</strong> {{ application.comment|nl2br}}</p>
{% endif %}
{% endif %}
{% if is_granted('WITHDRAW', application) %}
@@ -41,20 +51,21 @@
</button>
{% endif %}
{% else %}
<div>
<p>
Erfüllst du mehrere oder alle Voraussetzungen für diesen Einsatz?
</p>
<div class="flex flex-wrap items-center gap-x-6 gap-y-3">
<a href="{{ path('app_teamer_application_create', { 'uuid': assignment.uuid }) }}" class="btn btn--cta">
Hier bewerben!
</a>
<a href="{{ path('app_teamer_bookmark_toggle', { 'uuid': assignment.uuid, 'r': return_url() }) }}"
class="inline-flex items-center gap-x-1 text-sm font-bold text-brand hover:text-brand-dark">
{{ icon('star', 'w-4 h-4 shrink-0') }}
<span>{% if not isBookmarked %}auf die Merkliste setzen{% else %}von der Merkliste löschen{% endif %}</span>
</a>
</div>
<a href="{{ path('app_teamer_application_create', { 'uuid': assignment.uuid }) }}" class="btn">
Hier bewerben!
</a>
<a href="{{ path('app_teamer_bookmark_toggle', { 'uuid': assignment.uuid, 'r': return_url() }) }}" class="underline">
{% if not isBookmarked %}auf die Merkliste setzen{% else %}von der Merkliste löschen{% endif %}
</a>
{% endif %}
<a href="{{ returnUrl }}" class="underline">
zurück
</a>
</div>
</div>
</section>
</div>
{% endblock %}
{% endblock %}
@@ -12,7 +12,7 @@
{% endif %}
</h1>
<div class="grid lg:grid-cols-2 gap-8 items-start">
<div>
<div class="card p-5">
{% include '_partials/_assignment_info.html.twig' with {
'additional': [
{