cancel
Showing results for 
Search instead for 
Did you mean: 
Subscribe

Hello Everyone, We want to use SIDE EFFECT with RAP. We know how to do with local annotations. Is it possible to add side effect annotation via CDS annotations?

Accepted Solutions (0)

Answers (3)

Answers (3)

Ramjee_korada
Active Contributor

Hi Zafer,

I don't think that we can do in CDS. But its possible with fiori app . please see below blog posts for examples

https://blogs.sap.com/?p=1285336

https://blogs.sap.com/?p=1287257

Best wishes,

Ramjee Korada

Zafer
Participant
0 Likes

Hi Ramjee,

Thanks for your quick reply, We saw your blog which is really helpful but we are investigating to way to make it via CDS annotations. If not possible, we will definitely do it Fiori app annotation.

Thanks,

Zafer

Sschlegel
SAP Champion
SAP Champion
0 Likes

Hi Zafer,

it's not possible via CDS - an alternative would be to create an SEGW Project, use your RAP Entity via RDS and then add the annotation via MPC as described here:

Side Effect Annotations: Examples | SAP Help Portal

Regards

Sören

gayathri_sunil1
Explorer
0 Likes

 

 

gayathri_sunil1
Explorer
0 Likes

 

@Ramjee_korada 

We are using on premise and have a requirement to list details of approvers and then to enable forwarding to different approver. I have less knowledge in RAP, but referring to your blogs I have created one report listing the approver details. Also was able to bring a forward action with behavioral definition with unmanaged. As the root entity was built on I_workflowtask, I have not mentioned any persistant table or draft table, so its unmanaged without draft . We created Odata v2 service  . 

There are few challenges we face , 

1. The forward action appears in object page only, we would need that on the list page .2. From object page , on action I have used abstract entity to get a popup to accept the new approver id and then on forward it works fine in backend. but the object page is not getting refreshed with the new approver id . On going back to list page, we could see the new approver. 

Can you please help to understand what went wrong  here.

Ramjee_korada
Active Contributor
0 Likes

Hi @gayathri_sunil1 ,

1. Have you annotated for action using #lineitem also to show in the List report page?

2. Have you defined the result as $self?

 

Best wishes,

Ramjee Korada

gayathri_sunil1
Explorer
0 Likes

@Ramjee_korada Hi Ramjee,

Thank you for the response .

I have added the action in #lineitem and I have used reference to abstract entity instead of $self.

I have not used any CRUD actions, only this forward is used and there is no association / child page. 

action (features : instance) forward parameter ZI_APPROVER_FWD result [1] zi_approver_fwd;

 

Also I have added side effect in annotation.xml in BAS, not sure if I am doing it correctly. 

gayathri_sunil1_0-1707117527469.png

This is how the object page appears , the requirement is to update the approver id field, from the abstract entity popup field forwardto .

Both have the same value help assigned. 

gayathri_sunil1_1-1707118222663.png

 

 

Zafer
Participant
0 Likes

Thanks, Andre. We solved it in the Fiori part, but it will significantly help in the future.

Best Regards,

Zafer

Andre_Fischer
Product and Topic Expert
Product and Topic Expert
0 Likes

It is now possible.

As of release 2302 we added this functionality to the RAP framework. I published a simple example in my following blog post.

How to use side effects in RAP | SAP Blogs

Kind regards,

Andre