summaryrefslogtreecommitdiff
path: root/lib/Travelynx/Model
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2023-03-01 17:58:58 +0100
committerDaniel Friesel <derf@finalrewind.org>2023-03-01 17:58:58 +0100
commitae42028a71a21c034a1bbb804d8f1bc599f2dba4 (patch)
treec790d281f095dae8ccbd654f4de749c28d295067 /lib/Travelynx/Model
parentd1a3176edf4872c05a137a77ca1adb4034ff1b8e (diff)
Journeys->get: allow filtering by departure timestamp
Diffstat (limited to 'lib/Travelynx/Model')
-rwxr-xr-xlib/Travelynx/Model/Journeys.pm4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Travelynx/Model/Journeys.pm b/lib/Travelynx/Model/Journeys.pm
index a9c6200..0062642 100755
--- a/lib/Travelynx/Model/Journeys.pm
+++ b/lib/Travelynx/Model/Journeys.pm
@@ -545,6 +545,10 @@ sub get {
$order{limit} = $opt{limit};
}
+ if ( $opt{sched_dep_ts} ) {
+ $where{sched_dep_ts} = $opt{sched_dep_ts};
+ }
+
if ( $opt{journey_id} ) {
$where{journey_id} = $opt{journey_id};
delete $where{cancelled};