Merge branch 'feature/cancelation' into 'main'
Feature/cancelation See merge request PhilippHofer/rot!6
This commit is contained in:
		| @@ -7,7 +7,6 @@ | ||||
| - Wanderfahrt: ⛱ | ||||
|  | ||||
| # Notes / Bugfixes | ||||
| - [] max_people = 0 -> Rot hervorheben, dass Ausfahrt abgesagt wurde? | ||||
| - [] my trips for cox | ||||
| - [] add `trip_type` (id, name, desc, question, icon) with a FK to `trip_details` | ||||
| - [] add `always_show` to `planned_trips` (e.g. for wanderfahrten) | ||||
|   | ||||
| @@ -43,7 +43,7 @@ | ||||
| </div> | ||||
| {% endmacro alert %} | ||||
|  | ||||
| {% macro box(participants, empty_seats, header='Freie Plätze:', text='Keine Ruderer angemeldet', bg='primary-600', color='white') %} | ||||
| {% macro box(participants, empty_seats='', header='Freie Plätze:', text='Keine Ruderer angemeldet', bg='primary-600', color='white') %} | ||||
| <div class="text-{{ color }} bg-{{ bg }} text-center p-1 mt-1 rounded-t-md">{{ header }} {{ empty_seats }}</div> | ||||
| <div class="p-2 border border-t-0 border-{{ bg }} mb-4 rounded-b-md"> | ||||
|   {% if participants | length > 0 %} | ||||
|   | ||||
| @@ -139,10 +139,15 @@ | ||||
|         <div class="pt-2 reset-js" data-coxneeded="false"> | ||||
|           <div class="flex justify-between items-center"> | ||||
|             <div> | ||||
|               <strong class="text-primary-900">{{ trip.planned_starting_time }} Uhr</strong> <small | ||||
|                 class="text-gray-600">({{ trip.cox_name }})</small><br /> | ||||
|               <strong class="text-primary-900">{% if trip.max_people == 0 %}<span class="text-[#f43f5e]">⚠ </span>{% endif %}{{ trip.planned_starting_time }} Uhr</strong>  | ||||
|                 {% if trip.max_people == 0 %} | ||||
|                   <small class="text-[#f43f5e]">(Absage {{ trip.cox_name }})</small> | ||||
|                 {% else %} | ||||
|                  <small class="text-gray-600">({{ trip.cox_name }})</small> | ||||
|                 {% endif %} | ||||
|                 <br /> | ||||
|               <a href="#" data-sidebar="true" data-trigger="sidebar"  | ||||
|                 data-header="<strong>{{ trip.planned_starting_time }} Uhr</strong> ({{ trip.cox_name }}){% if trip.notes %}<small class='block'>{{ trip.notes }}</small>{% endif %}" | ||||
|                 data-header="<strong>{% if trip.max_people == 0 %}⚠ {% endif %}{{ trip.planned_starting_time }} Uhr</strong> ({{ trip.cox_name }}){% if trip.notes and trip.max_people > 0 %}<small class='block'>{{ trip.notes }}</small>{% endif %}{% if trip.max_people == 0 %}<small class='block'>Ausfahrt abgesagt!</small>{% endif %}" | ||||
|                 data-body="#trip{{ trip.trip_details_id }}" | ||||
|                 class="inline-block link-primary mr-3"> | ||||
|                 Details | ||||
| @@ -171,8 +176,14 @@ | ||||
|         {# --- START Sidebar Content --- #} | ||||
|         <div class="hidden"> | ||||
|             <div id="trip{{ trip.trip_details_id }}"> | ||||
|               {% if trip.max_people == 0 %} | ||||
|                 {# --- border-[#f43f5e] bg-[#f43f5e] --- #} | ||||
|                 {{ macros::box(participants=trip.rower,bg='[#f43f5e]',header='Absage') }} | ||||
|               {% else %} | ||||
|                 {% set amount_cur_rower = trip.rower | length %} | ||||
|                 {{ macros::box(participants=trip.rower, empty_seats=trip.max_people - amount_cur_rower, bg='primary-100', color='black') }} | ||||
|               {% endif %} | ||||
|  | ||||
|                  {# --- START Edit Form --- #} | ||||
|             {% if trip.cox_id == loggedin_user.id %} | ||||
|             <div class="bg-gray-100 p-3 mt-4 rounded-md"> | ||||
|   | ||||
		Reference in New Issue
	
	Block a user