mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-09-09 02:28:18 +00:00
booking operations and trains scheduling also allocations
This commit is contained in:
@@ -76,11 +76,12 @@ export class ConsolidationService {
|
||||
}
|
||||
|
||||
async slotsFromBooking(booking: Booking): Promise<ConsolidationSlot[]> {
|
||||
const lines =
|
||||
booking.bookingContainers?.map((bc) => ({
|
||||
const lines = (booking.bookingContainers ?? [])
|
||||
.filter((bc): bc is typeof bc & { containerTypeId: string } => bc.containerTypeId != null)
|
||||
.map((bc) => ({
|
||||
containerTypeId: bc.containerTypeId,
|
||||
quantity: bc.quantity,
|
||||
})) ?? [];
|
||||
}));
|
||||
return this.slotsFromContainerLines(lines);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user