cancel
Showing results for 
Search instead for 
Did you mean: 

classed based SAP workflow user decision with link to document

sugandhianand
Explorer
0 Kudos

Hello experts,

i have created a workflow using the custom class (implemented the IF_workflow) for sales order approval. my workflow is triggered sucessfully and got the workitem as well. but the problem is i am not getting link in the workitem which will take me to the sales document under "object  and attachment ".

i checked over SCN and found that i need to do binding between instance of my class to the _WI_OBJECT_ID. but while doing the binging i am getting error " the object catagories "CL" and "BO" are not compatible."

i am using standard user decision task TS00008276 with BOR as Decision and method as process.n

please suggest how to get the sales order display link under object and attachement in the workitem.

Regards

Anand

Accepted Solutions (0)

Answers (3)

Answers (3)

sugandhianand
Explorer
0 Kudos

Yes it is copy of the standard decision task TS00008276. i have replaced BOR with my custom class so as to enable the binding of _wi_object_id with the class and get the document link in the workitem.

things are working as expected, by copying the standard task i am getting the document link under"object and attachment ' section of workitem. but on clicking of it i am getting the error " user decision ********** has no alternative index 0000.

sbl
Active Contributor
0 Kudos

Anand,

For me the standard decision task is TS00008267 I don't have the task TS00008276 in my system what system are you working on ?

Besides the standard decision task TS00008276 is with BOR DECISION and method Process and the BOR  shall not be replaced.


You can pass in the Object Ad Hoc your personnal object.

Cheer

Stephane

sugandhianand
Explorer
0 Kudos

Hi Stephane,

thanks for the reply,

i moved the code of display method of BOR BUS2032 in the BI_OBJECT~EXECUTE-DEFAULT_METHOD. but still my workitems going in error upon clicking the workitem in sap mail box.

i have checked the log for the workflow and found this message under step history " user decision 000012357 has no alternative index 0000.

please suggest how to solve this error.

Regards

Anand

sbl
Active Contributor
0 Kudos

Anand,

Normally the code is not to be developped into the default method it shall call another method that you would have developped and then you only have to call this method (eg : me->display( ) )

You can easily test this method from your class directly, copying can be good but may be not enough

Also your decision task is this a copy of the standard decision task ? have you manage the decision ?

Cheers

Stephane

anjan_paul
Active Contributor
0 Kudos

Hi,

  You have to write proper code to excute transaction in method BI_OBJECT~EXECUTE_DEFAULT_METHOD of class

sugandhianand
Explorer
0 Kudos

Hi Anjan,

colud you please provide more details on the code that i have to written inside the method.

Also , i have copied the standard generic decision task TS00008276 to custom task and replace the BOR with my custom class and its method. did the proper binding of class and _wi_object_id. executed the workflow and workitem generated with the link in the work item "objects and attachment" section. but the problem is now when i double click on the workitem or the link my work item goes into the error status with error message " user decision 000012357 has no alternative to index 0000.

i don't have clue to solve this error.

sbl
Active Contributor
0 Kudos

Hi Anand,

I don't think that we are in this forum to really provide you the code you need to generate, that is your job or the job of your developper.

Especially you have decided to work with an ABAP Oject, you have teh BOR object (BUS2032)

which has a method display from which you can certainly get some inspiration

So insert the code there if it does not work get back to us

Cheers

Stephane