import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';
import { IsString, IsNotEmpty, IsOptional, IsInt } from 'class-validator';

export class CreateLostReasonDto {
  @ApiProperty({ description: 'Reason name', example: 'Дорого' })
  @IsString()
  @IsNotEmpty()
  name: string;

  @ApiPropertyOptional({ description: 'Sort position', default: 0 })
  @IsInt()
  @IsOptional()
  position?: number;
}
