Hi Guys,
I am trying to get an idea of what would be the best approach to tackle below use case.
Use case
- I have a portlet (say Portlet X) where in two portlet pages are imported into it (Say Page A and Page B)
- I have all the editable options on Page A, and it’s relevent read only options on Page B
- When user edits a field on Page A, the action present in Page A’s backing bean will be invoked to make the relevent update in database.
- Now I would like to see the updated data for this field in Page B. To do this, I would need to invoke an action in Page B (to get the updated data from database) and refresh Page B.
Can you please advise how can step 4 be achieved?
I have an approach but I don’t feel it is optimum as it involves invoking async command controls twice.
At step 3 - after Page A’s backing bean action is invoked, in the action command listener - invoke a javascript function present in Page B. That javascript function from Page B invokes server side action and refreshes controls on Page B.
Kind regards,