2024-01-15 11:31:03 +00:00
|
|
|
DELIMITER $$
|
|
|
|
CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `vn`.`invoiceIn_afterDelete`
|
|
|
|
AFTER DELETE ON `invoiceIn`
|
|
|
|
FOR EACH ROW
|
|
|
|
BEGIN
|
2024-04-04 13:04:23 +00:00
|
|
|
CALL invoiceIn_checkBooked(OLD.id);
|
|
|
|
|
2024-01-15 11:31:03 +00:00
|
|
|
INSERT INTO invoiceInLog
|
|
|
|
SET `action` = 'delete',
|
|
|
|
`changedModel` = 'InvoiceIn',
|
|
|
|
`changedModelId` = OLD.id,
|
|
|
|
`userFk` = account.myUser_getId();
|
|
|
|
END$$
|
|
|
|
DELIMITER ;
|