diff --git a/templates/macros.html b/templates/macros.html index 54a41f6..a5ec653 100644 --- a/templates/macros.html +++ b/templates/macros.html @@ -10,19 +10,15 @@ {% endif %} > - {% set_global image_found = 0 %} + {% set_global image = "../static/temp.jpg" %} {% for asset in recipe.assets %} {% if asset is matching("[img.](jpg|png)$") %} - Náhled - {% set_global image_found = 1 %} + {% set_global image = asset %} {% break %} {% endif %} {% endfor %} - {% if image_found == 0 %} - Náhradní obrázek - {% endif %} - {% set_global image_found = 0 %} - {% if recipe.title %}

{{ recipe.title }}

{% endif %} + {{ recipe.title }} +

{{ recipe.title }}

{% if recipe.date %}{{ recipe.date | date(format="%d.%m.%Y") }}{% endif %}