import { ApiProperty } from '@nestjs/swagger';
import { IsNotEmpty } from 'class-validator';
import { CreateDto } from 'src/common/dto/create.dto';

export class CreateExamPaperClassifyDto extends CreateDto {
  @ApiProperty({ description: '试卷分类名' })
  @IsNotEmpty({ message: '试卷分类名不能为空' })
  name: string;

  @ApiProperty({ description: '上级试卷分类', default: 0 })
  @IsNotEmpty({ message: '上级试卷分类不能为空' })
  pid: number;

  @ApiProperty({ description: '试卷分类层级', default: 1 })
  @IsNotEmpty({ message: '层级不能为空' })
  level: number;
}
