fix: update mandate_afterDelete trigger to log actions in clientLog and drop mandateLog table
gitea/salix/pipeline/pr-master This commit looks good
Details
gitea/salix/pipeline/pr-master This commit looks good
Details
This commit is contained in:
parent
00f4fdf3f0
commit
760cc3b09a
|
@ -3,9 +3,9 @@ CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`mandate_afterDelete`
|
|||
AFTER DELETE ON `mandate`
|
||||
FOR EACH ROW
|
||||
BEGIN
|
||||
INSERT INTO mandateLog
|
||||
INSERT INTO clientLog
|
||||
SET `action` = 'delete',
|
||||
`changedModel` = 'mandate',
|
||||
`changedModel` = 'Mandate',
|
||||
`changedModelId` = OLD.id,
|
||||
`userFk` = account.myUser_getId();
|
||||
END$$
|
||||
|
|
|
@ -2,6 +2,5 @@ ALTER TABLE vn.clientLog MODIFY COLUMN changedModel
|
|||
ENUM('Client','Address','ClientContact','ClientDms','ClientObservation','ClientSample','ClientUnpaid','Greuge','Recovery','Mandate','TpvTransaction','WorkerDms','Sms')
|
||||
CHARACTER SET utf8mb3 COLLATE utf8mb3_unicode_ci DEFAULT 'Client' NOT NULL;
|
||||
|
||||
UPDATE vn.clientLog
|
||||
SET changedModel = 'Mandate'
|
||||
WHERE changedModel = '';
|
||||
DROP TABLE vn.mandateLog;
|
||||
|
||||
|
|
Loading…
Reference in New Issue