From 3787245fd493fe821e000b2a160ee0f4bfa37dcd Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Tue, 19 Oct 2021 11:43:06 +0200 Subject: Document: fix image with no file attached to. --- ishtar_common/templates/ishtar/blocks/window_image.html | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/ishtar_common/templates/ishtar/blocks/window_image.html b/ishtar_common/templates/ishtar/blocks/window_image.html index dcf0c2f5e..8f0c0dbed 100644 --- a/ishtar_common/templates/ishtar/blocks/window_image.html +++ b/ishtar_common/templates/ishtar/blocks/window_image.html @@ -4,17 +4,16 @@ {% else %} {% trans "Sheet" as sheet_lbl %}
- {% if item.main_image %}{% with image=item.main_image %} + {% if item.main_image and item.main_image.image %}{% with image=item.main_image %}
× - {% include "ishtar/blocks/window_image_detail.html" %} {{image|simple_link_to_window:sheet_lbl}}   {% trans "Modify" %}
{% endwith %}{% endif %} - {% for image in item.images_without_main_image.all %} + {% for image in item.images_without_main_image.all %}{% if image.image %}
× {% include "ishtar/blocks/window_image_detail.html" %} @@ -23,21 +22,21 @@ {% trans "Modify" %}
- {% endfor %} + {% endif %}{% endfor %}
- {% if item.main_image %}{% with image=item.main_image %} + {% if item.main_image and item.main_image.image %}{% with image=item.main_image %} {% endwith %}{% endif %} - {% for image in item.images_without_main_image.all %} + {% for image in item.images_without_main_image.all %}{% if image.image %} - {% endfor %} + {% endif %}{% endfor %}
{% endif%} {% endif%} -- cgit v1.2.3