diff --git a/templates/journey.html.ep b/templates/journey.html.ep index e00fdc2..a9c0c0b 100644 --- a/templates/journey.html.ep +++ b/templates/journey.html.ep @@ -32,7 +32,7 @@ <%= $journey->{type} %> <%= $journey->{no} %> % if ($journey->{line}) { - (Linie <%= $journey->{type} %> <%= $journey->{line} %>) + (Linie <%= $journey->{line} %>) % } @@ -75,6 +75,17 @@ % } + + Entfernung + + % my $distance = get_travel_distance($journey->{from_name}, $journey->{to_name}, $journey->{route}); + % my $beeline = get_travel_distance($journey->{from_name}, $journey->{to_name}, [$journey->{from_name}, $journey->{to_name}]); + % if ($distance > 0.1) { + ca. <%= sprintf('%.f', $distance) %> km + % } + (Luftlinie: <%= sprintf('%.f', $beeline) %> km) + + Meldungen