Académique Documents
Professionnel Documents
Culture Documents
Scenario1:
Step1:
How to find the Business Object for the transaction that we are going to process
Step2:
To send a mail to SAP INBOX to show the purchase order (ME23N) when any new PO
is created or changed.
The main aim of this example is to make use of standard methods available in
business object.
This workflow will be triggered while changing and creating PO. So, add the events
for creation and change in start event of the workflow.
The created and changed events for this are displayed below
Go to transaction SWDD to start creating workflow
Basic Data
Click Active button in both the events to make this workflow gets triggered on PO
creation and changes
When the event gets activated, it will create an entry automatically in SWETYPV
transaction code.
NOTE: When workflow is not getting triggered, this is the first transaction you have
to look into.
BO name Events Our WF no.
What you need to check??!!
There was a method called Display in BUS2012 object. To call this method in
our workflow, we need to create a task.
Creation of task
Write the subject line for the mail in the work item text. Append the PO
number that wil be created or changed using Insert Variables
Insert
Variables
Double click this to insert the PO number
Save the Task.
Once task name is entered, system will ask whether all the objects present in
the task will be binding to our workflow. We need some variables in workflow
to bind with those tasks variables. So, the system will also suggest the
variables that need to be created in our workflow. The new variables will be
created in a place called workflow container.
_WI_OBJECT_ID is assigned with business
object BUS2012 in task container
Workflow Container
We have to give the user name that the work item will go.
Task Properties
We can set the possible agents in Agent Assignment. If we assign any number of
user names through Agent Assignment option, user can give only the user name
out of these names.
How to give possible list of agents who can perform this task??
It will show multiple agent types. Select any agent type. For our example, select
user and click continue.
If we dont want to restrict with any specified set of users list, make our task as a
general task.
Press Save
Open the work item
Test by SWUS
Go to transaction SWUS and enter the workflow number and PO number. This will
produce the output based on the last changes done to the transaction.
When you press F8, it will display the PO
Press Back.