From 47cff3f8946d29d7b714da549fde55eee7a23612 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Fri, 12 Jul 2024 08:52:03 +0200 Subject: [PATCH] feat(ssalix): refs #7648 remove select field --- modules/entry/back/methods/entry/filter.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/entry/back/methods/entry/filter.js b/modules/entry/back/methods/entry/filter.js index 0981247ee..77e5f2e67 100644 --- a/modules/entry/back/methods/entry/filter.js +++ b/modules/entry/back/methods/entry/filter.js @@ -189,8 +189,7 @@ module.exports = Self => { t.landed, t.ref AS travelRef, t.warehouseInFk, - w.name warehouseInName, - util.VN_CURDATE() + w.name warehouseInName FROM vn.entry e JOIN vn.supplier s ON s.id = e.supplierFk JOIN vn.travel t ON t.id = e.travelFk @@ -201,12 +200,13 @@ module.exports = Self => { ); if (supplier) { + const days = ctx.args.days ?? DEFAULT_INTERVAL_DAYS; stmt.merge({ sql: ` AND t.shipped < util.VN_CURDATE() + INTERVAL ? + 1 DAY AND t.shipped >= util.VN_CURDATE() `, - params: Array(1).fill(ctx.args.days ?? DEFAULT_INTERVAL_DAYS) + params: [days] }); } stmt.merge(conn.makeSuffix(filter));