Widget update problem with microflow datasource in gridview (TreeView and GridView)
Hi all, I've recently encountered a strange behaviour in custom widgets using a datasource microflow. The short version: When an action triggers a refresh, the widget displays the value that should have been shown for the last refresh. I have a NP Wrapper entity and a NP View entity. I create the Wrapper in a microflow and show it on a page. On the page is a grid (using the TreeView and GridView widget) which shows a single View object which is created by a datasource microflow. https://modelshare.mendix.com/models/82d9ae38-a3c0-465e-a97e-e7699a5396b6/ds-wrapper-view Now I have two buttons (Enable/Disable) on the page that change the Wrapper/DisplaySwitch and refresh all View objects. View/Display is a calculated attribute showing the value of Wrapper/Displayswitch. https://modelshare.mendix.com/models/96ad2075-2762-4f89-a0a0-1c519272f451/ac-t-wrapper-enable When clicking the Enable/Disable Button, the widget is going to show an outdated value, i.e. the value from the previous refresh. Somehow the mx.data.get call seems to fetch an old value in the widget. Does anyone have any ideas on this problem or experienced something similar.
What version of the modeler are you working on as there were some refresh issues and version 7.3 and 7.4 which we encountered as well. They are fixed in 7.5 and 7.5.1
Which version of the Tree and Gridview widget do you use? We encountered an issue that seems a bit similar. Now the widget is not officially supported (and the codebase is a hell to maintain), yet we pushed a new version of the widget (4.5.0) about two weeks ago. See release: https://github.com/mendix/TreeViewAndGridView/releases/tag/v4.5.0
This will get the data asynchronously, which should not be a problem.