From 663b4dc6d89d21caa6b670d69780754b40910d90 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Tue, 29 Oct 2019 21:18:46 +0100 Subject: live update of next station via javascript --- templates/_checked_in.html.ep | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'templates/_checked_in.html.ep') diff --git a/templates/_checked_in.html.ep b/templates/_checked_in.html.ep index 87b94f6..8d59c82 100644 --- a/templates/_checked_in.html.ep +++ b/templates/_checked_in.html.ep @@ -5,8 +5,10 @@ Eingecheckt in <%= $journey->{train_type} %> <%= $journey->{train_no} %>

+ data-journey="<%= $journey->{real_departure}->epoch %>;<%= <%= $journey->{real_arrival}->epoch %>" + data-route="<%= journey_to_ajax_route($journey) %>" + data-dest="<%= $journey->{arr_name} %>" + > % if ($journey->{boarding_countdown} > 120) { Einfahrt in <%= sprintf('%.f', $journey->{boarding_countdown} / 60) %> Minuten
% } @@ -108,7 +110,7 @@ noch nicht bekannt % }
-
+
% for my $station (@{$journey->{route_after}}) { % if ($station->[0] eq $journey->{arr_name}) { % last; @@ -133,7 +135,7 @@
-
+
% for my $station (@{$journey->{route_after}}) { % if ($station->[0] eq $journey->{arr_name}) { % last; -- cgit v1.2.3