At this point, you have performed all the steps required to process workflows. Running an actual Workflow is the best way to test the Workflow system. Depending on your license scheme, Dynamics AX will be equipped with default Workflow templates. In this example, we will cover the process of testing the Workflow system using the Purchase requisition workflow template.
- In Dynamics AX, go to Account Payable | Setup | Workflow configurations to load the Workflow configuration form specific for Accounts Payable business processes.
- In the Workflow configuration form, select the PurchReqApproval template from the Template drop-down.
- To create a new Workflow configuration for Purchase requisitions, click on the New button. The Create configuration: Select a template form will load. Select Purchase requisition approval and click on the Create configuration button to start creating the new configuration.
- After you have clicked on the Create configuration button, a new form Workflow: Purchase requisition approval will load.
- Provide the relevant field information in the current view. Various fields are required to be filled out in order to save a configuration. In this view, we must provide text in the Submission instructions field. You can set a specific condition that will allow this workflow to initiate. If the condition isn’t satisfied, the workflow will not proceed. For example, perhaps you would want the workflow to be used for Purchase requisitions that have a specific value. Instead of waiting for the workflow to run in order to verify that it works on specific conditions, you can simply test the conditions as you create them by clicking on the Test condition button. This will allow you to test your conditions on existing Purchase requisitions.
- In the next step, we must specify the required parameters for the complete and approval stage of the Purchase requisition workflow template. Each workflow may have different stages and each stage has fields that are required to be populated. To specify the parameters for the complete and approval stages in the Purchase requisition workflow, click on the Details tab.
- Select the PurchReqComplete task to specify the parameters for the complete stage as you did when you were in the General tab. When you have specified the required fields, collapse the PurchReqApproval task and select Step 1.
- You must also assign a user, group, or role that can approve the PurchReqComplete task. To specify a user, click on the Assignment tab.
- To specify a user, click on the Choose button. This will load the Assignment form where you can select a specific user, group, role, or hierarchy. You can also specify a time limit for how long a task must be approved by until it expires. Once you have specified the appropriate parameters, click on the OK button.