SAP Business Workflow: Dhruvin Mehta
SAP Business Workflow: Dhruvin Mehta
SAP Business Workflow: Dhruvin Mehta
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 . . .
Workflow Architecture
Organisational Level
Process Level
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.
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
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
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
Send Mail
Condition Step Multiple Condition Step Container Operation Form (approve and Change)
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.
Transaction: Menu Path: SW01 Tools Tools - Business Workflow Defination tool Busniness Object Builder
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)
At runtime user can create attachments User explains explicitly that work item is no longer is to be processed
Background
SAPphones
The workflow dials the telephone number attached to the current customer
Tracing the events triggered during the execution of a transaction (SWELS , SWEL )
Agent determination
administration