Merge branch 'dev' into freight/feat/fixes-v1

This commit is contained in:
Nathnael
2026-07-06 10:58:57 +00:00
189 changed files with 11443 additions and 3232 deletions

View File

@@ -384,11 +384,39 @@ export interface IYard extends BaseEntity {
displayOrder: number;
}
/** One container number loaded onto a customer self-haul truck. */
export interface ICustomerTruckContainer {
id: string;
containerNumber: string;
}
/** A customer self-haul truck on a booking, carrying 12 containers. */
export interface ICustomerTruck {
id: string;
bookingId: string;
plateNumber: string;
driverName: string;
truckType: string;
assignedAt: string;
arrivedAt?: string | null;
containers?: ICustomerTruckContainer[];
}
/** Payload to add a customer self-haul truck (12 container numbers). */
export interface AddCustomerTruckPayload {
truckPlateNumber: string;
driverName: string;
truckType: string;
containerNumbers: string[];
}
export interface IBooking extends BaseEntity {
reference: string;
customerId: string;
/** The contract this booking was created under (Path A / Path B). */
contractId?: string | null;
/** Human-readable reference of the parent contract, joined onto list rows. */
contractReference?: string | null;
trainId?: string | null;
status: BookingStatus;
/** ONE_TIME for normal bookings; GENERAL_CONTRACT for umbrella contracts. */
@@ -435,6 +463,8 @@ export interface IBooking extends BaseEntity {
customerTruckArrivedAt?: string | null;
customsClearingEnabled?: boolean;
// (multi-truck self-haul lives in ICustomerTruck[], fetched via the
// /customer-trucks endpoint; the fields above are the booking-level flag.)
customsClearingAgent?: string | null;
equipmentReturn: "WITH_RETURN" | "WITHOUT_RETURN";