Loading lib/Travelynx/Controller/Traveling.pm +2 −1 Original line number Diff line number Diff line Loading @@ -300,7 +300,8 @@ sub monthly_history { template => 'history', journeys => [@journeys], year => $year, month => $months[ $month - 1 ], month => $month, month_name => $months[ $month - 1 ], statistics => $stats } ); Loading templates/history.html.ep +18 −1 Original line number Diff line number Diff line % my $since = get_user_data()->{registered_at}; % my $now = DateTime->now(time_zone => 'Europe/Berlin'); <div class="row"> <div class="col s12"> <ul class="pagination"> <!--<li class="disabled"><a href="#!"><i class="material-icons">chevron_left</i></a></li>--> % my $ref = stash('year') ? stash('year') . '/' . stash('month') : ''; % while ($since < $now) { % my $link_to = $since->strftime('%Y/%m'); % my $class = $link_to eq $ref ? 'active' : 'waves-effect'; <li class="<%= $class %>"><a href="/history/<%= $link_to %>"><%= $since->strftime('%m.%Y') %></a></li> % $since->add(months => 1); % } <!--<li class="disabled"><a href="#!"><i class="material-icons">chevron_right</i></a></li>--> </ul> </div> </div> % if (my $stats = stash('statistics')) { <h1><%= stash('month') %> <%= stash('year') %></h1> <h1><%= stash('month_name') %> <%= stash('year') %></h1> <div class="row"> <div class="col s12"> <table class="striped"> Loading Loading
lib/Travelynx/Controller/Traveling.pm +2 −1 Original line number Diff line number Diff line Loading @@ -300,7 +300,8 @@ sub monthly_history { template => 'history', journeys => [@journeys], year => $year, month => $months[ $month - 1 ], month => $month, month_name => $months[ $month - 1 ], statistics => $stats } ); Loading
templates/history.html.ep +18 −1 Original line number Diff line number Diff line % my $since = get_user_data()->{registered_at}; % my $now = DateTime->now(time_zone => 'Europe/Berlin'); <div class="row"> <div class="col s12"> <ul class="pagination"> <!--<li class="disabled"><a href="#!"><i class="material-icons">chevron_left</i></a></li>--> % my $ref = stash('year') ? stash('year') . '/' . stash('month') : ''; % while ($since < $now) { % my $link_to = $since->strftime('%Y/%m'); % my $class = $link_to eq $ref ? 'active' : 'waves-effect'; <li class="<%= $class %>"><a href="/history/<%= $link_to %>"><%= $since->strftime('%m.%Y') %></a></li> % $since->add(months => 1); % } <!--<li class="disabled"><a href="#!"><i class="material-icons">chevron_right</i></a></li>--> </ul> </div> </div> % if (my $stats = stash('statistics')) { <h1><%= stash('month') %> <%= stash('year') %></h1> <h1><%= stash('month_name') %> <%= stash('year') %></h1> <div class="row"> <div class="col s12"> <table class="striped"> Loading