cancel
Showing results for 
Search instead for 
Did you mean: 

Any event triggered when deletion happens

uskalviskis
Participant
0 Kudos

Hi guys,

I wonder is there any way how to handle following scenario:

We have custom BO which has association to Activity BO.

User deletes Activity's instance and here I want that my custom BO's instance would be deleted together with this activity, as we have 1:1 relationship between Activity BO and mine custom BO.

As I know, than none of events on activity could be triggered when row from Activity's OWL is removed, right? As possible work around I see MDR usage on my custom BO, but it won't be real time check if my custom BO instance still has association to activity. So another thought what I had, but I couldn't find the way how to get it working, is there any chance to trigger on my custom BOs OWL any actions (mass enabled action which checks if my instances has set association to activity)?

Thanks,

Uldis

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Uldis,

we had exactly the same requirement and there is indeed no delete event.

However, you might also consider creating an internal communication (see SAP Cloud Application Studio Library for details) that creates instances of your custom object per activity and configure it such that activity deletions also delete the destination object of the internal communication (i.e. your custom object).

Best regards.

Ludger

uskalviskis
Participant
0 Kudos

Hi Ludger,

but still I confused about how it will be handled. If there is no deletion event, how I will trigger this removal in my custom BO?

Thanks,

Uldis

Former Member
0 Kudos

In case of an internal communication used, you would not receive a delete event.

The backend would delete your custom object.

Explained simple, internal communication creates, updates and deletes instances of objects (the destination object) based on modifications of a source object asynchronously in the background (you can define additional conditions when to create, update or delete).

So you might use it to create and delete instances of your custom object.

The approach using internal communication is just a suggestion and might not be what you need.

uskalviskis
Participant
0 Kudos

But worth to try! Thanks for hint.

Answers (0)