Quantcast
Channel: SAP CRM: Webclient UI - Framework
Viewing all articles
Browse latest Browse all 188

One breadcrumb issue caused by missing implementation of method GET_MAIN_ENTITY

$
0
0

Issue symptom

We have met with a strange issue in breadcrumb navigation:

 

We first click hyperlink of instance 201400024731

clipboard1.png


And we go to its detail page, then click Inbox Workcenter to return to the search result view. Then we click the second instance 201400024710 to reach its detail page, and click   Inbox Workcenter again. Now we delete the 201400024731 via delete icon in toolbar, however we still can find the entry for it in breadcrumb drop down list. The worse thing is, after we choose the dropdown list for 201400024731, we actually reach the detail page of 201400024710 which is completely wrong.

clipboard2.png

Root cause

We found the issue is caused by missing implementation of GET_MAIN_ENTITY.

clipboard3.png

After implementing it the issue is gone. The reason why that method is necessary is because:

 

 

The class CL_BSP_WD_HIST_MANAGER_BASE has two event handlers:

 

 

ON_ENTITY_DELETED is responsible for the removal of history record of deleted bol instance from history storage.

 

clipboard4.png


it is registered on method ON_HISTORY_TRIGGER,

clipboard5.png

which is the event handler for event:

clipboard6.png

When we are navigating from search result to detail page, GET_MAIN_ENTITY will be called:

clipboard7.png

The returned main entity is registered for event handler ON_ENTITY_DELETED.

clipboard8.png

When this very instance is deleted, the event DELETED is raised and caught by event handler ON_ENTITY_DELETED( see callstack below)

clipboard9.png

The history entry for the deleted bol entity( o:871) is removed in line 32:

clipboard10.png

clipboard11.png

Row one is removed, and in back button drop down list now the entity for deleted bol entity is removed as expected.


Viewing all articles
Browse latest Browse all 188

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>