I'm trying to automate the workflow via database creating a trigger that can be able to create a case when an opportunity reach the Closed Won level.
CREATE TRIGGER after_opportunity_closed_won
AFTER UPDATE ON opportunity
FOR EACH ROW
BEGIN
IF (NEW.last_stage = 'Closed Won') THEN
INSERT INTO `case` (description, account_id, contact_id, name, status)
VALUES (NEW.description, NEW.account_id, NEW.contact_id, 'Implantação', 'Aberto');
END IF;
END;
First of all, all the installation where made by following the Docker tutorial documentation on the EspoCRM website.
Secondly, I made a test in a local server with Xampp and got success, but I cannot repeat the proccess with Docker.
Some of you jedi's of the EspoCRM can help me?
I know it's possible but I'm not being able to reprocuce on a Docker enviroment.
CREATE TRIGGER after_opportunity_closed_won
AFTER UPDATE ON opportunity
FOR EACH ROW
BEGIN
IF (NEW.last_stage = 'Closed Won') THEN
INSERT INTO `case` (description, account_id, contact_id, name, status)
VALUES (NEW.description, NEW.account_id, NEW.contact_id, 'Implantação', 'Aberto');
END IF;
END;
First of all, all the installation where made by following the Docker tutorial documentation on the EspoCRM website.
Secondly, I made a test in a local server with Xampp and got success, but I cannot repeat the proccess with Docker.
Some of you jedi's of the EspoCRM can help me?
I know it's possible but I'm not being able to reprocuce on a Docker enviroment.