carrera en cuestionarios programa
This commit is contained in:
@@ -76,9 +76,7 @@ const get = async (body) => {
|
||||
});
|
||||
return helper.crearArchivo(path, convertArrayToCSV(data));
|
||||
})
|
||||
.then((res) => {
|
||||
return path;
|
||||
});
|
||||
.then((res) => path);
|
||||
};
|
||||
|
||||
module.exports = get;
|
||||
|
||||
@@ -5,6 +5,7 @@ const helperPath = '../../helper';
|
||||
const helper = require(`${helperPath}/helper`);
|
||||
const { validarNumero } = require(`${helperPath}/validar`);
|
||||
const dbPath = '../../db/tablas';
|
||||
const Carrera = require(`${dbPath}/Carrera`);
|
||||
const CuestionarioPrograma = require(`${dbPath}/CuestionarioPrograma`);
|
||||
const Servicio = require(`${dbPath}/Servicio`);
|
||||
const Programa = require(`${dbPath}/Programa`);
|
||||
@@ -23,6 +24,7 @@ const get = async (body) => {
|
||||
},
|
||||
{ model: Programa, where: { clavePrograma: { [Op.like]: `${year}-%` } } },
|
||||
{ model: Usuario },
|
||||
{ model: Carrera },
|
||||
],
|
||||
order: [['createdAt']],
|
||||
})
|
||||
@@ -33,6 +35,7 @@ const get = async (body) => {
|
||||
clavePrograma: res[i].Programa.clavePrograma,
|
||||
usuario: res[i].Usuario.usuario,
|
||||
nombre: res[i].Usuario.nombre,
|
||||
carrera: res[i].Carrera.carrera,
|
||||
idCuestionarioPrograma:
|
||||
res[i].CuestionarioPrograma.idCuestionarioPrograma,
|
||||
actividad1: res[i].CuestionarioPrograma.actividad1,
|
||||
@@ -50,9 +53,7 @@ const get = async (body) => {
|
||||
});
|
||||
return helper.crearArchivo(path, convertArrayToCSV(data));
|
||||
})
|
||||
.then((res) => {
|
||||
return path;
|
||||
});
|
||||
.then((res) => path);
|
||||
};
|
||||
|
||||
module.exports = get;
|
||||
|
||||
Reference in New Issue
Block a user