Entering content frameProcedure documentation Unit 6: Defining a Workflow Locate the document in its SAP Library structure

Use

A mail is to be sent once the production order has been released. This is carried out by a workflow which you will define in this unit.

Procedure

  1. Choose Tools ® Business Workflow ® Development ® Definition Tools ® Workflow Builder ® Workflow Builder.
  2. The Workflow Builder screen is displayed. If you are starting the Workflow Builder for the first time, an initial workflow definition is displayed there. Otherwise, the workflow that was processed last is opened.

  3. Choose This graphic is explained in the accompanying text.

The Workflow Builder - Create 'Unnamed' screen is then displayed. An initial workflow definition is displayed.

Create container element in the workflow container

You must now add a container element to the workflow container that can store an object reference to a production order.

  1. Choose <Double-click to create> by double-clicking in the Workflow Container tray.
  2. The dialog box for creating a new container element is displayed.

  3. Enter the following data:
  4. Element: ProductionOrder

    Name: Production order

    Short Description: Production order

    Object type category: BOR object type

    Object type: Zini_2005

  5. Set the Import and Mandatory flags on the Properties tab page.
  6. Choose This graphic is explained in the accompanying text.

The new container element is displayed in the workflow container tray. The symbol This graphic is explained in the accompanying text shows that the new container element is an import parameter of the workflow and thus belongs to the workflow interface.

Saving the workflow

  1. Choose This graphic is explained in the accompanying text.
  2. Enter the following data:
  3. Abbreviation: Zini_Mail

    Name: <Mail for production order>

    The dialog box Create object directory entry is displayed.

  4. Choose Local Object.

Determine Triggering Event

If a workflow is to be started by an event, you must define this as a triggering event. In this scenario, the workflow is to be started as a response to the released1 event of your object type Zini_2005. You must activate the type linkage for this event and define a binding.

  1. Choose This graphic is explained in the accompanying text.
  2. The basic data of the workflow is displayed.

  3. Change to the version-independent basic data on the tab page Start events.
  4. Enter the following data:
  5. Category: BOR object type

    Object type: Zini_2005

    Event: released1

    Activate the type linkage

  6. Click on This graphic is explained in the accompanying text in the event column.
  7. Active type linkages are marked with This graphic is explained in the accompanying text.

    Defining the binding between the event container and the workflow container

    The event parameter _Evt_Object of the event released1 contains the object reference to the released sales order.

    The event parameter _Evt_Creator of the event released1 contains the name of the person whose system user was used to generate the event. The name is stored in the form US<Name> in this element.

    This information must be transferred by means of a binding between the event container and the workflow container.

    The workflow container contains the production order (technical name: ProductionOrder) element you created as well as the standard initiator element (technical name: _WF_Initiator).

  8. Choose released1 This graphic is explained in the accompanying text in the event line.
  9. The Task: Binding for Triggering Events dialog box is then displayed. The workflow system has automatically assigned the contain element _Evt_Object of the event container to the ProductionOrder element of the workflow container.

  10. Choose This graphic is explained in the accompanying text to display all of the container elements in the workflow container to which you can define a binding.
  11. Assign the _Evt_Creator container element in the event container to the _WF_Initiator element in the workflow container. Use the F4 input help.
  12. Choose This graphic is explained in the accompanying text.
  13. Exit the basic data of the workflow and choose This graphic is explained in the accompanying text.
Leaving content frame