Changes between Version 1 and Version 2 of ViewMyTripsUseCase


Ignore:
Timestamp:
01/13/25 12:55:23 (2 days ago)
Author:
221514
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ViewMyTripsUseCase

    v1 v2  
    551. The user logs into the system
    662. The user clicks on the ‘My Trips’ tab
     7
     8{{{#!sql
     9SELECT lf.name, lt.name, trip.free_seats, trip.date, t_o.company_name, stop_time
     10FROM ticket as tick
     11JOIN trip on trip.trip_id = tick.trip_id
     12JOIN transport_organizer as t_o ON trip.transport_organizer_id = t_o.transport_organizer_id
     13JOIN route as r ON trip.route_id = r.route_id
     14JOIN location as lf on r.from_location_id = lf.location_id
     15JOIN location as lt on r.to_location_id = lt.location_id
     16JOIN trip_stops as stop on lf.location_id = stop.location_id
     17WHERE tick.account_id = {account_lists_id};
     18}}}
     19
    7203. (''Optional'') The user selects a status on which to filter their trips. By default, all trips are displayed.
    8214.  (''Optional'') The user selects a company on which to filter their trips. By default, all trips are displayed.
    9225. (''Optional'') The user selects a date range in which their trips were completed. By default, all trips are displayed.
     23
     24{{{#!sql
     25SELECT lf.name, lt.name, trip.free_seats, trip.date, t_o.company_name, stop_time
     26FROM ticket as tick
     27JOIN trip on trip.trip_id = tick.trip_id
     28JOIN transport_organizer as t_o ON trip.transport_organizer_id = t_o.transport_organizer_id
     29JOIN route as r ON trip.route_id = r.route_id
     30JOIN location as lf on r.from_location_id = lf.location_id
     31JOIN location as lt on r.to_location_id = lt.location_id
     32JOIN trip_stops as stop on lf.location_id = stop.location_id
     33WHERE tick.account_id = {account_lists_id}
     34AND status = {selected_status}
     35AND (trip.date < {before_date} AND trip.date < {after_date})
     36AND t_o.company_name = {selected_company_name};
     37}}}
     38
    10396. The user is displayed their trips.