mirror of https://github.com/ghostfolio/ghostfolio
6 changed files with 21 additions and 13 deletions
@ -1,10 +1,13 @@ |
|||
import { SYMBOL_MAXIMUM_LENGTH } from '@ghostfolio/common/config'; |
|||
|
|||
import { DataSource } from '@prisma/client'; |
|||
import { IsEnum, IsString } from 'class-validator'; |
|||
import { IsEnum, IsString, MaxLength } from 'class-validator'; |
|||
|
|||
export class CreateWatchlistItemDto { |
|||
@IsEnum(DataSource) |
|||
dataSource: DataSource; |
|||
|
|||
@IsString() |
|||
@MaxLength(SYMBOL_MAXIMUM_LENGTH) |
|||
symbol: string; |
|||
} |
|||
|
|||
Loading…
Reference in new issue