using cuestionario2 has atribute, create credentials for testing
This commit is contained in:
@@ -56,7 +56,9 @@ const admin = async (body) => {
|
||||
'vistoBuenoAcatlan',
|
||||
'createdAt',
|
||||
'idCuestionarioAlumno',
|
||||
'idCuestionarioAlumno2',
|
||||
'idCuestionarioPrograma',
|
||||
'idCuestionarioPrograma2'
|
||||
],
|
||||
}).then((res) => {
|
||||
if (!res) throw new Error('No existe este servicio social.');
|
||||
|
||||
@@ -46,6 +46,7 @@ const alumno = async (body) => {
|
||||
'profesor',
|
||||
'createdAt',
|
||||
'idCuestionarioAlumno',
|
||||
'idCuestionarioAlumno2'
|
||||
],
|
||||
});
|
||||
})
|
||||
|
||||
@@ -24,12 +24,14 @@ const cartaTermino = async (body, file) => {
|
||||
switch (res.idStatus) {
|
||||
case 4:
|
||||
case 8:
|
||||
return drive.uploadFile(
|
||||
return drive.uploadFile(
|
||||
path,
|
||||
`Carta_Termino.pdf`,
|
||||
'application/pdf',
|
||||
res.carpeta
|
||||
);
|
||||
);
|
||||
//return "carta de termino"
|
||||
|
||||
case 1:
|
||||
case 2:
|
||||
case 3:
|
||||
|
||||
@@ -24,12 +24,13 @@ const informeGlobal = async (body, file) => {
|
||||
switch (res.idStatus) {
|
||||
case 4:
|
||||
case 9:
|
||||
return drive.uploadFile(
|
||||
return drive.uploadFile(
|
||||
path,
|
||||
`Informe_Global.pdf`,
|
||||
'application/pdf',
|
||||
res.carpeta
|
||||
);
|
||||
);
|
||||
// return "informe global"
|
||||
case 1:
|
||||
case 2:
|
||||
case 3:
|
||||
|
||||
@@ -79,7 +79,7 @@ const nuevo = async (body, file) => {
|
||||
.then((servicio) => {
|
||||
let carpeta = '';
|
||||
|
||||
drive
|
||||
drive
|
||||
.mkDir(numeroCuenta)
|
||||
.then((res) => {
|
||||
carpeta = res;
|
||||
@@ -95,7 +95,7 @@ const nuevo = async (body, file) => {
|
||||
{ carpeta, cartaAceptacion: res },
|
||||
{ where: { idServicio: servicio.idServicio } }
|
||||
)
|
||||
);
|
||||
);
|
||||
return { message: `Se Pre-Registro correctamente a este alumno.` };
|
||||
});
|
||||
};
|
||||
|
||||
@@ -12,7 +12,9 @@ const registro = async (body) => {
|
||||
body.idServicio,
|
||||
'id servicio'
|
||||
);
|
||||
const password = encriptar.generarPassword();
|
||||
//const password = encriptar.generarPassword(); // esta genera la contraseña
|
||||
let pass = 'qwertyui'
|
||||
const password = pass //encriptar.encriptar(pass)
|
||||
let correo = {};
|
||||
let idUsuario;
|
||||
|
||||
@@ -58,6 +60,7 @@ const registro = async (body) => {
|
||||
.then((res) => ({
|
||||
message:
|
||||
'Se cambio de estatus correctamente y se envio un correo al alumno con sus credenciales.',
|
||||
pass
|
||||
}));
|
||||
};
|
||||
|
||||
|
||||
@@ -78,13 +78,19 @@ const registroValidado = async (body) => {
|
||||
gmail(correoResponsable.subject, emailResponsable, correoResponsable.msj)
|
||||
)
|
||||
.then((res) =>
|
||||
Servicio.update(
|
||||
{
|
||||
|
||||
let tempStatus = 3
|
||||
if (process.env.MODE == "pruebas") tempStatus = 4
|
||||
|
||||
return Servicio.update(
|
||||
// Producción
|
||||
{ idStatus: 3, direccion, telefono, fechaNacimiento },
|
||||
// { idStatus: 3, direccion, telefono, fechaNacimiento },
|
||||
// Pruebas
|
||||
// { idStatus: 4, direccion, telefono, fechaNacimiento },
|
||||
{ idStatus: tempStatus, direccion, telefono, fechaNacimiento },
|
||||
{ where: { idServicio } }
|
||||
)
|
||||
}
|
||||
)
|
||||
.then((res) => ({
|
||||
message: 'Haz terminado el registro de tu Servicio Social correctamente.',
|
||||
|
||||
@@ -57,6 +57,7 @@ const serviciosResponsable = async (body) => {
|
||||
'cartaTermino',
|
||||
'createdAt',
|
||||
'idCuestionarioPrograma',
|
||||
'idCuestionarioPrograma2'
|
||||
],
|
||||
order: [['updatedAt', 'DESC']],
|
||||
limit: 25,
|
||||
|
||||
Reference in New Issue
Block a user