You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
512 B
33 lines
512 B
import { Currency, Type } from '@prisma/client';
|
|
import { IsISO8601, IsNumber, IsString, ValidateIf } from 'class-validator';
|
|
|
|
export class UpdateOrderDto {
|
|
@IsString()
|
|
currency: Currency;
|
|
|
|
@IsISO8601()
|
|
date: string;
|
|
|
|
@IsNumber()
|
|
fee: number;
|
|
|
|
@IsString()
|
|
@ValidateIf((object, value) => value !== null)
|
|
platformId: string | null;
|
|
|
|
@IsString()
|
|
id: string;
|
|
|
|
@IsNumber()
|
|
quantity: number;
|
|
|
|
@IsString()
|
|
symbol: string;
|
|
|
|
@IsString()
|
|
type: Type;
|
|
|
|
@IsNumber()
|
|
unitPrice: number;
|
|
}
|