1 year ago

#112377

test-img

jor

SAP Workflow read decision note from CDS view for mail template

As the title suggests, I must read the decision note from a workflow user decision task in a CDS view (https://blogs.sap.com/2013/04/01/sap-workflow-decision-task-new-capability-to-add-notes/). The CDS view is used to provide data to a mail template, which is send after a user has declined a certain workflow step. The decision note why the item was declined should be send within the mail to inform the recipient what went wrong.

In ABAP there exists two different functions (SO_NOTE_READ or SO_DOCUMENT_READ_API1) to read the decision note, which worked great and I was able to read the decision notes easily. However I could not find an equivalent in pure CDS.

I also found two different solution to solve the issue. But the solution only enables me to access the database layer with SQl queries or use virtual elements annotations. ABAP CDS View - use a class method The latter solution only works with an annotation based solution, which the mail template is not and I did not found a solution on how to read the decision note from purely SQL.

Anyone has a solution to replace the FM SO_NOTE_READ in purely CDS for this issue? Note that I am using a flexible workflow and mails are triggered with the Fiori App "Maintain E-Mail templates" thus sending the mail with ABAP is not possible/wanted.

workflow

abap

cds

s4hana

0 Answers

Your Answer

Accepted video resources