The Grails documentation for the remoteFunction update attribute states:
update (optional) – Either a Map containing the elements to update for ‘success’ or ‘failure’ states, or a string with the element id to update, in which case failure events would be ignored
I’m a little confused why the indicate a Map and not a List here, is this wrong? I imagine I want my remote action to return a Map, where the keys match the name of the list elements specified in the update attribute??
Thanks
Use
update, if you want to replace a part of the current page, which is identified by the (html)-id in theupdatetag. E.g.:However this is not useful, if the AJAX call fails. That is why you can define which element is to be updated in the failure case:
I am not sure, whether this clarifies your question regarding
update, but maybe it helps 😉