Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 40

SAP Business Workflow

Dhruvin Mehta

Contents
Introduction Workflow terminology and architecture Workflow Definition and workflow Template Workflow steps in details Task Business Objects and Methods Container Structure and Container Programming Events Agent assignment Workflow Tracing and Administration

Introduction
What is workflow?
SAP Business Workflow is a cross-application tool that makes it possible to integrate business tasks across departments, and applications.
It is a tool that automates business processes in a flexible and transparent way and maps the individual tasks to the users so that a push technology informs and helps the users through the process. Steps which do not require user intervention are carried out automatically, along with business logic and escalation procedures.

A workflow is an automated electronic representation of a Business Process. - Speed , Consistency , Quality. "the right work is brought in the right sequence at the right time to the right people". Before implementing SAP Business Workflow, organizations should start by asking a series of questions, such as: Which processes do we want to automate? To what extent can we change current procedures and pass them over to electronic control? What steps are these procedures made up of? Who are the individuals involved and what are their roles? How do we get the Work item to go to the right people?

Need of Workflow
2
Hmm ! Time to put in a purchase requisition request I wonder who approves buying this stuff?

TIME IS MONEY!!!
5

I guess Id better send off some inter-office mail to ask the approvers to approve my requisition.

4 Time drags on . . .

Meanwhile, in Mr. Managers office . . . What shall I do next?

Workflow Architecture
Organisational Level

Process Level

Business Object Level

How Process, Business Logic and People are linked in Workflows?

The business processes are defined in Workflow builder. Each and every small work process is called as an activity in the workflow builder. Each activity consists of a single step task, which can be a standard task or a workflow template. Associated Business Logic is built in Business Objects. i.e. ABAP code will be in Business Object. Business Objects consist of attributes, methods and events. Methods consist of ABAP code. Each and every standard task is associated with a Business Object and a method. People / Group of people responsible for taking actions are defined in organization structure. Person responsible for taking an action is called actual agent. It is defined in the workflow activity.

The Process (Business)


The People(Organization)

The Impact (Process Information)


|

Use and Benefits of workflow


Finding out what work needs to be done Planning of work that needs to be done amongst the group of people The identification of roles & responsibilities on who will do what, when & in how much time Working in coordination with others Informing next person about his work to be done, when the earlier one has finished his own Duplication of work that has been already done because of communication gap,inefficient knowledge transfer & the incomplete documentation in the central repository Identification of delay in the completion of the work Preparing status on this delay

A tool to fill functionality gaps!

Automatic Workflow Configuration

Workflow provides a number of tools for defining and analyzing workflows as well as for monitoring operation. They are:
Workflow Builder Business Object Builder

Business Workplace
System Admin Tools

SAP Business Workplace (SBWP)


You use this part of the Business Workplace if you want to use the functions of SAP Business Workflow. Business Workplace is the main interface between an end user and the workflow system. The end users Workflow inbox contains all dialog work items and missed deadline work items for which they are a specified recipient.

Business Workplace
Display Reserve Replace Forward

Execute

14-Mar-12

12

Workflow Log

14-Mar-12

13

14-Mar-12

Substitutes:

14-Mar-12

Terminology
Workflow builder Workflow tool for creating, editing and displaying the workflow definition Container Container elements for which the import or export indicator is set form the interface of the workflow.

Workitem Workitem is runtime representation of a task or a step in the workflow definition. There are various types of work item.
Triggering Event Triggering event is the one, whose occurrence triggers or starts the workflows or tasks. Step A step is an entity, which can be inserted into the workflow builder. Whenever executed, step gives the predefined desired results.

Task Task (Standard Task, Customer Task) is used to define the Activity step in workflow definition. Responsible Agent: Responsible Agent is a user assigned to a step in the step definition. Rule Workflow Binding Concept

Workflow Definition

A workflow definition describes the workflow process

Workflow definition consists of


1. 2. 3. 4. 5. Basic Data Information about triggering events Initial Values Containers Bindings

Workflow definition steps


Workflow definition is made up of individual steps. When creating a step in a workflow definition, the step type must be specified first. There are 1. Steps which refer to business activities (activities & user decision) 2. Steps which are used for internal process control and monitoring (condition, multiple condition, loop, etc)
Activity

Can be a single step task with basic business functionality Can be a multi-step task, which reference to a workflow definition
User Decisions

This provides an opportunity for user interaction with the system. The response to this decides the selection of the subsequent step.
Document from template

PA document is created from a document template using variables in the text that are filled during program execution.

Condition Branch on the basis of control information from the runtime dependent context of the workflow. An attribute of this object can also be accessed for condition evaluation Condition evaluation can be done by Field comparison e.g constants , object attribute, system fields
Multiple condition In contrast to condition, multiple condition makes it possible for the workflow definition to branch in more than two branches.

For evaluation of the multiple condition, the value of the basis of comparison is checked at runtime against the comparison values and branched accordingly.

Until Loop Steps are processed repeatedly until the condition contained in the UNTIL step is true.

Fork

Used for parallel processing branches. Only a part of the parallel processing branches actually has to run to continue the workflow. Dynamic parallel processing is also possible
Send mail - Text entered in this step can be used to send a mail to the agent assigned Container operationss - Used to perform arithmetic operation of value assignment to workflow container elements using constants and data in the workflow container . Event Creator An event is created when this step in the workflow is reached. Other workflows can be started as a reaction to the event created in this step. This event must be the triggering event of the relevant workflow tasks and/or templates.

WAIT for event Used to stop the whole execution of the workflow until the event is created in the system. Used to wait for events for parallel processing

Simple WF for User Decision and mail

Workflow Builder (SWDD)


All Step Types
User Decision

Send Mail
Condition Step Multiple Condition Step Container Operation Form (approve and Change)

Workflow Builder (SWDD)


All Step Types
FORK LOOP Process control Event creator and wait Block and local WF Document template

Workflow Builder (SWDD)


All Step Types
Process control
Process Control is a very important Step-Type, since it performs a lot of Functions. Now let us look at each of the Functions individually

Cancel Work item The process control step should be located in the branch of a parallel section. To uniquely identify the work item to be canceled, we must enter its node number in the 'workflow step' field. Press F4 to find all possible entries for the node numbers. The work item selected is set to the status logically deleted at the time of step execution. The workflow is not continued after this work-item. It terminates.

Cancel Work-Flow Using this function, all work items of the workflow are set to the status logically deleted. If the step Process control is located in a workflow that is used as a sub workflow, the branch of the calling workflow that contains the sub workflow is stopped.

Set Work-Item to Obsolete Use this Function, when process control is located in the branch of a modeled deadline monitoring. We can then set the work item that has exceeded its deadline, to the status completed and continue processing in the branch processing obsolete. In order to uniquely identify the work item to be cancelled, we must enter its node number in the field workflow step..

The work item selected is set to the status completedat the time of step execution.

Subtype
The subtype inherits all attributes, methods and events of the supertype and is open for new customer-specific attributes, methods and events. The key fields of the supertype and subtype must be identical. This means that any methods and attributes defined on the parent can be executed and accessed on the child object.

Delegation

Transaction: Menu Path: SW01 Tools Business Workflow - Development - Definition tools - Business Object Builder Settings - Delegate

This delegation is powerful because it lets you implement your own business logic without modifying any SAP code. As long as the objects are properly delegated, your method will be executed.

KNA1 Calling Program Method: Change password

ZKNA1 Method: Change password

Business Object Repository (BOR)

Transaction: Menu Path: SW01 Tools Tools - Business Workflow Defination tool Busniness Object Builder

SWC_GET_ELEMENT CONTAINER 'CustomerNumber' CUSTOMERNUMBER. N SWC_SET_ELEMENT COTAINER 'Return' RETURN.

SWC_SET_TABLE CONTAINER 'SalesOrders' SALESORDERS.

Deadline monitoring
A major advantage of workflow is the ability to monitor the workflow steps according to a predefined schedule.
Requested Start Latest Start Requested End Latest End

Task (PFTC)

Task executed in background depending on object method

At runtime user can create attachments User explains explicitly that work item is no longer is to be processed

Background
SAPphones

Confirm end of processing

The workflow dials the telephone number attached to the current customer

Tracing the events triggered during the execution of a transaction (SWELS , SWEL )

Binding and data flow


SWO1 BOR pro SWI1 SWETYPV

Agent determination
administration

You might also like