From 242f4ee266918acaa16fe36a2b732a01ff4edc48 Mon Sep 17 00:00:00 2001 From: philipp Date: Tue, 3 Sep 2024 22:09:42 +0300 Subject: [PATCH] format frontend code --- templates/includes/macros.html.tera | 12 +++++----- templates/planned.html.tera | 36 ++++++++++++++++------------- 2 files changed, 26 insertions(+), 22 deletions(-) diff --git a/templates/includes/macros.html.tera b/templates/includes/macros.html.tera index b4202b0..e3a0b30 100644 --- a/templates/includes/macros.html.tera +++ b/templates/includes/macros.html.tera @@ -24,14 +24,14 @@ function setChoiceByLabel(choicesInstance, label) { {% for planned_trip in planned_trips | sort(attribute='planned_starting_time') %}
- {% set amount_members = planned_trip.rower | length + 1 %} + {% set amount_members = planned_trip.rower | length + 1 %} {{ planned_trip.cox_name }} ({{ amount_members }} Person{{ amount_members | pluralize(singular="", plural="en") }}) {{ planned_trip.planned_starting_time }} - - + +
{% endfor %} diff --git a/templates/planned.html.tera b/templates/planned.html.tera index 99e55dc..e500be3 100644 --- a/templates/planned.html.tera +++ b/templates/planned.html.tera @@ -100,7 +100,9 @@ style="order: {{ event.planned_starting_time | replace(from=":", to="") }}">
- {% if event.always_show and not day.regular_sees_this_day %}🔮{% endif -%} + {% if event.always_show and not day.regular_sees_this_day %} + 🔮 + {% endif -%} {%- if event.max_people == 0 %} ⚠ Absage {{ event.planned_starting_time }} @@ -275,7 +277,9 @@ data-coxneeded="false">
- {% if trip.always_show and not day.regular_sees_this_day %}🔮{% endif -%} + {% if trip.always_show and not day.regular_sees_this_day %} + 🔮 + {% endif -%} {% if trip.max_people == 0 %} ⚠ {{ trip.planned_starting_time }} @@ -384,20 +388,20 @@ {% if allowed_to_update_always_show_trip %}

Admin-Modus

- {% if not day.regular_sees_this_day %} -
- {% if not trip.always_show %} - Diese Ausfahrt sehen aktuell nur Steuerleute (und Admins). {{ amount_days_to_show_trips_ahead }} Tage vorher sehen sie dann alle. - {% else %} - Diese Ausfahrt sehen alle Mitglieder. - {% endif %} - -
- {% endif %} + {% if not day.regular_sees_this_day %} +
+ {% if not trip.always_show %} + Diese Ausfahrt sehen aktuell nur Steuerleute (und Admins). {{ amount_days_to_show_trips_ahead }} Tage vorher sehen sie dann alle. + {% else %} + Diese Ausfahrt sehen alle Mitglieder. + {% endif %} + +
+ {% endif %} {% include "includes/delete-icon" %} -- 2.45.2