refactor: refs #7567 Fix and improvement #2699

Merged
guillermo merged 8 commits from 7567-movingCleanFix into dev 2024-08-23 07:13:36 +00:00
1 changed files with 4 additions and 3 deletions
Showing only changes of commit 625b3a5608 - Show all commits

View File

@ -7,6 +7,8 @@ BEGIN
DECLARE vExpeditionFk INT;
DECLARE vBufferToFk INT;
guillermo marked this conversation as resolved
Review

esta es gastaba en el correu, pero com l'has llevat, sobra

esta es gastaba en el correu, pero com l'has llevat, sobra
DECLARE vBufferFromFk INT;
DECLARE vStateOutFk INT
DEFAULT (SELECT id FROM expeditionState WHERE `description` = 'OUT');
DECLARE vDone BOOL DEFAULT FALSE;
DECLARE vSorter CURSOR FOR
SELECT m.expeditionFk, m.bufferToFk, m.bufferFromFk
@ -52,10 +54,10 @@ BEGIN
OR (bufferFk = vBufferFromFk AND `position` > 0)
FOR UPDATE;
UPDATE expedition
UPDATE expedition
SET bufferFk = NULL,
`position` = NULL,
stateFk = (SELECT id FROM expeditionState WHERE `description` = 'OUT')
stateFk = vStateOutFk
WHERE id = vExpeditionFk;
UPDATE expedition
@ -64,7 +66,6 @@ BEGIN
AND `position` > 0;
COMMIT;
END LOOP l;
CLOSE vSorter;
END$$