import { ApiProperty } from '@nestjs/swagger'
import { IsBoolean } from 'class-validator'
import { Transform } from 'class-transformer'

export class ToggleVersionDto {
  @ApiProperty({ description: '是否启用' })
  @Transform(({ value }) => value === 'true' || value === true)
  @IsBoolean()
  isEnabled: boolean
}
