Hello, I want to set it up so that Task F is no longer executed when Task G or Task H is started. I understand that. However, I also want to set it up where it says ‘approved’ in the edge. Do I need to set it up the same way as in Task G or H, or can it be configured differently in the edge? Thanks for your help
Hello my friend!
As we said in previous posts, I’m not knowledgeable about Camunda 8, but in Camunda 7 you can do it as follows, maybe this will help you with some ideas.
-
Add a “start” execution listner to task G and task H.
-
In this execution listner you need to put:
execution.setVariable("skipTaskF", true);
-
Do the same for task G and task H.
-
Add the following validation to your conditional boundary event:
${skipTaskF == true}
and in the “variable events” field you type:
create, update
And as soon as your instance reaches task G or task H
NOTE: You need to place the flows to connect the conditional events of task D and task E to your XOR Gateway.
Haaaa I was going to forget…
In the flow of the “Not approved” path you can also set this variable just like you did in tasks G and H.
Or instead of setting this variable the same in each of the tasks, you can set it directly in the gateway, so you don’t need to repeat code and all paths followed from the gateway will have the same behavior as skipTaskF