import { ApiProperty } from "@nestjs/swagger"
import { Type } from "class-transformer"
import { IsDate, IsNumber, IsUUID } from "class-validator"

export class CreateTransferDto {
    @ApiProperty({ format: 'uuid' })
    @IsUUID()
    id_out: string

    @ApiProperty({ format: 'uuid' })
    @IsUUID()
    id_in: string

    @ApiProperty()
    @IsNumber()
    id_fuel: number

    @ApiProperty({ type: String, format: 'date-time' })
    @Type(() => Date)
    @IsDate()
    date: Date

    @ApiProperty()
    @IsNumber()
    value: number
}