8093-devToTest_2442_3 #3100

Merged
alexm merged 284 commits from 8093-devToTest_2442_3 into test 2024-10-15 06:51:43 +00:00
2 changed files with 8 additions and 5 deletions
Showing only changes of commit ba9d0743b5 - Show all commits

View File

@ -23,9 +23,14 @@ BEGIN
DELETE FROM messageInbox WHERE sendDate < v2Months;
DELETE FROM messageInbox WHERE sendDate < v2Months;
DELETE FROM workerTimeControl WHERE timed < v4Years;
SET @canDeleteItemShelvingSale = TRUE;
DELETE FROM itemShelvingSale
WHERE itemShelvingFk IN (
SELECT id
FROM itemShelving
WHERE created < util.VN_CURDATE()
AND visible = 0
);
DELETE FROM itemShelving WHERE created < util.VN_CURDATE() AND visible = 0;
SET @canDeleteItemShelvingSale = NULL;
DELETE FROM ticketDown WHERE created < util.yesterday();
DELETE IGNORE FROM expedition WHERE created < v26Months;
DELETE cs

View File

@ -9,9 +9,7 @@ BEGIN
FROM itemShelvingSale
WHERE itemShelvingFk = OLD.id;
IF vItemShelvingSaleExists AND (NOT @canDeleteItemShelvingSale
OR @canDeleteItemShelvingSale IS NULL) THEN
IF vItemShelvingSaleExists THEN
CALL util.throw('Cannot delete item shelving with item shelving sale');
END IF;