summaryrefslogtreecommitdiff
path: root/templates/consts/list.jinja
blob: 68fa1e1d108c64e23ab1fb1a3943246e7a0afee0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{% extends "layout.jinja" %}

{% block heading %}
    Konstante Kosten
{% endblock %}

{% block content %}
    <p><a href="{{ url_for(".add") }}">Neuen Eintrag hinzufügen</a></p>

    {{ list(current, "Aktuell") }}

    {% if future %} {{ list(future, "Zukünftige") }} {% endif %}
    {% if old %} {{ list(old, "Veraltet") }} {% endif %}
{% endblock %}

{% macro list(list, h) %}
    <h2>{{ h }}</h2>
    <ul class="arrow">
        {% for c in list -%}
            <li><a href="{{ url_for(".show", id = c.id) }}">{{c.description}} ({{c.expense | eur}})</a></li>
        {% endfor %}
    </ul>
{% endmacro %}