Skip to content

Instantly share code, notes, and snippets.

@mikeobrien
Created February 22, 2012 15:43
Show Gist options
  • Save mikeobrien/1885609 to your computer and use it in GitHub Desktop.
Save mikeobrien/1885609 to your computer and use it in GitHub Desktop.
public class PostHandler
{
...
public AjaxContinuation Execute(Model request)
{
var updatedModel = Map(_addWidgetService.Add(Map(request)));
// How do I get my updatedModel back to the client?
return AjaxContinuation.Successful();
}
}
// Ah, maybe this is what I'm missing; adding the response data to the continuation:
var response = AjaxContinuation.Successful();
response.Data["data"] = updatedModel;
return response
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment