From 43459025bcac72318e4ef8a32c2d4455321bc191 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20=27Necoro=27=20Neumann?= Date: Sat, 14 Sep 2013 23:05:07 +0200 Subject: Draw pies using highcharts JS-lib --- templates/expenses/show.jinja | 12 ++++++++---- templates/layout.jinja | 14 +++++++------- 2 files changed, 15 insertions(+), 11 deletions(-) (limited to 'templates') diff --git a/templates/expenses/show.jinja b/templates/expenses/show.jinja index 4b6e362..395d1e5 100644 --- a/templates/expenses/show.jinja +++ b/templates/expenses/show.jinja @@ -3,6 +3,11 @@ {% set JSFunction = "showJS" %} +{% block js %} + {{ super() }} + +{% endblock %} + {% block heading %} {% if exps | length > 1 %} Aktuelle Kosten @@ -14,8 +19,8 @@ {% block content %} {% for e, p in zip(exps,pies) %} {% if exps | length > 1 %}

{{e|date}}

{% endif %} -
-
+
+
{% for c in e.catexps | sort(attribute="cat.name") %} {% call(exp) detail(name=c.cat.name, sum=c.expense, set=c.all) %} {{exp.day}}.{{exp.month}}. -- {{exp.description}}: {{exp.expense | eur }} @@ -30,8 +35,7 @@ {{exp.day}}.{{exp.month}}. -- {{exp.description}}: {{exp.expense | eur}} {% endcall %}
-
-
+
{% endfor %} diff --git a/templates/layout.jinja b/templates/layout.jinja index ee082f9..aa923d6 100644 --- a/templates/layout.jinja +++ b/templates/layout.jinja @@ -2,13 +2,6 @@ - {% if not g.is_mobile %} - {% block js %} - - - {% if JSFunction %} {% endif %} - {% endblock %} - {% endif %} {{ title or "Kostenverwaltung" }} {% block style %} @@ -54,5 +47,12 @@

{% endblock %}
+ {% if not g.is_mobile %} + {% block js %} + + + {% endblock %} + {% if JSFunction %} {% endif %} + {% endif %} -- cgit v1.2.3