From 4e0a81464c6e0dc410d8c87091bbfe2f9aa06df8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carlos=20Andr=C3=A9s?= Date: Wed, 2 Oct 2024 15:12:57 +0200 Subject: [PATCH] fix: test --- db/routines/vn/procedures/productionControl.sql | 1 + db/routines/vn/procedures/sale_getProblems.sql | 2 +- db/routines/vn/procedures/sale_getProblemsByTicket.sql | 4 +++- db/routines/vn/procedures/ticket_getProblems.sql | 2 ++ modules/monitor/back/methods/sales-monitor/salesFilter.js | 1 + modules/ticket/back/methods/ticket/filter.js | 1 + modules/ticket/back/methods/ticket/getTicketsFuture.js | 1 + 7 files changed, 10 insertions(+), 2 deletions(-) diff --git a/db/routines/vn/procedures/productionControl.sql b/db/routines/vn/procedures/productionControl.sql index 29abc8044..b9550d62c 100644 --- a/db/routines/vn/procedures/productionControl.sql +++ b/db/routines/vn/procedures/productionControl.sql @@ -283,6 +283,7 @@ proc: BEGIN DROP TEMPORARY TABLE tmp.productionTicket, + tmp.ticket, tmp.ticketProblems, tmp.saleProblems, tmp.ticketWithPrevia, diff --git a/db/routines/vn/procedures/sale_getProblems.sql b/db/routines/vn/procedures/sale_getProblems.sql index a8388034f..79b548c2c 100644 --- a/db/routines/vn/procedures/sale_getProblems.sql +++ b/db/routines/vn/procedures/sale_getProblems.sql @@ -163,6 +163,6 @@ BEGIN END LOOP; CLOSE vCursor; - DROP TEMPORARY TABLE tItemShelving, tmp.sale; + DROP TEMPORARY TABLE tItemShelving; END$$ DELIMITER ; diff --git a/db/routines/vn/procedures/sale_getProblemsByTicket.sql b/db/routines/vn/procedures/sale_getProblemsByTicket.sql index 708938cba..fdfd5c8bc 100644 --- a/db/routines/vn/procedures/sale_getProblemsByTicket.sql +++ b/db/routines/vn/procedures/sale_getProblemsByTicket.sql @@ -18,6 +18,8 @@ BEGIN SELECT * FROM tmp.saleProblems; - DROP TEMPORARY TABLE tmp.saleProblems; + DROP TEMPORARY TABLE + tmp.saleProblems, + tmp.sale; END$$ DELIMITER ; diff --git a/db/routines/vn/procedures/ticket_getProblems.sql b/db/routines/vn/procedures/ticket_getProblems.sql index 3855c3a1d..fe77ed57b 100644 --- a/db/routines/vn/procedures/ticket_getProblems.sql +++ b/db/routines/vn/procedures/ticket_getProblems.sql @@ -105,5 +105,7 @@ BEGIN SET totalProblems = isFreezed + hasHighRisk + hasTicketRequest + isTaxDataChecked + hasComponentLack + hasItemDelay + isTooLittle + hasItemLost + hasRounding + hasItemShortage + isVip; + + DROP TEMPORARY TABLE tmp.sale; END$$ DELIMITER ; diff --git a/modules/monitor/back/methods/sales-monitor/salesFilter.js b/modules/monitor/back/methods/sales-monitor/salesFilter.js index 36e2c40aa..27a308311 100644 --- a/modules/monitor/back/methods/sales-monitor/salesFilter.js +++ b/modules/monitor/back/methods/sales-monitor/salesFilter.js @@ -375,6 +375,7 @@ module.exports = Self => { stmts.push(` DROP TEMPORARY TABLE + tmp.ticket, tmp.filter, tmp.ticketProblems, tmp.sale_getWarnings, diff --git a/modules/ticket/back/methods/ticket/filter.js b/modules/ticket/back/methods/ticket/filter.js index 257121307..3ca52337d 100644 --- a/modules/ticket/back/methods/ticket/filter.js +++ b/modules/ticket/back/methods/ticket/filter.js @@ -369,6 +369,7 @@ module.exports = Self => { stmts.push( `DROP TEMPORARY TABLE + tmp.ticket, tmp.filter, tmp.ticketProblems`); diff --git a/modules/ticket/back/methods/ticket/getTicketsFuture.js b/modules/ticket/back/methods/ticket/getTicketsFuture.js index af3acff13..88f40bc3e 100644 --- a/modules/ticket/back/methods/ticket/getTicketsFuture.js +++ b/modules/ticket/back/methods/ticket/getTicketsFuture.js @@ -213,6 +213,7 @@ module.exports = Self => { stmts.push( `DROP TEMPORARY TABLE + tmp.ticket, tmp.filter, tmp.ticketProblems`);