2020-03-27 01:42 AM
What is the intended way to transfer data between views? Global variables in FrontendApplication or something else?
For example I have views that can be entered from multiple locations, and the view should go back to the specific view that it originated from.
I also need to transfer strings from views to others, and more.
How is this supposed to be done?
Thanks!
Solved! Go to Solution.
2020-03-31 07:25 AM
Hi @Tuoman,
Since only one view can be active at a time, use the presenter of the view to save data in the model and load that data when the presenter for the NEW view activates.
save data: view1 tell presenter1 to save data to model (presenter has model pointer)
load data: presenter2 activate() loads from model and sets data in view2
/Martin
2020-03-31 07:25 AM
Hi @Tuoman,
Since only one view can be active at a time, use the presenter of the view to save data in the model and load that data when the presenter for the NEW view activates.
save data: view1 tell presenter1 to save data to model (presenter has model pointer)
load data: presenter2 activate() loads from model and sets data in view2
/Martin