summaryrefslogtreecommitdiff
path: root/lib/Travelynx
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2020-01-25 14:55:51 +0100
committerDaniel Friesel <derf@finalrewind.org>2020-01-25 14:55:51 +0100
commit1028e47a35a472fc4835f324f3ad195970b45b17 (patch)
tree09cb4b0c3a018227cfee423037cad86e0497843a /lib/Travelynx
parentee1285e8fa684c35b62dd32854f66515cd62a269 (diff)
map: list skipped journeys1.13.7
Diffstat (limited to 'lib/Travelynx')
-rwxr-xr-xlib/Travelynx/Controller/Traveling.pm8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/Travelynx/Controller/Traveling.pm b/lib/Travelynx/Controller/Traveling.pm
index 198d66e..421032f 100755
--- a/lib/Travelynx/Controller/Traveling.pm
+++ b/lib/Travelynx/Controller/Traveling.pm
@@ -445,6 +445,7 @@ sub map_history {
$self->render(
template => 'history_map',
with_map => 1,
+ skipped_journeys => [],
station_coordinates => [],
polyline_groups => [],
);
@@ -465,6 +466,8 @@ sub map_history {
my @station_pairs;
my %seen;
+ my @skipped_journeys;
+
for my $journey (@journeys) {
my @route = map { $_->[0] } @{ $journey->{route} };
@@ -474,6 +477,8 @@ sub map_history {
if ( $from_index == -1
or $to_index == -1 )
{
+ push( @skipped_journeys,
+ [ $journey, 'Start/Ziel nicht in Route gefunden' ] );
next;
}
@@ -491,6 +496,8 @@ sub map_history {
and @route <= 2
and not $include_manual )
{
+ push( @skipped_journeys,
+ [ $journey, 'Manueller Eintrag ohne Unterwegshalte' ] );
next;
}
@@ -527,6 +534,7 @@ sub map_history {
$self->render(
template => 'history_map',
with_map => 1,
+ skipped_journeys => \@skipped_journeys,
station_coordinates => \@station_coordinates,
polyline_groups => [
{