#5858 - zoneCollisions #1853
|
@ -0,0 +1,47 @@
|
|||
DROP TRIGGER IF EXISTS `vn`.`zoneIncluded_afterInsert`;
|
||||
USE `vn`;
|
||||
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `vn`.`zoneIncluded_afterInsert`
|
||||
AFTER INSERT ON `zoneIncluded`
|
||||
FOR EACH ROW
|
||||
BEGIN
|
||||
INSERT INTO zoneLog
|
||||
SET `action` = 'insert',
|
||||
`changedModel` = 'zoneIncluded',
|
||||
`changedModelId` = OLD.zoneFk,
|
||||
`userFk` = account.myUser_getId();
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
||||
DROP TRIGGER IF EXISTS `vn`.`zoneIncluded_afterUpdate`;
|
||||
USE `vn`;
|
||||
|
||||
DELIMITER $$
|
||||
CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `vn`.`zoneIncluded_afterUpdate`
|
||||
AFTER UPDATE ON `zoneIncluded`
|
||||
FOR EACH ROW
|
||||
BEGIN
|
||||
INSERT INTO zoneLog
|
||||
SET `action` = 'update',
|
||||
`changedModel` = 'zoneIncluded',
|
||||
`changedModelId` = OLD.zoneFk,
|
||||
`userFk` = account.myUser_getId();
|
||||
END$$
|
||||
DELIMITER ;
|
||||
|
||||
-- DROP TRIGGER IF EXISTS `vn`.`zoneIncluded_afterDelete`;
|
||||
-- USE `vn`;
|
||||
|
||||
-- DELIMITER $$
|
||||
-- CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `vn`.`zoneIncluded_afterDelete`
|
||||
-- AFTER DELETE ON `zoneIncluded`
|
||||
-- FOR EACH ROW
|
||||
-- BEGIN
|
||||
-- INSERT INTO zoneLog
|
||||
-- SET `action` = 'delete',
|
||||
-- `changedModel` = 'zoneIncluded',
|
||||
-- `changedModelId` = OLD.zoneFk,
|
||||
-- `userFk` = account.myUser_getId();
|
||||
-- END$$
|
||||
-- DELIMITER ;
|
Loading…
Reference in New Issue