From d6e6c9992e85151ee12b9104bca647ce0e11782b Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 27 Apr 2019 09:11:42 +0200 Subject: History: Only show months and years with logged journeys --- templates/_history_months.html.ep | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'templates/_history_months.html.ep') diff --git a/templates/_history_months.html.ep b/templates/_history_months.html.ep index 465a159..6a83d74 100644 --- a/templates/_history_months.html.ep +++ b/templates/_history_months.html.ep @@ -1,11 +1,11 @@
    - % while ($since < $now) { - % my $link_to = $since->strftime('%Y/%m'); + % for my $month (history_months()) { + % my $link_to = $month->[0]; + % my $text = $month->[1]; % my $class = $link_to eq $current ? 'active' : 'waves-effect'; -
  • <%= $since->strftime('%m.%Y') %>
  • - % $since->add(months => 1)->set(day => 1, hour => 0, minute => 0, second => 0); +
  • <%= $text %>
  • % }
-- cgit v1.2.3