Upstream returned HTTP 400 for empty departure/arrival values. Angular
derives them from per-leg data when missing; easier fix here is to
simply not send them — the backend accepts the request without those
query params.
Angular's ScheduleApiService.getFlights uses GET with query params
and a half-open date interval (sends dateTo = requested end + 1 day).
React sent POST with a JSON body matching the params verbatim, which
returned HTTP 500 from the backend.
searchSchedule now:
- GETs flights/1/{lang}/schedule with ?departure=...&arrival=...
- extends dateTo by one day
- coerces connections to '0'/'1' and drops empty timeFrom/timeTo
Verified the call returns 200 with real flight data for
SVO→LED 2026-04-18..2026-04-25. Updated the api tests accordingly.
Previously the /schedule/route results page rendered everything on the
dark-blue background and dumped the raw 382-char bitmask from the
/days endpoint straight into the DOM. Changes:
- Wrap the page in PageLayout with PageTabs, breadcrumb and an H1
matching Angular ('Маршрут: SVO - LED').
- Swap the inline calendar loop for the shared <DayTabs> component
(weekday + day + month labels, paging arrows).
- Replace the broken comma-split parser in getScheduleCalendarDays
with the same bitmask-to-dates conversion the board endpoint uses,
so the calendar now yields real yyyy-MM-dd strings.
- Frame the results in <section class='frame'> so they sit on a white
card (matches the board pages).
- Translate the 'Invalid …' parameter errors on every route page to
SHARED.INVALID-PARAMS ('Неверные параметры URL.') and wire t() into
the two route files that still lacked useTranslation.
API functions now build the full localized path matching the Angular
EndpointService pattern (/api/flights/{version}/{locale}/{endpoint}).
The dev proxy forwards /api and /flights to the test backend.
POST schedule/1 for search, GET schedule/details with indexed query
params, GET days/.../schedule/v1 for calendar. Three hooks wrap the
API functions with loading/error state management.