[TASK] add label for logtype

This commit is contained in:
Marie Birner 2023-09-28 14:28:21 +02:00
parent 54cedd2ec3
commit 929785b5c5

View File

@ -186,8 +186,21 @@
{% endmacro show %} {% endmacro show %}
{% macro show_old(log, state, allowed_to_close=false, only_ones, index) %} {% macro show_old(log, state, allowed_to_close=false, only_ones, index) %}
<div class="border-t bg-white p-3" data-filterable="true" data-filter="{{ log.boat.name }} {{ log.shipmaster_user.name }} {% for rower in log.rowers %} {{ rower.name }} {% endfor %}"> <div class="border-t bg-white py-3 px-4 relative" data-filterable="true" data-filter="{{ log.boat.name }} {{ log.shipmaster_user.name }} {% for rower in log.rowers %} {{ rower.name }} {% endfor %}">
<div> {% if log.logtype %}
<div class="absolute top-0 right-0 bg-primary-100 rounded-bl-md text-primary-950 text-xs w-32 px-2 py-1 text-center font-bold">
{% if log.logtype == 1 %}
Wanderfahrt
{% else %}
{% if log.logtype == 2 %}
Regatta
{% else %}
{{ log.logtype }}
{% endif %}
{% endif %}
</div>
{% endif %}
<div {% if log.logtype %} class="mt-4 sm:mt-0" {% endif %}>
<strong>{{ log.boat.name }}</strong> <small class="text-gray-600">({{ log.shipmaster_user.name }}{% if log.shipmaster_only_steering %} - handgesteuert {% endif %})</small> <strong>{{ log.boat.name }}</strong> <small class="text-gray-600">({{ log.shipmaster_user.name }}{% if log.shipmaster_only_steering %} - handgesteuert {% endif %})</small>
<small class="block text-gray-600"> <small class="block text-gray-600">
@ -224,12 +237,6 @@
{% endif %} {% endif %}
</div> </div>
{% endif %} {% endif %}
{% if log.logtype %}
<div>
Logtype:
{{ log.logtype }}
</div>
{% endif %}
{% endif %} {% endif %}
</div> </div>
</div> </div>