Refresh entity editor screen after a global event is received

Hi Everyone,

I have a scenario where i would like refresh/reload the screen after a global event is received.
My entity has fields which has composition relation and i would like to refresh all the data fields and tables.
Could you please help me how can i achieve a refresh view of the current entity.

Thanks in advance for your help.

In global event handler method,i reload data using this approach:

public void onProjectStatDataUpdatedEvent(ProjectStatDataUpdatedEvent event) {        

In my entity editor screen , how do i retrieve instance loader?
Below is my instance declaration in XML:

<instance id=“submissionDc”

You can get your container with the following code:

InstanceContainer ic = getScreenData().getContainer("submissionDc");


I am able to get Instance Container. I tried setting the reloaded item from datamanager using setitem API but i dont see view getting refresh.

Could you share a code snippet or demo project to demonstrate how you’re trying to do it?

I’ve checked the case and it seems that everything works.

Please find my submission entity editor xml and java (4.1 KB)
I would like to refresh the screen in the eventlistener of UINotificationevent(onUiNotificationEvent).

You can retrieve the loader if you give it id in the XML and then inject into controller.

As per the documentation(Data Loaders - CUBA Platform. Developer’s Manual) instance loader requires an entity identifier which is specified programmatically by the StandardEditor base class.
For an entity editor screen how can i set the query and the identifier in the XML?

Query can be specified as usual:

    <instance ...>

To set entity id you should use the following method:

StandardEditor#setEntityToEdit(T item)