Search code examples
cuba-platform

Refreshing the screen after entity update from Rest API is not showing latest data?


Steps to reproduce -

  1. I have updated the entity data using CUBA REST API.
  2. I clicked refresh button in browser, it did refresh but the data in entity viewer is still showing old one. So I closed the entity viewer and opened again - it reflects the new changes.

I think the refresh is not working for entity viewer if it is updated by REST API. Is it a bug or any work around is there?


Solution

  • A quick workaround is to add a refresh button to the UI. Please check below screenshots to add the refresh button. I think that serves the purpose.

    1. When Creating the Generic UI, click on Show advanced properties.

    Advanced

    1. Show Advanced Properties > Table Actions > refresh.

    enter image description here

    1. Now you can see Refresh button in the web UI, so the user can click refresh button rather than loading the page.

    final result