I'm not sure if this can currently be done, i couldnt see anything in the code, but let me know if i've missed something.
Use case - I have a page where i have embedded a node edit form directly under the node content. A user is able to ajax submit the node edit form to update the content. On the form submission i want the updated node to be returned to on 'complete' state so i can replace the old content with the updated content.
This would be a great addition, currently, i am having to fire off an additional AJAX GET request on 'complete' to get the updated data, and then replace it on the page. If it were to come back as part of the args object (or possibly in a different object) as a response from the form POST to the plugin_api then this would be only 1 ajax call instead of 2, and a resulting increase in performance.
Comments
Comment #1
kvvnn CreditAttribution: kvvnn commentedI concur.
I'm using the same method as you are for node edits, but node adds are much more difficult.
I'm trying to use jquery's .ajaxSuccess function and dig out some sort of response, but not having much luck. Will post here if I nail it.
Comment #2
kvvnn CreditAttribution: kvvnn commentedHere is what I am doing to get my node-view path once I submit an add-node form:
1) Ajax and Disable Redirect are enabled for my node type
2) I load the node-add form via jQuery's .load() :
3) I attach some code to the Submit button of this form