is not empty
This commit is contained in:
@@ -1,9 +1,11 @@
|
||||
import { IsInt, IsString } from 'class-validator';
|
||||
import { IsInt, IsNotEmpty, IsString, MaxLength } from 'class-validator';
|
||||
|
||||
export class CreateModuloDto {
|
||||
@IsInt()
|
||||
id_institucion: number;
|
||||
|
||||
@IsString()
|
||||
@IsNotEmpty()
|
||||
@MaxLength(30)
|
||||
modulo: string;
|
||||
}
|
||||
|
||||
@@ -1,4 +1,11 @@
|
||||
import { IsBoolean, IsInt, IsOptional, IsString } from 'class-validator';
|
||||
import {
|
||||
IsBoolean,
|
||||
IsInt,
|
||||
IsNotEmpty,
|
||||
IsOptional,
|
||||
IsString,
|
||||
MaxLength,
|
||||
} from 'class-validator';
|
||||
|
||||
export class UpdateModuloDto {
|
||||
@IsInt()
|
||||
@@ -9,6 +16,8 @@ export class UpdateModuloDto {
|
||||
activo?: boolean;
|
||||
|
||||
@IsString()
|
||||
@IsNotEmpty()
|
||||
@MaxLength(30)
|
||||
@IsOptional()
|
||||
modulo?: string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user