fix: review blockers — entity registration, session enum, conflict date-range, @Type decorators
This commit is contained in:
@@ -8,6 +8,7 @@ import {
|
||||
Min,
|
||||
Max,
|
||||
} from 'class-validator';
|
||||
import { Type } from 'class-transformer';
|
||||
|
||||
export class CreateScheduleDto {
|
||||
@IsInt()
|
||||
@@ -115,14 +116,17 @@ export class UpdateScheduleDto {
|
||||
|
||||
export class QueryScheduleDto {
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
classroomId?: number;
|
||||
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
classId?: number;
|
||||
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
@Min(1)
|
||||
@Max(7)
|
||||
@@ -147,6 +151,7 @@ export class WeeklyViewQueryDto {
|
||||
endDate?: string;
|
||||
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
classroomId?: number;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user