Change an objects attribute with a nanoflow

0
Hi,    I am trying to change the attribute of an object with a nanoflow in the web application, but when I do it it gives me the following error:     An error occurred while executing an action of CuadernoExplotacion.Explotacion_Overview.actionButton8: Cannot modify attribute EstaActivo of a read-only object. Error: An error occurred while executing an action of CuadernoExplotacion.Explotacion_Overview.actionButton8: Cannot modify attribute EstaActivo of a read-only object.     at http://localhost:8080/mxclientsystem/mxui/mxui.js?637830250025952994:68:119197     at we (http://localhost:8080/mxclientsystem/mxui/mxui.js?637830250025952994:24:6501)     at i (http://localhost:8080/mxclientsystem/mxui/mxui.js?637830250025952994:24:6402)     at x (http://localhost:8080/mxclientsystem/mxui/mxui.js?637830250025952994:66:5472)   In the domain model the attribute has read and write permissions.   Thanks.      
asked
1 answers
0

Hi Mikel,

See: https://docs.mendix.com/refguide/nanoflows/

 

The documentation states: 

The following actions interact with the database:

  • Create
  • Commit
  • Retrieve
  • Rollback

Therefore, the best practice is to use nanoflows in online applications when they do not contain the above actions.

 

Furthermore:

 

6 Security

Nanoflows are executed in the context of the current user. Any operation for which the user is unauthorized will fail. For instance, when objects are retrieved in a nanoflow, only the ones for which the current user has read access will be returned. Committing an object only succeeds when the current user has write access for all changes.

 

Best regards

Jan

 

answered