alfa numérico
This commit is contained in:
@@ -19,7 +19,8 @@ const nuevo = async (body, file) => {
|
||||
const fechaNacimiento = validar.validarFecha(body.fechaNacimiento);
|
||||
const direccion = validar.validarAlfanumerico(
|
||||
body.direccion,
|
||||
'La dirección',
|
||||
'dirección',
|
||||
false,
|
||||
200
|
||||
);
|
||||
const institucion = body.institucion
|
||||
|
||||
@@ -21,7 +21,8 @@ const update = async (body) => {
|
||||
if (body.direccion)
|
||||
dataUpdate.direccion = validar.validarAlfanumerico(
|
||||
body.direccion,
|
||||
'La dirección',
|
||||
'dirección',
|
||||
false,
|
||||
200
|
||||
);
|
||||
if (body.telefono)
|
||||
|
||||
@@ -12,7 +12,12 @@ const cancelar = async (body) => {
|
||||
body.idServicio,
|
||||
'id servicio'
|
||||
);
|
||||
const mensaje = validar.validarAlfanumerico(body.mensaje, 'El mensaje', 800);
|
||||
const mensaje = validar.validarAlfanumerico(
|
||||
body.mensaje,
|
||||
'mensaje',
|
||||
true,
|
||||
800
|
||||
);
|
||||
let correoResponsable = {};
|
||||
let correoAlumno = {};
|
||||
let emailResponsable = '';
|
||||
|
||||
@@ -24,7 +24,8 @@ const nuevo = async (body, file) => {
|
||||
const programaInterno = body.programaInterno
|
||||
? validar.validarAlfanumerico(
|
||||
body.programaInterno,
|
||||
'El texto programa interno',
|
||||
'programa interno',
|
||||
true,
|
||||
250
|
||||
)
|
||||
: '';
|
||||
|
||||
@@ -12,7 +12,12 @@ const cancelar = async (body) => {
|
||||
body.idServicio,
|
||||
'id servicio'
|
||||
);
|
||||
const mensaje = validar.validarAlfanumerico(body.mensaje, 'El mensaje', 800);
|
||||
const mensaje = validar.validarAlfanumerico(
|
||||
body.mensaje,
|
||||
'mensaje',
|
||||
true,
|
||||
800
|
||||
);
|
||||
let correoResponsable = {};
|
||||
let correoAlumno = {};
|
||||
let emailResponsable = '';
|
||||
|
||||
@@ -12,7 +12,12 @@ const cancelar = async (body) => {
|
||||
body.idServicio,
|
||||
'id servicio'
|
||||
);
|
||||
const mensaje = validar.validarAlfanumerico(body.mensaje, 'El mensaje', 800);
|
||||
const mensaje = validar.validarAlfanumerico(
|
||||
body.mensaje,
|
||||
'mensaje',
|
||||
true,
|
||||
800
|
||||
);
|
||||
let correoResponsable = {};
|
||||
let correoAlumno = {};
|
||||
let emailResponsable = '';
|
||||
|
||||
@@ -12,7 +12,12 @@ const cancelar = async (body) => {
|
||||
body.idServicio,
|
||||
'id servicio'
|
||||
);
|
||||
const mensaje = validar.validarAlfanumerico(body.mensaje, 'El mensaje', 800);
|
||||
const mensaje = validar.validarAlfanumerico(
|
||||
body.mensaje,
|
||||
'mensaje',
|
||||
true,
|
||||
800
|
||||
);
|
||||
let correoResponsable = {};
|
||||
let correoAlumno = {};
|
||||
let emailResponsable = '';
|
||||
|
||||
@@ -16,7 +16,8 @@ const registroValidado = async (body) => {
|
||||
const telefono = validar.validarNumero(body.telefono, 15);
|
||||
const direccion = validar.validarAlfanumerico(
|
||||
body.direccion,
|
||||
'La dirección',
|
||||
'dirección',
|
||||
false,
|
||||
200
|
||||
);
|
||||
let correoResponsable = {};
|
||||
|
||||
@@ -50,7 +50,8 @@ const update = async (body, files) => {
|
||||
if (body.direccion)
|
||||
dataUpdate.direccion = validar.validarAlfanumerico(
|
||||
body.direccion,
|
||||
'La dirección',
|
||||
'dirección',
|
||||
false,
|
||||
200
|
||||
);
|
||||
if (body.telefono)
|
||||
|
||||
@@ -9,7 +9,8 @@ const login = async (body) => {
|
||||
const usuario = validar.validar(body.usuario, 'El usuario', 60);
|
||||
const password = validar.validarAlfanumerico(
|
||||
body.password,
|
||||
'La contraseña',
|
||||
'contraseña',
|
||||
false,
|
||||
20
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user