reporte corregido

This commit is contained in:
xXpuma99Xx
2022-02-18 22:05:55 -06:00
parent 0504d8c947
commit dfa0951a49
2 changed files with 101 additions and 101 deletions
+3 -3
View File
@@ -34,8 +34,8 @@ const reporte = async (body) => {
return Prestamo.findAll({
where: {
[Op.and]: [
{ createdAt: { [Op.gte]: inicio.format() } },
{ createdAt: { [Op.lte]: fin.format() } },
{ createdAt: { [Op.gte]: inicio.add(-1, 'd').format() } },
{ createdAt: { [Op.lte]: fin.add(1, 'd').format() } },
],
},
include: [
@@ -127,7 +127,7 @@ const reporte = async (body) => {
await helper.eliminarArchivo(path).catch((err) => {});
return helper.crearArchivo(path, convertArrayToCSV(data));
})
.then((res) => path);
.then(() => path);
};
module.exports = reporte;