I'm currently working with the new Business Process Flows functionality and I would like to see Jscript support for switching stages and manipulating fields inside the Business Process Flows itself.
It would be very nice if we would be able to add Jscript functions against a OnMoveNextStage and OnMovePreviousStage in the same fashion as we assign function to the OnSave and OnLoad functionality on Forms.
The functions should give information about the currently selected stage (ID and friendly name), the stage it's moving towards and possibly even the fields included in the stage with full Xrm.Page support for manipulating the fields.
I'm currently manipulating fields by prepending "header_process" in the field ID when I want to manipulate BPF fields but this functionality has to work based on switching towards a specific stage.
Adding OnSave functions does not fully cover this functionality as OnSave will trigger before the stage is actually changed.
Hiding a stage is supported by defining branching logic that gets evaluated and alter the active path. Arbitrary jumps with a MoveToStage function would corrupt the traversed path information and are, consequently, not supported.
Regarding exposing the stage steps as full fields in the Xrm.Page.ui controls collection and refreshing the process control (chevrons), these are great suggestions! We will consider this in our roadmap.