cancel
Showing results for 
Search instead for 
Did you mean: 

Workflow for z report

former_member211992
Active Participant
0 Kudos

Dear all

Im new to workflow , i have got a requirement to run a program in a background. here is my requirement.

1)User used to schedule a z report (PO creation BAPI_PO_CREATE1) in a background .

2) after job has finished workflow has to be triggered with the output from job (error po's and success po's).

3) there is a decision making in the mail if user click YES then all success po's should get processed in the BG.

How to achieve this ,,

Thanks

Accepted Solutions (0)

Answers (4)

Answers (4)

former_member211992
Active Participant
0 Kudos

Dear all,

Thanks for ur replies,

1) i have created BO in swo1.

2)I am calling FM  CALL FUNCTION 'SAP_WAPI_CREATE_EVENT' to create event in my zreport.

3) created workflow for BO for mail triggering .

Now i am able receive a mail with decision YES and NO.

but i have to send mail with some data's  which i m getting in my zreport

former_member185167
Active Contributor
0 Kudos

Is that a question? Sending a mail is easy.

former_member185167
Active Contributor
0 Kudos

Hello,

You should turn on the event trace (SWEL) via transaction SWELS and get the user to schedule his report. Check to see which events get created. You can then use those events to start separate workflows for each PO and have the relevant user approve each one.

Approving in bulk is often pointless, nothing gets checked.

regards

Rick

ronen_weisz
Active Contributor
0 Kudos

For using a workflow you will need an object key, since this is a z-object you can use any z name use want. For the key you can use a job number or any other key that will link all the PO of the job.

Use sap_wapi_create_event FM to raise the event for staring the workflow. you will need a screen that will display the PO's created by the job (default method for your object)

Use can use a decision task for the yes/no task (transfer your new object to it)

After the yes create another method for the BG processing and use it in a task.

What should happen if the user selects "no"?

However, this is something that can be done by a report and not necessarily by workflow. you can simply send a mail at the end of the job let people knew they should check the results.

siva_subramanian2
Participant
0 Kudos

Hi Peter,

We do have standard Workflow which is similar to your requirement. But its for single PO. BUS2012 Busniess object is used. So whenever a PO is created this workflow will trigger.Please check with this busniess Object.

If you need to deal with bulk POs then i guess you need to copy and customize the STD PO Workflow with busniess object BUS2012.

Thanks

Siva.A