2024-08-22 15:02:59 +00:00
|
|
|
DELIMITER $$
|
2024-10-01 06:51:03 +00:00
|
|
|
CREATE OR REPLACE DEFINER=`vn`@`localhost` TRIGGER `vn`.`roadmap_beforeUpdate`
|
2024-08-22 15:02:59 +00:00
|
|
|
BEFORE UPDATE ON `roadmap`
|
|
|
|
FOR EACH ROW
|
|
|
|
BEGIN
|
2025-01-21 13:03:50 +00:00
|
|
|
SET NEW.editorFk = account.myUser_getId();
|
|
|
|
IF NEW.tractorPlate IS NOT NULL THEN
|
|
|
|
CALL vehicle_checkNumberPlate(NEW.tractorPlate, NULL);
|
|
|
|
END IF;
|
|
|
|
IF NEW.trailerPlate IS NOT NULL THEN
|
|
|
|
CALL vehicle_checkNumberPlate(NEW.trailerPlate, NULL);
|
2024-08-22 15:02:59 +00:00
|
|
|
END IF;
|
|
|
|
END$$
|
|
|
|
DELIMITER ;
|