feat: sort flights by date and add sortable date/price columns
All checks were successful
Deploy / deploy (push) Successful in 36s
All checks were successful
Deploy / deploy (push) Successful in 36s
- Change API ORDER BY from price/date to date/price (chronological default) - Add flightSortField/flightSortDir state to ScanDetails - Make Date and Price sub-table headers clickable with sort icons Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1827,7 +1827,7 @@ async def get_scan_flights(
|
||||
departure_time, arrival_time, price, stops
|
||||
FROM flights
|
||||
WHERE scan_id = ? AND destination = ?
|
||||
ORDER BY price ASC, date ASC
|
||||
ORDER BY date ASC, price ASC
|
||||
LIMIT ? OFFSET ?
|
||||
""", (scan_id, destination.upper(), limit, offset))
|
||||
else:
|
||||
@@ -1836,7 +1836,7 @@ async def get_scan_flights(
|
||||
departure_time, arrival_time, price, stops
|
||||
FROM flights
|
||||
WHERE scan_id = ?
|
||||
ORDER BY price ASC, date ASC
|
||||
ORDER BY date ASC, price ASC
|
||||
LIMIT ? OFFSET ?
|
||||
""", (scan_id, limit, offset))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user