Support for persistent state for collections

This commit is contained in:
Mark McDowall
2013-12-09 18:40:20 -08:00
parent cec479923f
commit 874e98b408
2 changed files with 60 additions and 3 deletions
+7 -3
View File
@@ -2,11 +2,13 @@
define(
[
'Series/EpisodeModel',
'backbone.pageable'
], function (EpisodeModel, PagableCollection) {
return PagableCollection.extend({
'backbone.pageable',
'Mixins/AsPersistedStateCollection'
], function (EpisodeModel, PagableCollection, AsPersistedStateCollection) {
var collection = PagableCollection.extend({
url : window.NzbDrone.ApiRoot + '/missing',
model: EpisodeModel,
tableName: 'missing',
state: {
pageSize: 15,
@@ -38,4 +40,6 @@ define(
return resp;
}
});
return AsPersistedStateCollection.call(collection);
});