From ffee7177ac26f4e79227cdf0abcd83f80f34faa4 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sun, 7 Apr 2019 18:44:33 +0200 Subject: Refactor history template, add yearly stats --- templates/history_by_year.html.ep | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 templates/history_by_year.html.ep (limited to 'templates/history_by_year.html.ep') diff --git a/templates/history_by_year.html.ep b/templates/history_by_year.html.ep new file mode 100644 index 0000000..97c223f --- /dev/null +++ b/templates/history_by_year.html.ep @@ -0,0 +1,13 @@ +% my $since = get_user_data()->{registered_at}; +% my $now = DateTime->now(time_zone => 'Europe/Berlin'); +%= include '_history_years', current => $year, since => $since, now => $now; + +

Jahresrückblick <%= $year %>

+ +% if (stash('statistics')) { + %= include '_history_stats', stats => stash('statistics'); +% } + +% if (stash('journeys')) { + %= include '_history_trains', journeys => stash('journeys'); +% } -- cgit v1.2.3