From d9ffbafe071117b090398c93283f574a9d77734f Mon Sep 17 00:00:00 2001 From: Vytor Calixto <vytorcalixto@gmail.com> Date: Tue, 25 Jul 2017 09:13:53 -0300 Subject: [PATCH] Change region download table --- src/libs/jobs/download.js | 2 +- src/libs/routes/region.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/jobs/download.js b/src/libs/jobs/download.js index 9130141c..eb8d30dd 100644 --- a/src/libs/jobs/download.js +++ b/src/libs/jobs/download.js @@ -34,7 +34,7 @@ module.exports = function(agenda) { let mailOptions = { to: 'Teste <vsbc14@inf.ufpr.br>', subject: 'DOWNLOAD!!!!!', - text: body + '\n\nOi!' + text: `Oi!\n\n ${body}` }; mail(mailOptions, (err, info) => { if (err) { diff --git a/src/libs/routes/region.js b/src/libs/routes/region.js index 24029716..6a3dc40b 100644 --- a/src/libs/routes/region.js +++ b/src/libs/routes/region.js @@ -57,7 +57,7 @@ regionApp.get('/', rqf.parse(), (req, res, next) => { const agenda = require(`${libs}/agenda`); regionApp.get('/download', (req, res) => { - req.sql.from('escola').field('*'); + req.sql.from('regiao').field('*'); let params = req.sql; agenda.now('download database', {sql: req.sql.toString(), table: req.sql.tableFrom}); res.json({msg: 'Wait for it...'}); -- GitLab