24 lines
409 B
TypeScript
24 lines
409 B
TypeScript
|
|
import { Type } from 'class-transformer'
|
||
|
|
import { IsInt, IsNumber, IsOptional, IsString } from 'class-validator'
|
||
|
|
|
||
|
|
export class CreatePurchaseReceiptDto {
|
||
|
|
@IsString()
|
||
|
|
code: string
|
||
|
|
|
||
|
|
@Type(() => Number)
|
||
|
|
@IsNumber()
|
||
|
|
totalAmount: number
|
||
|
|
|
||
|
|
@IsOptional()
|
||
|
|
@IsString()
|
||
|
|
description?: string
|
||
|
|
|
||
|
|
@Type(() => Number)
|
||
|
|
@IsInt()
|
||
|
|
supplierId: number
|
||
|
|
|
||
|
|
@Type(() => Number)
|
||
|
|
@IsInt()
|
||
|
|
inventoryId: number
|
||
|
|
}
|