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

Use

To define the flow of the approval process in the system, create a workflow consisting of a workflow definition and a multistep task workflow template. If you create a workflow from the Workflow Builder, the system creates the required multistep task automatically.

Prerequisites

You are in the Workflow Builder and an initial workflow definition is displayed.

Procedure

Create Workflow

  1. Choose This graphic is explained in the accompanying text.
  2. Enter the initial basic data for the workflow in the dialog box displayed.

  3. Enter an abbreviation (of your choice) and a name (of your choice) for the workflow to be created.
  4. Abbreviation: <ini_ws>

    Name: <Workflow: notification of absence (ini)>

  5. Choose This graphic is explained in the accompanying text.
  6. The dialog box Create object directory entry is displayed.

  7. Choose Local Object.

The system has now allocated an 8-digit number for your workflow. This number is made up of the 3-digit prefix number (a setting in Customizing) and a 5-digit number taken from a number range. This number together with the letters WS forms the workflow ID. Make a note of the ID so that you can later call the workflow more quickly.

You return to the Workflow Builder. The workflow ID and the current status of the workflow are displayed in the information area.

Entering the basic data for the workflow

  1. Switch to the basic data of the workflow. Choose This graphic is explained in the accompanying text.
  2. The basic data for the workflow, divided into version-dependent and version-independent data, is displayed.

    Entering a workflow description

  3. Switch to the Version-independent (task) tab page and then to the Description tab page.
  4. Choose Task description as the text type. Click on the text Click here to edit task.
  5. The Task description screen is displayed. You can create a text here using the SAPscript Editor.

  6. Enter a text that describes the task. You can use the following proposal:
  7. <You can use this workflow to create a notification of absence. This will then be sent to your superior for review. You will be notified of the result of this review.

    If your request is rejected, you can revise it and resubmit it for review or withdraw it completely.>

  8. Choose This graphic is explained in the accompanying text to go back to the processing of the workflow.
  9. Determining agents

    To enable the workflow to be started in dialog, you have to assign possible agents to the workflow.

  10. Choose This graphic is explained in the accompanying text in the application toolbar.
  11. The workflow template: agent assignment screen is displayed.

  12. Position the cursor on the name of your workflow.
  13. Choose Properties…
  14. You go to the dialog box Task.

  15. Set the General task flag.
  16. Choose This graphic is explained in the accompanying text Copy and then This graphic is explained in the accompanying text.
  17. Caution

    Designating your workflow as a general task means that every user in the system is authorized to start this workflow in dialog.

  18. Exit the basic data of the workflow and choose Save.

Result

You have created a workflow with its basic data. The required multistep task was created automatically by the system.

To create a workflow definition, you need tasks that are used as steps in the workflow definition.

Additional information: Tasks

A task can either be a single-step task or a multistep task. In our example of the notification of absence, making the application and checking the application are single-step tasks. The entire procedure involved in processing a leave request consists of these (and other) single steps, and is therefore a multistep task.

Note

In this tutorial, a single step task is generally described as a task. The difference between the task types is only explicitly explained if there is a risk of confusion over multistep tasks. The term workflow is used as the umbrella term for the workflow template (and thus the multistep task) and the workflow definition. More precise differentiation only takes place if there is a risk of confusion.

For more information, see Definition of Multistep Tasks in the SAP Business Workflow documentation.

On a technical level, the main difference between single-step tasks and multistep tasks is that:

A workflow definition is made up of a sequence of different steps (for example, all steps required to process a leave request).

Standard tasks and workflow templates are client-independent. Customer and workflow tasks are client-dependent. Customer and workflow tasks are no longer supported and are therefore no longer used in this tutorial.

An Activity is a possible step type in a workflow definition. An activity refers to a task. It references a task, which can be a single-step or multistep task (subworkflow).

For more information, see Tasks and Task Groups in the SAP Business Workflow documentation.

Leaving content frame