summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2019-03-31 19:32:41 +0200
committerDaniel Friesel <derf@finalrewind.org>2019-03-31 19:32:41 +0200
commit3ce1cfc55f03ccb67b3bab13112d4594974552a4 (patch)
tree256d536d98b49b586f357575d7d580ae2cddb7f4 /templates
parent76f6922e825ea4f4f2ca0054bdd29ccd8e9edeca (diff)
Select journeys by ID
Diffstat (limited to 'templates')
-rw-r--r--templates/history.html.ep2
-rw-r--r--templates/landingpage.html.ep2
2 files changed, 2 insertions, 2 deletions
diff --git a/templates/history.html.ep b/templates/history.html.ep
index 5fc3907..8f63296 100644
--- a/templates/history.html.ep
+++ b/templates/history.html.ep
@@ -79,7 +79,7 @@
<tbody>
% for my $travel (@{$journeys}) {
% if ($travel->{completed}) {
- % my $detail_link = '/journey/' . current_user()->{id} . '-' . $travel->{checkin}->epoch . '-' . $travel->{checkout}->epoch;
+ % my $detail_link = '/journey/' . current_user()->{id} . '-' . $travel->{ids}->[1];
<tr>
<td><%= $travel->{sched_departure}->strftime('%d.%m.%Y') %></td>
<td>
diff --git a/templates/landingpage.html.ep b/templates/landingpage.html.ep
index dc559f9..2cd8f68 100644
--- a/templates/landingpage.html.ep
+++ b/templates/landingpage.html.ep
@@ -105,7 +105,7 @@
% for my $travel (get_user_travels(limit => 1)) {
% if ($travel->{completed}) {
<tr>
- % my $detail_link = '/journey/' . current_user()->{id} . '-' . $travel->{checkin}->epoch . '-' . $travel->{checkout}->epoch;
+ % my $detail_link = '/journey/' . current_user()->{id} . '-' . $travel->{ids}->[1];
<td><%= $travel->{sched_departure}->strftime('%d.%m.%Y') %></td>
<td><a href="<%= $detail_link %>"><%= $travel->{type} %> <%= $travel->{line} // $travel->{no} %></a></td>
<td><a href="<%= $detail_link %>"><%= $travel->{from_name} %> → <%= $travel->{to_name} %></a></td>