From 416f0f5e9a92bc8ef6d258f2a40c2cc3577cc82f Mon Sep 17 00:00:00 2001 From: TioSam77 Date: Fri, 14 Jun 2024 16:06:15 -0600 Subject: [PATCH] profesorDto --- src/Profesor/dto/profesorDto.dto.ts | 97 ++++++++++++++++++++++++++++- 1 file changed, 96 insertions(+), 1 deletion(-) diff --git a/src/Profesor/dto/profesorDto.dto.ts b/src/Profesor/dto/profesorDto.dto.ts index 2599d4b..1523062 100644 --- a/src/Profesor/dto/profesorDto.dto.ts +++ b/src/Profesor/dto/profesorDto.dto.ts @@ -1,6 +1,101 @@ +import { IsBoolean, IsDate, IsEmail, IsEmpty, IsNotEmpty, IsNumber, IsString, Length,} from "class-validator"; export class profesorDto{ + + @IsNumber() + @IsNotEmpty() + @Length(11) + id_profesor: number; - username:string + @IsNumber() + @IsNotEmpty() + @Length(11) + id_usuario: number; + + @IsString() + @IsEmpty() + @Length(10) + num_trabajador: string; + + @IsString() + @IsNotEmpty() + @Length(80) + nombre: string; + + @IsString() + @IsEmpty() + @Length(10) + rfc: string; + + @IsString() + @IsEmpty() + @Length(3) + homoclave: string; + + @IsString() + @IsEmpty() + @Length(13) + tel_oficina: string; + + @IsString() + @IsEmpty() + @Length(10) + extension: string; + + @IsString() + @IsEmpty() + @Length(13) + tel_personal: string; + + @IsString() + @IsEmpty() + @Length(65) + correo_pcp: string; + + @IsString() + @IsEmpty() + @Length(65) + correo_per: string; + + @IsNumber() + @IsEmpty() + @Length(11) + id_adscripcion: number; + + @IsNumber() + @IsEmpty() + @Length(11) + id_categoria: number; + + @IsNumber() + @IsEmpty() + @Length(11) + id_edificio: number; + + @IsString() + @IsEmpty() + @Length(256) + ubicacion: string; + + @IsString() + @IsEmpty() + @Length(150) + fotografia: string; + + @IsBoolean() + @IsNotEmpty() + activo: boolean = false; + + @IsBoolean() + @IsNotEmpty() + mostrar: boolean = true; + + @IsDate() + @IsNotEmpty() + fecha_alta: Date; + + @IsDate() + @IsNotEmpty() + fecha_actualizacion: Date; } \ No newline at end of file