import { ApiProperty } from '@nestjs/swagger';
import { ArrayMinSize, IsArray, IsUUID } from 'class-validator';

export class ReorderTrainWagonsDto {
  @ApiProperty({
    type: [String],
    format: 'uuid',
    description: 'Every wagon of the train, in the new consist order',
  })
  @IsArray()
  @ArrayMinSize(1)
  @IsUUID('all', { each: true })
  wagonIds!: string[];
}
