show boatreservations in planned
Some checks failed
CI/CD Pipeline / test (push) Has been cancelled
CI/CD Pipeline / deploy-staging (push) Has been cancelled
CI/CD Pipeline / deploy-main (push) Has been cancelled

This commit is contained in:
2025-01-01 19:05:20 +01:00
parent d7187a7589
commit b560233acf
3 changed files with 79 additions and 4 deletions

View File

@ -89,8 +89,30 @@
</small>
{% endif %}
</h2>
{% if day.events | length > 0 or day.trips | length > 0 %}
{% if day.events | length > 0 or day.trips | length > 0 or day.boat_reservations | length > 0 %}
<div class="grid grid-cols-1 gap-3 mb-3">
{# --- START Boatreservations--- #}
{% for _, reservations_for_event in day.boat_reservations %}
{% set reservation = reservations_for_event[0] %}
<div class="pt-2 px-3 {% if not loop.first %}border-t{% endif %} border-gray-200">
<div class="flex justify-between items-center">
<div class="mr-1">
<strong class="text-primary-900 dark:text-white">
Reservierung
{% for reservation in reservations_for_event -%}
{{ reservation.boat.name }}
{%- if not loop.last %} + {% endif -%}
{% endfor -%}
: {{ reservation.time_desc }}
</strong>
<small class="text-gray-600 dark:text-gray-100">(von {{ reservation.user_applicant.name }}, Grund: {{ reservation.usage}})</small>
<br />
</div>
</div>
</div>
{% endfor %}
{# --- END Boatreservations--- #}
{# --- START Events --- #}
{% if day.events | length > 0 %}
{% for event in day.events | sort(attribute="planned_starting_time") %}