mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-27 00:52:50 +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.
73 lines
3.1 KiB
TypeScript
73 lines
3.1 KiB
TypeScript
import { Module, forwardRef } from '@nestjs/common';
|
|
import { TypeOrmModule } from '@nestjs/typeorm';
|
|
|
|
import { BillingModule } from '../billing/billing.module';
|
|
import { BookingsModule } from '../bookings/bookings.module';
|
|
import { Container } from '../container-management/entities/container.entity';
|
|
import { LocomotivesModule } from '../locomotives/locomotives.module';
|
|
import { RuleEngineModule } from '../rule-engine/rule-engine.module';
|
|
import { Locomotive } from '../locomotives/entities/locomotive.entity';
|
|
import { Route } from '../routes/entities/route.entity';
|
|
import { TrainSetLocomotive } from '../train-sets/entities/train-set-locomotive.entity';
|
|
import { TrainSetWagon } from '../train-sets/entities/train-set-wagon.entity';
|
|
import { TrainSet } from '../train-sets/entities/train-set.entity';
|
|
import { TrainSetsModule } from '../train-sets/train-sets.module';
|
|
import { TrainSchedulesModule } from '../train-schedules/train-schedules.module';
|
|
import { WagonType } from '../wagon-types/entities/wagon-type.entity';
|
|
import { WagonTypesModule } from '../wagon-types/wagon-types.module';
|
|
import { Wagon } from '../wagons/entities/wagon.entity';
|
|
import { WarehousesModule } from '../warehouses/warehouses.module';
|
|
import { TrainCheckpointEvent } from './entities/train-checkpoint-event.entity';
|
|
import { ImportDjiboutiOperation } from './entities/import-djibouti-operation.entity';
|
|
import { TrainSchedulingGlobalRules } from './entities/train-scheduling-global-rules.entity';
|
|
import { TrainCheckpointEventsRepository } from './train-checkpoint-events.repository';
|
|
import { TrainSchedulingController } from './train-scheduling.controller';
|
|
import { TrainSchedulingService } from './train-scheduling.service';
|
|
import { BookingBatchService } from './booking-batch.service';
|
|
import { BookingNotifierService } from './booking-notifier.service';
|
|
import { BookingWindowService } from './booking-window.service';
|
|
import { BookingSplitService } from './booking-split.service';
|
|
import { BookingBatchOffer } from './entities/booking-batch-offer.entity';
|
|
import { NotificationsModule } from '../notifications/notifications.module';
|
|
import { ContractsModule } from '../contracts/contracts.module';
|
|
|
|
@Module({
|
|
imports: [
|
|
TypeOrmModule.forFeature([
|
|
Locomotive,
|
|
WagonType,
|
|
TrainSet,
|
|
TrainSetWagon,
|
|
TrainSetLocomotive,
|
|
Route,
|
|
Wagon,
|
|
Container,
|
|
TrainSchedulingGlobalRules,
|
|
TrainCheckpointEvent,
|
|
ImportDjiboutiOperation,
|
|
BookingBatchOffer,
|
|
]),
|
|
forwardRef(() => BookingsModule),
|
|
BillingModule,
|
|
NotificationsModule,
|
|
LocomotivesModule,
|
|
WagonTypesModule,
|
|
TrainSetsModule,
|
|
TrainSchedulesModule,
|
|
forwardRef(() => WarehousesModule),
|
|
RuleEngineModule,
|
|
forwardRef(() => ContractsModule),
|
|
],
|
|
controllers: [TrainSchedulingController],
|
|
providers: [
|
|
TrainSchedulingService,
|
|
TrainCheckpointEventsRepository,
|
|
BookingBatchService,
|
|
BookingNotifierService,
|
|
BookingWindowService,
|
|
BookingSplitService,
|
|
],
|
|
exports: [TrainSchedulingService, BookingBatchService, BookingWindowService],
|
|
})
|
|
export class TrainSchedulingModule {}
|