aboutsummaryrefslogtreecommitdiff
path: root/templates/balancing/table.html
diff options
context:
space:
mode:
Diffstat (limited to 'templates/balancing/table.html')
-rw-r--r--templates/balancing/table.html56
1 files changed, 56 insertions, 0 deletions
diff --git a/templates/balancing/table.html b/templates/balancing/table.html
new file mode 100644
index 0000000..72f3b37
--- /dev/null
+++ b/templates/balancing/table.html
@@ -0,0 +1,56 @@
+{% import "macros/paging.html" as paging %}
+
+{% extends "base.html" %}
+
+{% block title %}
+ Équilibrages
+{% endblock title %}
+
+{% block main %}
+
+ <section class="g-Section">
+
+ {% if not balancings %}
+ <div class="g-Table__NoResults">
+ Il n’y a aucun équilibrage.
+ </div>
+ {% endif %}
+
+ <a
+ class="g-Paragraph g-Button__Validate"
+ href="/balancing?page={{ page or 1 }}"
+ >
+ Ajouter un équilibrage
+ </a>
+
+ {% if balancings %}
+ <div class="g-Table">
+ <div class="g-Table__Row g-Table__Row--Header">
+ <span class="g-Table__Cell">Montant</span>
+ <span class="g-Table__Cell">De</span>
+ <span class="g-Table__Cell">Vers</span>
+ </div>
+ {% for balancing in balancings %}
+ <a
+ class="g-Table__Row {% if highlight == balancing.id %} g-Table__Row--Highlight {% endif %}"
+ href="/balancing/{{ balancing.id }}?page={{ page or 1 }}"
+ >
+ <span class="g-Table__Cell g-Table__NumericCell">
+ {{ balancing.amount | euros() }}
+ </span>
+ <span class="g-Table__Cell">{{ balancing.source }}</span>
+ <span class="g-Table__Cell">{{ balancing.destination }}</span>
+ </a>
+ {% endfor %}
+ </div>
+
+ {{ paging.view(
+ url="/balancings",
+ page=page,
+ max_page=max_page
+ ) }}
+ {% endif %}
+
+ </section>
+
+{% endblock main %}