summaryrefslogtreecommitdiff
path: root/ishtar_common/templates/ishtar/blocks/window_image.html
blob: aa43e1ca56a3c65719933eedd03b6c267b71b47b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
{% load i18n %}{% if item.images.count %}
<div class="lightgallery-captions">
    {% for image in item.images.all %}
    <div id="lightgallery-{{window_id}}-caption-{{forloop.counter0}}">
        <span class="close">&times</span>
        {% if image.title %}<h3>{{image.title}}</h3>{% endif %}
        {% if image.description %}<p class="raw-description">
        {{image.description}}
        </p>{% endif %}
        {% if image.licences.count %}
        <div class="row">
            <div class="col-2">
                <strong>{% trans "Licenses" %}</strong>
            </div>
            <div class="col-10">
                {% for license in image.licenses.all %}
                {% if not forloop.first %} ; {% endif %}{% if license.url %}<a href="{{license.url}}">{% endif %}
                {{license}}
                {% if license.url %}</a>{% endif %}
                {% endfor %}
            </div>
        </div>
        {% endif %}
        {% if image.authors.count or image.authors_raw %}
        <div class="row">
            <div class="col-2">
                <strong>{% trans "Authors" %}</strong>
            </div>
            <div class="col-10">
                {% for author in image.authors.all %}
                {% if not forloop.first %} ; {% endif %}{{author}}{% endfor %}
                {% if image.authors_raw %}
                {% if image.authors.count %} ; {% endif %}
                {{image.authors_raw}}
                {% endif %}
            </div>
        </div>
        {% endif %}
        {% if image.image_type %}
        <div class="row">
            <div class="col-2">
                <strong>{% trans "Type" %}</strong>
            </div>
            <div class="col-10">
                {{image.image_type}}
            </div>
        </div>
        {% endif %}
        {% if image.reference %}
        <div class="row">
            <div class="col-2">
                <strong>{% trans "Ref." %}</strong>
            </div>
            <div class="col-10">
                {{image.reference}}
            </div>
        </div>
        {% endif %}
        {% if image.internal_reference %}
        <div class="row">
            <div class="col-2">
                <strong>{% trans "Internal ref." %}</strong>
            </div>
            <div class="col-10">
                {{image.internal_reference}}
            </div>
        </div>
        {% endif %}
        {% if image.creation_date %}
        <div class="row">
            <div class="col-2">
                <strong>{% trans "Creation date" %}</strong>
            </div>
            <div class="col-10">
                {{image.creation_date}}
            </div>
        </div>
        {% endif %}
        <a href="{% url 'edit-document' image.pk %}">
            {% trans "Modify" %} &nbsp;<i class="fa fa-pencil"></i>
        </a>
    </div>
    {% endfor %}
</div>
<div id="lightgallery-{{window_id}}">
    {% for image in item.images.all %}
    {% if output != "ODT" %}<a data-sub-html="#lightgallery-{{window_id}}-caption-{{forloop.counter0}}" href="{{image.image.url}}"{% if not forloop.first %}
               class="lightgallery-subimage"{% endif %}>{% endif %}
        <img{% if forloop.first %} class='card-img-top'{% endif %} src="{{BASE_URL}}{{image.thumbnail.url}}">
    {% if output != "ODT" %}</a>{% endif %}
    {% endfor %}
</div>
{% endif%}