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

12 lines
312 B
MySQL
Raw Normal View History

2024-03-14 07:36:19 +00:00
DELIMITER $$
CREATE OR REPLACE DEFINER=`vn-admin`@`localhost` TRIGGER `vn`.`parking_afterDelete`
2024-03-14 07:36:19 +00:00
AFTER DELETE ON `parking`
FOR EACH ROW
BEGIN
INSERT INTO parkingLog
SET `action` = 'delete',
`changedModel` = 'Parking',
`changedModelId` = OLD.id,
`userFk` = account.myUser_getId();
END$$
DELIMITER ;