Hi,
I have a (human) task in my BPMN where one of three options need to be selected on a form. I have used an XOR gate in the BPMN connecting the input to the outputs. In the forms I am using radio buttons to enable the selection of one of the three options, and have defined the returned key as 0, 1, 2.
How can I put this is in the script if the individual flows of the outputs of my XOR gateway.
Hello,
please follow these steps:
- In the process create a global process variable (i.e. optionVar) (I consider you don't use business variables to simplify)
- In the human task (ht) create a contract input, let's call it optionInput (choose the same type you defined in the variable)
- Go back to the process variable declaration and in the "Default value" field map the value to the optionInput.
- In the ht create a form. Replace the input widget with a radio button, but be careful, the form variable formOutput should respect the contract
- Go back to the process, on each transition after the gateway put a condition using the variable optionVar. Remember to leave one transition as default
If this looks unclear I'd recommend to follow a Bonita Camp (for free).
Kind regards