refactor: split the questionnaire into teamer and bus feedback
This commit is contained in:
1 parent
2f4f9800dd
commit
a0170f5952
35 files changed
+1114
-554
No files matched your search
@@ -1,10 +1,10 @@
|
||||
{% extends 'administrative/layout.html.twig' %}
|
||||
|
||||
{% block title %}{{ definition.title }} (Testmodus){% endblock %}
|
||||
{% block title %}Fragebogen testen{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h1 class="text-2xl font-bold pb-4">
|
||||
{{ definition.title }}
|
||||
Fragebogen testen
|
||||
</h1>
|
||||
{% include '_partials/_alert.html.twig' with {
|
||||
'type': 'warning',
|
||||
@@ -14,14 +14,14 @@
|
||||
{% embed '_partials/_alert.html.twig' with { 'type': 'info' } %}
|
||||
{% block message %}
|
||||
{% if busEscort %}
|
||||
Mit den Fragen zur Busfahrt, wie bei einer Busbegleitung.
|
||||
Mit dem Bus-Feedback, wie bei einer Busbegleitung.
|
||||
{% else %}
|
||||
Ohne die Fragen zur Busfahrt, wie bei einem Einsatz ohne Busbegleitung.
|
||||
Ohne das Bus-Feedback, wie bei einem Einsatz ohne Busbegleitung.
|
||||
{% endif %}
|
||||
{% if busEscort != assignment.hasBusEscort %}
|
||||
Dieser Einsatz hat {{ assignment.hasBusEscort ? 'eine' : 'keine' }} Busbegleitung.
|
||||
{% endif %}
|
||||
<a href="{{ otherVariant }}" class="underline">{{ busEscort ? 'Ohne' : 'Mit' }} Busfahrt testen</a>
|
||||
<a href="{{ otherVariant }}" class="underline">{{ busEscort ? 'Ohne' : 'Mit' }} Bus-Feedback testen</a>
|
||||
{% endblock %}
|
||||
{% endembed %}
|
||||
<div class="grid lg:grid-cols-3 gap-8 items-start">
|
||||
@@ -31,18 +31,22 @@
|
||||
'type': 'success',
|
||||
'message': 'So würde der abgeschickte Fragebogen gespeichert. Ausgeblendete Fragen fallen dabei weg.'
|
||||
} %}
|
||||
{% include 'questionnaire/_answers.html.twig' with { 'answers': submitted } %}
|
||||
<div class="flex flex-col gap-y-12">
|
||||
{% for item in submitted %}
|
||||
<section>
|
||||
<h2 class="text-2xl font-bold pb-4">
|
||||
{{ item.definition.title }}
|
||||
</h2>
|
||||
{% include 'questionnaire/_answers.html.twig' with { 'definition': item.definition, 'answers': item.answers } %}
|
||||
</section>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<div class="pt-8">
|
||||
<a href="{{ path('app_administrative_questionnaire_test', { 'uuid': assignment.uuid, 'r': app.request.query.get('r') }) }}" class="btn btn--secondary">
|
||||
Erneut testen
|
||||
</a>
|
||||
</div>
|
||||
{% else %}
|
||||
{% if definition.description %}
|
||||
<p class="pb-8 text-gray-700">
|
||||
{{ definition.description|nl2br }}
|
||||
</p>
|
||||
{% endif %}
|
||||
{% if draft %}
|
||||
{% include '_partials/_alert.html.twig' with {
|
||||
'type': 'success',
|
||||
|
||||
Reference in new issue
Block a user