salix/db/routines/vn/triggers/workerDms_afterDelete.sql

13 lines
311 B
SQL

DELIMITER $$
CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`workerDms_afterDelete`
AFTER DELETE ON `workerDms`
FOR EACH ROW
BEGIN
INSERT INTO workerLog
SET `action` = 'delete',
`changedModel` = 'WorkerDms',
`changedModelId` = OLD.id,
`userFk` = account.myUser_getId();
END$$
DELIMITER ;