diff --git a/db/routines/vn/procedures/collection_getTickets.sql b/db/routines/vn/procedures/collection_getTickets.sql index 0f675041a..4566792fa 100644 --- a/db/routines/vn/procedures/collection_getTickets.sql +++ b/db/routines/vn/procedures/collection_getTickets.sql @@ -23,7 +23,7 @@ BEGIN JOIN vn.ticketCollection tc ON tc.ticketFk = tob.ticketFk LEFT JOIN vn.observationType ot ON ot.id = tob.observationTypeFk WHERE ot.`code` = 'itemPicker' - AND tc.collectionFk = vParamFk + AND tc.collectionFk = vParamFk OR tc.ticketFk = vParamFk ) SELECT t.id ticketFk, IF(!(vItemPackingTypeFk <=> 'V'), cc.code, CONCAT(SUBSTRING('ABCDEFGH', tc.wagon, 1), '-', tc.`level`)) `level`, diff --git a/modules/worker/back/methods/device/handle-user.js b/modules/worker/back/methods/device/handle-user.js index ac4ff2704..55302c1cb 100644 --- a/modules/worker/back/methods/device/handle-user.js +++ b/modules/worker/back/methods/device/handle-user.js @@ -82,7 +82,7 @@ module.exports = Self => { const getDataOperator = await models.Operator.findOne({ where: {workerFk: user.id}, fields: ['numberOfWagons', 'warehouseFk', 'itemPackingTypeFk', 'sectorFk', 'sector', - 'trainFk', 'train', 'labelerFk', 'printer'], + 'trainFk', 'train', 'labelerFk', 'printer', 'isOnReservationMode'], include: [ { relation: 'sector',