Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class PaginationQueryStringDto {
- @IsOptional()
- @IsNumber(
- { allowInfinity: false, allowNaN: false },
- { message: 'page_should_be_number'.toUpperCase() },
- )
- page: number;
- @IsOptional()
- @IsNumber(
- { allowInfinity: false, allowNaN: false },
- { message: 'limit_should_be_number'.toUpperCase() },
- )
- limit: number;
- }
- class ProjectFiltersByUserDto extends PaginationQueryStringDto {
- @IsOptional()
- @IsString({ message: 'province_should_be_string'.toUpperCase() })
- @IsMongoId({ message: 'province_should_be_object_id'.toUpperCase() })
- province: string;
- @IsOptional()
- @IsString({ message: 'endDate_should_be_string'.toUpperCase() })
- endDate: string;
- @IsOptional()
- @IsString({ message: 'startDate_should_be_string'.toUpperCase() })
- startDate: string;
- @IsOptional()
- @IsString({ message: 'serviceTypeId_should_be_string'.toUpperCase() })
- @IsMongoId({ message: 'serviceTypeId_should_be_object_id'.toUpperCase() })
- serviceTypeId: string;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement