feat: refs #7584 workerTimeControl_afterDelete
gitea/salix/pipeline/pr-dev There was a failure building this commit Details

This commit is contained in:
Robert Ferrús 2024-12-16 07:40:49 +01:00
parent ec2b6dd0c2
commit 1d7e69cb25
1 changed files with 7 additions and 5 deletions

View File

@ -3,10 +3,12 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`workerTimeControl_after
AFTER DELETE ON `workerTimeControl`
FOR EACH ROW
BEGIN
INSERT INTO workerLog
SET `action` = 'delete',
`changedModel` = 'WorkerTimeControl',
`changedModelId` = OLD.id,
`userFk` = account.myUser_getId();
IF account.myUser_getId() THEN
INSERT INTO workerLog
SET `action` = 'delete',
`changedModel` = 'WorkerTimeControl',
`changedModelId` = OLD.id,
`userFk` = account.myUser_getId();
END IF;
END$$
DELIMITER ;