Stage gates in a Business Process Flow

Within a business process flow (BPF), when moving from one stage to the next, the system checks whether the mandatory fields for that particular stage have been populated or not. Consider the field ‘Payment timeline Completed’ in the example below. It’s defined as a ‘Two Options’ data type with the two options being ‘Yes’ or ‘No’. The stage won’t be considered complete until this field is set to yes.

Now consider an example of a field (Variation required) being defined as an ‘Option Set’ rather than ‘Two Options’. In this case the system doesn’t know what is the correct value is for the step so it doesn’t perform field validation.

So, to implement field validation similar to the above scenario, a JavaScript event handler is added for the stage’s OnPreStageChange event. (Thanks to debajmecrm.com for the code.)

Then, when ‘Variation Required’ = No, and the user tries to move to the next stage in the process, the following alert is generated