assistante dto edited
This commit is contained in:
parent
fd10c87c94
commit
d19a303ddc
@ -1,4 +1,46 @@
|
|||||||
import { OmitType } from "@nestjs/swagger";
|
import { OmitType } from "@nestjs/swagger";
|
||||||
import { CreateUserDto } from "./create_user.dto";
|
import { CreateUserDto } from "./create_user.dto";
|
||||||
|
import { IsBoolean, IsDateString, IsInt, IsOptional, IsString, IsUUID, Length, Max, Min } from "class-validator";
|
||||||
|
|
||||||
export class CreateAssistanteDto extends OmitType(CreateUserDto, ['role'] as const) {}
|
export class CreateAssistanteDto extends OmitType(CreateUserDto, ['role'] as const) {
|
||||||
|
@IsUUID()
|
||||||
|
user_id: string;
|
||||||
|
|
||||||
|
@IsString()
|
||||||
|
@Length(1, 50)
|
||||||
|
numero_agrement: string;
|
||||||
|
|
||||||
|
@IsDateString()
|
||||||
|
date_naissance: string;
|
||||||
|
|
||||||
|
@IsString()
|
||||||
|
@Length(1, 100)
|
||||||
|
ville_naissance: string;
|
||||||
|
|
||||||
|
@IsString()
|
||||||
|
@Length(2, 2)
|
||||||
|
pays_naissance: string;
|
||||||
|
|
||||||
|
@IsString()
|
||||||
|
@Length(15, 15)
|
||||||
|
nir_chiffre: string;
|
||||||
|
|
||||||
|
@IsInt()
|
||||||
|
@Min(1)
|
||||||
|
@Max(10)
|
||||||
|
nb_max_enfants: number;
|
||||||
|
|
||||||
|
@IsOptional()
|
||||||
|
@IsString()
|
||||||
|
biographie?: string;
|
||||||
|
|
||||||
|
@IsOptional()
|
||||||
|
@IsBoolean()
|
||||||
|
disponible?: boolean;
|
||||||
|
|
||||||
|
@IsOptional()
|
||||||
|
@IsString()
|
||||||
|
@Length(1, 100)
|
||||||
|
ville_residence?: string;
|
||||||
|
|
||||||
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user