To define and enforce consistent business processes help people using the system can focus on their work and not to perform a set of manual steps. At times based on some conditions we must show or hide stages based on conditions. So here, in this post we see in the same vaccination use case provide discount based on status of Vaccination to the selected contact.
Login to the required environment and go to flows and select Business process flows as shown below figure.
After Step1, click on Vaccination flow and click on edit and go to components and select Condition Component and drag and drop it to Business Process Flow Designer and name it as Validate Vaccination as shown in the below figure.
After Step2, under Rules select Field as Vaccination Completed and operator as Equals and type as Value and select value as Yes and click on Apply as shown in the below figure.
After Step3, under true part of Validate Condition keep the step Provide Discount as shown in the below figure.
After Step 4, under false part of Validate Condition directly connect to Comments Stage which is common for the user to provide comments as shown in the below figure.
After Step 5, click on Update and Validate and Activate BPF as shown in the below figure.
After Step 6, navigate to dynamics crm instance and then open contact record and then select vaccination completed to yes and observe BPF Stage Discount showed as shown in the below figure.
After Step 7, if user selects vaccination completed to No and observe BPF Stage Discount Stage will be hidden as shown in the below figure.
- Make sure every stage and data steps are discussed before implementation.
- Validate,Save and Activate BPF without fail.
- Properly arrange connectors so that respective stages flow is represented for the user if conditional branching used.
- Microsoft Documentation found here
- BPF’s works only in Modern Driven Apps.
Conclusion: In this way, one can easily implement Conditional branching in Business Process Flow in Dynamics CRM.