How to: Enable a Form or List for Workflow [AX 2012]

In Microsoft Dynamics AX, each form or list that is to be used by workflow must be enabled for workflow. This topic describes the steps to enable a form for workflow. It also describes the steps to enable a list for workflow.

When a form is enabled for workflow, the workflow menu bar is automatically inserted at the top of the form, below the form title bar or action pane. The workflow menu bar provides everything that you must have to interact with a workflow. The menu bar contains workflow action buttons, such as Submit and Complete, and data fields that contain workflow instructions, configuration name, and information icons.

To display the Submit button, the form must have a canSubmitToWorkflow method.

Note: The form data source, or table, must contain a field for the workflow state of the document. For example, a field that contains the workflow state NotSubmitted should be updated to Submitted when the user clicks the Submit button on the form.

To enable a form for workflow
  1. In the Application Object Tree (AOT), expand the Forms node.

  2. Expand the form that you want to enable for workflow, and then expand the Designs node.

  3. In the Designs node, right-click the Design child node, and then click Properties.

  4. In the Properties sheet, set the following properties.

    Property Value
    WorkflowEnabled Set to Yes to enable the workflow menu bar on the form. The default setting is No.
    WorkflowDataSource Set to the same root data source specified in the query used for the Document property on the workflow type.
    WorkflowType Set to the workflow type that you want to use for the list.
  5. In the AOT, right-click the form, and then click Save.

To enable a list for workflow
  1. In the Application Object Tree (AOT), expand the Forms node.

  2. Expand the form for the list that you want to enable for workflow, and then expand the Designs node.

  3. In the Designs node, right-click the Design child node, and then click Properties.

  4. In the Properties sheet, set the following properties.   
    Property Value
    WorkflowEnabled Set to Yes to enable the workflow menu bar on the list. The default setting is No.
    WorkflowDataSource Set to the same root data source specified in the query used for the Document property on the workflow type.
    WorkflowType Set to the workflow type that you want to use for the list.

   5.    In the AOT, right-click the List, and then click Save.

No comments:

Post a Comment