From 00412e3258d507d7c9c166c9e43067f555ccfc8c Mon Sep 17 00:00:00 2001 From: ivanm Date: Fri, 22 Nov 2024 12:21:05 +0100 Subject: [PATCH] refactor: refs #7899 delete unused states --- db/versions/11359-navyPaniculata/00-firstScript.sql | 8 ++++++++ modules/monitor/back/methods/sales-monitor/salesFilter.js | 4 ---- 2 files changed, 8 insertions(+), 4 deletions(-) create mode 100644 db/versions/11359-navyPaniculata/00-firstScript.sql diff --git a/db/versions/11359-navyPaniculata/00-firstScript.sql b/db/versions/11359-navyPaniculata/00-firstScript.sql new file mode 100644 index 000000000..6748d2104 --- /dev/null +++ b/db/versions/11359-navyPaniculata/00-firstScript.sql @@ -0,0 +1,8 @@ +DELETE FROM stateI18n + WHERE `name` IN ('Billed', 'Facturado', 'Assisted preparation', 'Preparación asistida', 'Shipped', 'Embarcado', 'Stowaway OK', 'Polizón OK'); + +UPDATE `state` SET nextStateFk = 43 + WHERE nextStateFk IN (11, 27, 30, 32, 41); + +DELETE FROM `state` + WHERE code IN ('INVOICED', 'ASSISTED_PREPARATION', 'BOARD', 'OK STOWAWAY', 'PARTIAL_PREPARATION'); \ No newline at end of file diff --git a/modules/monitor/back/methods/sales-monitor/salesFilter.js b/modules/monitor/back/methods/sales-monitor/salesFilter.js index 927f49999..9f03c57a0 100644 --- a/modules/monitor/back/methods/sales-monitor/salesFilter.js +++ b/modules/monitor/back/methods/sales-monitor/salesFilter.js @@ -342,7 +342,6 @@ module.exports = Self => { 'CHECKED', 'PACKING', 'PACKED', - 'INVOICED', 'ON_DELIVERY', 'PREPARED', 'WAITING_FOR_PICKUP', @@ -350,10 +349,7 @@ module.exports = Self => { 'PRINTED_BACK', 'LAST_CALL', 'PREVIOUS_PREPARATION', - 'ASSISTED_PREPARATION', - 'BOARD', 'PRINTED STOWAWAY', - 'OK STOWAWAY', 'HALF_PACKED', 'COOLER_PREPARATION' ]}}; -- 2.40.1