add if condition

This commit is contained in:
2022-06-13 21:58:33 +00:00
parent 71f7ac3404
commit e4971a7c08

View File

@@ -116,19 +116,23 @@
Event-Ende: {{ post.event_end|date }} um {{ post.event_end|time }} Uhr
</span>
</div>
{% if post.event_place %}
<div class="items-center lg:flex gap-2">
<i class="flex-none fa-solid fa-location-dot fa-fw text-gray-800 dark:text-gray-200"></i>
<span class="flex-1 text-sm text-gray-800 dark:text-gray-200">
Event-Ort: {{ post.event_place }}
</span>
</div>
{% endif %}
</div>
<div class="hidden absolute top-0 right-0 bg-white dark:bg-gray-900 rounded-bl p-2 bg-opacity-80 dark:bg-opacity-70 items-center gap-2">
<i class="flex-none fa-solid fa-calendar-clock text-gray-800 dark:text-gray-200"></i>
<span class="flex-1 text-sm text-gray-800 dark:text-gray-200">
Event-Start: {{ post.event_start|date }} um {{ post.event_start|time }} Uhr<br>
Event-Ende: {{ post.event_end|date }} um {{ post.event_end|time }} Uhr<br>
{% if post.event_place %}
Event-Ort: {{ post.event_place }}
{% endif %}
</span>
</div>
{% endif %}
@@ -165,7 +169,9 @@
<ul class="text-base text-gray-700 dark:text-gray-300 my-1">
<li>Start: {{ post.event_start|date }} um {{ post.event_start|time }} Uhr</li>
<li>Ende: {{ post.event_end|date }} um {{ post.event_end|time }} Uhr</li>
{% if post.event_place %}
<li>Ort: {{ post.event_place }}</li>
{% endif %}
</ul>
</div>
{% endif %}