mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-29 14:08:11 +00:00
Project Initialization
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
import { Freight } from '@edr/types';
|
||||
import { IsEnum, IsNumber, IsOptional, IsString, Min } from 'class-validator';
|
||||
|
||||
export class CreateTrainDto {
|
||||
@IsString()
|
||||
code!: string;
|
||||
|
||||
@IsNumber()
|
||||
@Min(0)
|
||||
capacityTons!: number;
|
||||
|
||||
@IsOptional()
|
||||
@IsEnum(Freight.TrainStatus)
|
||||
status?: Freight.TrainStatus;
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
notes?: string;
|
||||
}
|
||||
Reference in New Issue
Block a user