Workflow Approval State Transitions
Applies To: Microsoft Dynamics AX 2012 R3, Microsoft Dynamics AX 2012 R2, Microsoft Dynamics AX 2012 Feature Pack, Microsoft Dynamics AX 2012
Microsoft Dynamics AX workflow documents that are enabled for workflow approvals typically support at least five workflow states. The current workflow state of a workflow can be maintained in a table field associated with the workflow document. As the state of the document is changed, the state field in the table should be updated. This topic describes workflow approval states.
Workflow State
Workflow state determines what you can do with the workflow document as soon as it is available in the system. Workflow states are defined by developers and must be supported in queries and business logic for operations that are controlled by workflow. Workflow approvals typically use the following workflow states.
Workflow state |
Use |
---|---|
NotSubmitted |
The state of the document before it is submitted to workflow or if the workflow is canceled. This is the state of all documents before a workflow instance is instantiated for the document. |
Submitted |
The state of the document as soon as the workflow is activated and the document is submitted to workflow. This is a temporary state when the user activates a workflow, but the system has not yet processed the workflow for activation. For more information, see How to: Activate a Workflow from a Workflow Type. |
PendingApproval |
The state of the document as soon as the approval starts and remains in this state until the approval is completed, returned for a change, or rejected. |
ChangeRequested |
The state of the document if a change is requested or the document is returned. |
Approved |
The state of the document when the approval is completed. |
The following diagram illustrates a typical approval state transition model.
Here are some general guidelines for workflow state:
Avoid creating your own workflow states unless you have a business justification for doing this.
Consider refactoring existing approval states so that you can take advantage of the states listed here.
See also
Walkthrough: Adding Workflow to an Existing Form
Requirements for Enabling Workflow in an Application Module
Announcements: New book: "Inside Microsoft Dynamics AX 2012 R3" now available. Get your copy at the MS Press Store.