add smart random

This commit is contained in:
2023-07-14 14:54:47 +02:00
parent 68942e904f
commit b14fb39009
25 changed files with 509 additions and 104 deletions

View File

@@ -1,6 +1,7 @@
import { Length } from 'class-validator'
import { PaginationDto } from '../../../infrastructure/common/pagination/pagination.dto'
import { IsOptionalOrEmptyString } from '../../../infrastructure/decorators/is-optional-or-empty-string'
import { IsOrderBy } from '../../../infrastructure/decorators/is-order-by-constraint'
export class GetAllCardsInDeckDto extends PaginationDto {
@IsOptionalOrEmptyString()
@@ -10,4 +11,7 @@ export class GetAllCardsInDeckDto extends PaginationDto {
@IsOptionalOrEmptyString()
@Length(1, 30)
answer?: string
@IsOrderBy()
orderBy?: string | null
}