Forums Register Login
updating table in calling page after closing a dialog
I have a JSF page that has a table full of data... In the table, there is a create new record button. By clicking on the create new record button a dialog is opened. Once you add the record and close the dialog box, the new record is added to the database, but the update is not shown in the table... Any idea on how to have the update to be shown in the table after the dialog is closed?
By dialog box do you mean a javascript dialog box? Did you try refreshing the page if it shows the new added record? You might have to find a way to do a page refresh programmatically after you close the dialog.
Just use a Ajax-request after you have done the update so the user wouldn't know that you're getting new values from the server.

I use AJAX4JSF for that.
IIRC, I had a similar problem, my solution: after the dialog is submitted (so the data is persisted) I send a "refresh" to the main page through javascript.
Wink, wink, nudge, nudge, say no more ... https://richsoil.com/cards

All times above are in ranch (not your local) time.
The current ranch time is
Oct 16, 2017 16:41:15.