Extends: | Ember.Object |
---|---|
Uses: | Ember.Evented , |
Defined in: | addon/-private/system/many-array.js:12 |
Module: | ember-data |
Defined in addon/-private/system/many-array.js:214
Reloads all of the records in the manyArray. If the manyArray holds a relationship that was originally fetched using a links url Ember Data will revisit the original links url to repopulate the relationship.
If the manyArray holds the result of a store.query()
reload will re-run the original query.
Example
var user = store.peekRecord('user', 1) user.login().then(function() { user.get('permissions').then(function(permissions) { return permissions.reload(); }); });
Defined in addon/-private/system/many-array.js:241
Saves all of the records in the ManyArray
.
Example
store.findRecord('inbox', 1).then(function(inbox) { inbox.get('messages').then(function(messages) { messages.forEach(function(message) { message.set('isRead', true); }); messages.save() }); });
© 2017 Yehuda Katz, Tom Dale and Ember.js contributors
Licensed under the MIT License.
https://emberjs.com/api/ember-data/2.14/classes/DS.ManyArray/methods