View entity access rules cause errors

0
We have created a view entity for a complex overview page to be shown in a DataGrid 2 that used to take a really long time to load. With the newly created view entity the overview page loads really fast which is great.   The view entity contains some access rules which prevent a certain role to view certain fields of the entity as long as a specific condition isn't met. The datagrid has an on click event to open the detail page of an item of the data grid but when clicking on a row to open said detail page we get the following error:   com.mendix.webui.WebUIException: Exception while executing runtime operationat com.mendix.webui.actions.client.RuntimeOperationAction.$anonfun$apply$3(RuntimeOperationAction.scala:60)Caused by: com.mendix.webui.WebUIException: Attempt to illegally change a value for object with id '137078313658093773' (SecurityVerificationModule.EnterpriseEmployeeVerificationView). Object hash is invalid!at com.mendix.webui.requesthandling.HashUtilImpl$.verifyObjectHash(HashUtilImpl.scala:60)   This only occurs when one of the columns has a read restriction present. Other roles that have full access to read the view do not face this issue. The empty columns are not needed to view the detail page, it's pure visual. The issue occurs when calling a 'Show Page' action from the row click, and also when opening the page through a microflow (in this case, the microflow is never reached).   Any help in resolving this issue, or providing a workaround if it's a Mendix bug would be greatly appreciated.   Note: we are currently running Mendix Studio Pro version 10.24.1 but I was not able to choose that version in the version selector of this ticket.
asked
1 answers
0
  • Pre-joins and simplified structure: The view entity likely consolidates data from multiple tables, avoiding the need for expensive joins or logic at runtime.

  • Query optimization: The database query engine can optimize view execution plans better than dynamic or ad-hoc queries.

  • Reduced logic on frontend/backend: The transformation logic is encapsulated within the view, offloading that complexity from the app code.

  • Indexing and caching: If the view is materialized or if the underlying tables are indexed well, this speeds things up significantly.

answered