Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save zoghal/2870227 to your computer and use it in GitHub Desktop.
Save zoghal/2870227 to your computer and use it in GitHub Desktop.
ember rest adapter
findAll: function(store, type) {
var root = this.rootForType(type);
this.ajax(root, "GET", {
success: function(json) {
store.loadMany(type, json["objects"]);
store.typeMapFor(type).modelArrays.forEach( function(item) {
item.set('isLoaded', true);
});
}
});
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment