From 2978af834103a3075db6fab85dde611781ac6e24 Mon Sep 17 00:00:00 2001 From: carlossa Date: Thu, 21 Nov 2024 10:18:17 +0100 Subject: [PATCH 1/3] fix: hotfix errorMyTeam --- modules/order/back/methods/order/filter.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/order/back/methods/order/filter.js b/modules/order/back/methods/order/filter.js index f8df6e10e..b60fab6a9 100644 --- a/modules/order/back/methods/order/filter.js +++ b/modules/order/back/methods/order/filter.js @@ -79,12 +79,12 @@ module.exports = Self => { const models = Self.app.models; const conn = Self.dataSource.connector; const myOptions = {}; + const userId = ctx.req.accessToken.userId; if (typeof options == 'object') Object.assign(myOptions, options); const args = ctx.args; - // Apply filter by team const teamMembersId = []; if (args.myTeam != null) { @@ -102,7 +102,7 @@ module.exports = Self => { } if (args && args.myTeam) - args.teamIds = teamIds; + args.teamIds = teamMembersId; const where = buildFilter(args, (param, value) => { switch (param) { From 5ac255ac521e1534219a93a5e8c231e4be288e3e Mon Sep 17 00:00:00 2001 From: sergiodt Date: Thu, 21 Nov 2024 16:27:45 +0100 Subject: [PATCH 2/3] fix: refs #7855 refs#7855 isCheckedDeleted --- back/models/expedition_PrintOut.json | 3 --- 1 file changed, 3 deletions(-) diff --git a/back/models/expedition_PrintOut.json b/back/models/expedition_PrintOut.json index dd49b0234..23a2fdbc4 100644 --- a/back/models/expedition_PrintOut.json +++ b/back/models/expedition_PrintOut.json @@ -14,9 +14,6 @@ }, "itemFk": { "type": "number" - }, - "isChecked": { - "type": "boolean" } } } \ No newline at end of file From c73196edece03a7cbf369773b0e9253870fba700 Mon Sep 17 00:00:00 2001 From: guillermo Date: Fri, 22 Nov 2024 09:10:18 +0100 Subject: [PATCH 3/3] fix: refs #7834 expeditionScan_Put no throw --- db/routines/vn/procedures/expeditionScan_Put.sql | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/db/routines/vn/procedures/expeditionScan_Put.sql b/db/routines/vn/procedures/expeditionScan_Put.sql index fc7d4da23..999b9af10 100644 --- a/db/routines/vn/procedures/expeditionScan_Put.sql +++ b/db/routines/vn/procedures/expeditionScan_Put.sql @@ -4,12 +4,12 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` PROCEDURE `vn`.`expeditionScan_Put`( vExpeditionFk INT ) BEGIN - IF NOT (SELECT TRUE FROM expedition WHERE id = vExpeditionFk LIMIT 1) THEN - CALL util.throw('Expedition not exists'); + IF NOT EXISTS (SELECT id FROM expeditionPallet WHERE id = vPalletFk) THEN + CALL util.throw('Pallet not exists'); END IF; - IF NOT (SELECT TRUE FROM expeditionPallet WHERE id = vPalletFk LIMIT 1) THEN - CALL util.throw('Pallet not exists'); + IF NOT EXISTS (SELECT id FROM expedition WHERE id = vExpeditionFk) THEN + CALL util.throw('Expedition not exists'); END IF; REPLACE expeditionScan(expeditionFk, palletFk)