From 8da77ee13ba6687e3528156a115dd463a0273818 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Fromme?= Date: Wed, 23 Jul 2025 15:48:59 +0200 Subject: [PATCH] wip: collapsible forms --- templates/booking/create_step_2.html.twig | 70 +++++++++++++---------- 1 file changed, 40 insertions(+), 30 deletions(-) diff --git a/templates/booking/create_step_2.html.twig b/templates/booking/create_step_2.html.twig index 3d3eb97..be407ee 100644 --- a/templates/booking/create_step_2.html.twig +++ b/templates/booking/create_step_2.html.twig @@ -12,36 +12,46 @@ {% block participants_form %}
{% for participant in form.participants %} -
- - Teilnehmer:in {{ loop.index }} - -
- {{ form_row(participant.firstName) }} - {{ form_row(participant.lastName) }} - {{ form_row(participant.dateOfBirth) }} - {{ form_row(participant.gender) }} - {{ form_row(participant.nationality) }} -
-
- {{ form_row(participant.email) }} - {{ form_row(participant.mobile) }} -
-
- {{ form_row(participant.bodyDimensions.height) }} - {{ form_row(participant.bodyDimensions.shoeSize) }} - {{ form_row(participant.bodyDimensions.weight) }} -
-
- {# hx-swap="none" tells HTMX not to do a normal swap, as OOB will handle it #} - {{ form_row(participant.assignedRoomId, { - 'attr': { - 'hx-post': path('app_booking_create_step_2_refresh'), - 'hx-swap': 'none' - } - }) }} -
-
+ {% set participantDataValid = participant.vars.valid %} +
+
+ + Teilnehmer:in {{ loop.index }} + + + +
+
{% endfor %}
{% endblock %}