From 138dd87ab950f03fac193def46fdba7b0f5063fa Mon Sep 17 00:00:00 2001 From: Birte Kristina Friesel Date: Wed, 29 Oct 2025 20:18:58 +0100 Subject: Incorporate dbdb into travelynx --- lib/Travelynx/Model/Stations.pm | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'lib/Travelynx/Model/Stations.pm') diff --git a/lib/Travelynx/Model/Stations.pm b/lib/Travelynx/Model/Stations.pm index 5316118..6c647ec 100644 --- a/lib/Travelynx/Model/Stations.pm +++ b/lib/Travelynx/Model/Stations.pm @@ -519,4 +519,19 @@ sub grep_unknown { return @unknown_stations; } +sub get_bahn_stationinfo { + my ( $self, %opt ) = @_; + $opt{db} //= $self->{pg}->db; + + my $res + = $opt{db} + ->select( 'bahn_platform_directions', ['data'], { eva => $opt{eva} } ) + ->expand->hash; + + if ($res) { + return $res->{data}; + } + return; +} + 1; -- cgit v1.2.3