mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-27 00:52:50 +00:00
Booking detail now has a Trucks tab displaying every EDR or customer truck assigned to a booking's last mile. Each row shows warehouse-gate times (arrival/departure) and destination-detention times (arrival/return), with detention costs and inspection status. Detention rows only for EDR trucks; customer self-haul shows —. Reuses existing TruckDetentionModal and FeePreviewModal for edit/view actions. Backend: arrivalTrucksForBooking() adds lastMileId per truck (direct chain to detention preview), containerItems() adds inspection_status column to responses. No new SQL, no migrations, no new endpoints. Frontend: BookingTrucksPanel.tsx self-fetches all data via existing warehouse + last-mile services, renders adaptive table with cargo-cost strip above. Wired into BookingRequestDetailPage.tsx tab bar.