Prevent to navigate away from unsaved change

0
i am new to mendix. I am wondering, How do we prevent a user to navigate away if there has unsaved change?   There are few issues to be solved in order to make this happen however, i am not sure how to solve this in mendix. 1.  Need to be able to detect if current form data is dirty or not(compare with previously/init. object) 2. when the path is change, if the form is dirty, show the confirmation popup. 3. when user navigate to another web site, if the form is dirty, show the confirmation popup.
asked
2 answers
0

There is no out of the box solution for this. The best approach to have data integrity is to not do commits in between. Only let the user save data that is complete. If the user navigates away, the entered data is "just" lost.

answered
0

thanks for response. we are already doing the save action, however, pm has additional request as i described before. this is can be done with other framework(for example: angular) because they provide a way to trace the change of the path.  as i am new to mendix(never done any of mendix before), i am wondering if mendix provide similar way to handle that.

 

thx

answered