meso.tpl 2.84 KB
Newer Older
1
{% if header %}
2
3
4
<div class="meso">
    <div class="card">
        <div class="card-header">
5
            <h4>
6
7
            {% if meso['url'] %}
            <a href="{{ meso['url'] }}">{{ meso['name'] }}</a>
Roland Denis's avatar
Roland Denis committed
8
            {% else %}
9
            {{ meso['name'] }}
Roland Denis's avatar
Roland Denis committed
10
            {% endif %}
11
12
13
14
15
16
17
18
19
20
21
22
            {% if meso['gpscoordinates'] %}
            <div>
                <a href="https://www.openstreetmap.org/?mlat={{meso['gpscoordinates'][0]}}&mlon={{meso['gpscoordinates'][1]}}&zoom=16">
                <img src="../theme/img/position_full.png" alt="Position" title="Position" />
                </a>
            </div>
            {% endif %}
            </h4>
            <p>
{% endif %}
{% if footer %}
            </p>
23
24
        </div>
        <div class="card-body">
25
            <div class="plus-minus plus" onclick="$(this).closest('.card-body').find('.collapse').collapse('toggle'); $(this).toggleClass('plus minus')"></div>
26
            {% if meso['contactname'] %}
27
                <p><img src="../theme/img/mail.png" alt="Contact" title="Contact" />
28
29
30
31
32
                {% if meso['contactaddress'] %}
                <a href="mailto:{{ meso['contactaddress'] }}">{{ meso['contactname'] }}</a>
                {% else %}
                {{ meso['contactname'] }}
                {% endif %}
Roland Denis's avatar
Roland Denis committed
33
                </p>
34
            {% endif %}
35
            {% if meso['institutesname'] %}
36
                <p><img src="../theme/img/employer.png" alt="Institutions" title="Institutions" />
37
38
39
                {% for name in meso['institutesname'] -%}
                {{ ' et ' if loop.last }}{{ ', ' if not loop.first and not loop.last }}{{ name }}
                {%- endfor %}
Roland Denis's avatar
Roland Denis committed
40
                </p>
41
42
            {% endif %}
            {% if meso['financersname'] %}
43
                <p class="collapse"><img src="../theme/img/piggy_bank.png" alt="Financeurs" title="Financeurs" />
44
45
46
                {% for name in meso['financersname'] -%}
                {{ ' et ' if loop.last }}{{ ', ' if not loop.first and not loop.last }}{{ name }}
                {%- endfor %}
Roland Denis's avatar
Roland Denis committed
47
                </p>
48
            {% endif %}
49
50
51
            {% if meso['accesspolicy'] %}
                <p class="collapse"><img src="../theme/img/contract.png" alt="Conditions d'accès" title="Conditions d'accès" />
                {{ meso['accesspolicy'] }}
Roland Denis's avatar
Roland Denis committed
52
                </p>
53
            {% endif %}
54
55
        </div>
        <div class="card-footer row">
56
            {% if meso['totalcorenumber'] %}
57
                <p class="col-sm"><img src="../theme/img/cpu.png" alt="Nombre de cœurs" />
58
                {{ meso['totalcorenumber'] }} cœurs
Roland Denis's avatar
Roland Denis committed
59
                </p>
60
61
            {% endif %}
            {% if meso['totalstorage'] %}
62
                <p class="col-sm"><img src="../theme/img/floppy.png" alt="Stockage" />
63
                {{ meso['totalstorage'] }} To
Roland Denis's avatar
Roland Denis committed
64
                </p>
65
66
            {% endif %}
        </div>
Roland Denis's avatar
Roland Denis committed
67
68
    </div>
</div>
69
{% endif %}