mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-29 00:10:57 +00:00
- Implemented migration to release stuck assigned locomotives. - Added schedule window phases to train schedules. - Created booking batch offers table for partial capacity bookings. - Developed BookingSplitService to handle partial booking offers and splits. - Introduced BookingWindowService to manage booking window lifecycle and transitions. - Added BookingBatchOffer entity to represent offers made during booking splits. - Enhanced locomotive options with warnings for scheduling. - Created UpcomingWindowsSection component to display upcoming booking windows.
27 lines
1.0 KiB
TypeScript
27 lines
1.0 KiB
TypeScript
/**
|
|
* Tunables for the demand-batching booking → allocation flow.
|
|
* Times run in EAT so window boundaries match the local operating clock.
|
|
*
|
|
* Cadence and pay-window durations moved to the train_scheduling_global_rules
|
|
* table (TrainSchedulingService.getWindowConfig) — the window engine
|
|
* (BookingWindowService) drives all timing off that config.
|
|
*/
|
|
|
|
export const BATCH_TIMEZONE = 'Africa/Addis_Ababa';
|
|
|
|
/** Fallback wagons-per-booking when a booking has no computed `wagonsRequired`. */
|
|
export const DEFAULT_WAGONS_PER_BOOKING = 1;
|
|
|
|
/**
|
|
* Fallback per-wagon length (m) for the batch length budget when global rules don't yet
|
|
* define maxTrainLength / maxWagons to derive it from. Used only to estimate train length
|
|
* against the locomotive's max train length.
|
|
*/
|
|
export const DEFAULT_WAGON_LENGTH_METERS = 14;
|
|
|
|
/** Default NW5 flat wagon length for container bookings (m). */
|
|
export const DEFAULT_CONTAINER_WAGON_LENGTH_METERS = 14;
|
|
|
|
/** Default CW3 covered wagon length for bulk bookings (m). */
|
|
export const DEFAULT_BULK_WAGON_LENGTH_METERS = 14;
|