diff options
author | Daniel Friesel <derf@finalrewind.org> | 2023-03-01 17:58:58 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2023-03-01 17:58:58 +0100 |
commit | ae42028a71a21c034a1bbb804d8f1bc599f2dba4 (patch) | |
tree | c790d281f095dae8ccbd654f4de749c28d295067 /lib/Travelynx/Model | |
parent | d1a3176edf4872c05a137a77ca1adb4034ff1b8e (diff) |
Journeys->get: allow filtering by departure timestamp
Diffstat (limited to 'lib/Travelynx/Model')
-rwxr-xr-x | lib/Travelynx/Model/Journeys.pm | 4 |
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}; |