Projet

Général

Profil

Development #58367 » actu.html

Thomas Jund, 13 décembre 2021 15:34

 
1
<! -- Début de du détail actu  -->
2

    
3
<div class="actu--header">
4
    <p class="actu--date">{{ json.fields.date|date:"d M Y" }}</div>
5
    <h1 class="actu--title">{{ json.fields.titre }}</h1>
6
    {% if json.fields.image %}
7
        <picture class="actu--picture">
8
            <img  class="actu--img" src="{% make_public_url url=json.fields.image.url %}" width="100%">
9
            {% if json.fields.legende %}<legend class="actu--legend">{{ json.fields.legende }}</legend>{% endif %}
10
        </picture>
11
    {% endif %}
12
</div>
13

    
14
<div class="actu--body">
15
    <p>{{ json.fields.resume|linebreaksbr }}</p>
16

    
17
    {% if  json.fields.encart == "Oui" %}
18
    <section class="actu--insert">
19
        {% if json.fields.titreencart %}
20
        <h2 class="actu--insert-title">{{ json.fields.titreencart }}</h2>
21
        {% endif %}
22
        <p class="actu--insert-body">
23
            {{ json.fields.contenuencart|linebreaksbr }}
24
        </p>
25
        {% if json.fields.lienencart %}
26
        <p>
27
            <a class="actu--insert-link" href="{{ json.fields.lienencart }}" target="{{ json.fields.targetlienencart }}">{{ json.fields.libellelienencart }}</a>
28
        </p>
29
        {% endif %}
30
    </section>
31
    {% endif %}
32

    
33
    {% if json.fields.contenu_supplementaire %}
34
    <p>{{ json.fields.contenu_supplementaire|linebreaksbr }}</p>
35
    {% endif %}
36
</div>
37

    
38
{% if json.fields.liens == "Oui" or json.fields.fichier1 or json.fields.fichier2 or json.fields.fichier3 %}
39
<footer class="actu--footer">
40
    {% if json.fields.liens == "Oui" %}
41
    <div>
42
        <h2 class="actu--footer-title">
43
            {{ json.fields.titreliens }}
44
        </h2>
45
        <ul>
46
            {% for lien in json.fields.lienscomplementaires_raw %}
47
            <li>
48
                <a href="{{ lien.url }}" target="{{ lien.target }}">
49
                    {{ lien.libelle }}
50
                </a>
51
            </li>
52
            {% endfor %}
53
        </ul>
54
    </div>
55
    {% endif %}
56

    
57
    {% if json.fields.fichier1 or json.fields.fichier2 or json.fields.fichier3 %}
58
    <div>
59
    {% if json.fields.titrefichiers %}
60
        <h2 class="actu--footer-title">{{ json.fields.titrefichiers }}</h2>
61
    {% endif %}
62
        <ul>
63
        {% if json.fields.fichier1 %}
64
            <li>
65
                <a class="download-link" type="{{ json.fields.fichier1.content_type }}" href="{% make_public_url url=json.fields.fichier1.url %}" download="{{ json.fields.fichier1.filename }}">
66
                    {{ json.fields.libelle_fichier1 }} libellé du fichier
67
                </a>
68
            </li>
69
        {% endif %}
70
        {% if json.fields.fichier2 %}
71
            <li>
72
                <a class="download-link" type="{{ json.fields.fichier2.content_type }}" href="{% make_public_url url=json.fields.fichier2.url %}" download="{{ json.fields.fichier2.filename }}">
73
                    {{ json.fields.libelle_fichier1 }} libellé du fichier
74
                </a>
75
            </li>
76
        {% endif %}
77
        {% if json.fields.fichier3 %}
78
            <li>
79
                <a class="download-link" type="{{ json.fields.fichier3.content_type }}" href="{% make_public_url url=json.fields.fichier3.url %}" download="{{ json.fields.fichier3.filename }}">
80
                    {{ json.fields.libelle_fichier1 }} libellé du fichier
81
                </a>
82
            </li>
83
        {% endif %}
84
        </ul>
85
    </div>
86
    {% endif %}
87
</footer>
88
{% endif %}