Added season pass for toggling monitored status of seasons

Linked from missing
This commit is contained in:
Mark McDowall 2013-08-05 02:09:41 -07:00
commit 6ca17942f0
12 changed files with 316 additions and 22 deletions

View file

@ -1,24 +1,25 @@
'use strict';
define(
[
'Series/SeasonModel',
'backbone.pageable'
], function (SeasonModel, PageAbleCollection) {
return PageAbleCollection.extend({
'backbone',
'Series/SeasonModel'
], function (Backbone, SeasonModel) {
return Backbone.Collection.extend({
url : window.ApiRoot + '/season',
model: SeasonModel,
mode: 'client',
state: {
sortKey : 'seasonNumber',
order : 1,
pageSize: 1000000
comparator: function (season) {
return -season.get('seasonNumber');
},
queryParams: {
sortKey: null,
order : null
bySeries: function (series) {
var filtered = this.filter(function (season) {
return season.get('seriesId') === series;
});
var SeasonCollection = require('Series/SeasonCollection');
return new SeasonCollection(filtered);
}
});
});

View file

@ -246,4 +246,30 @@
.series-legend {
padding-top: 5px;
}
.seasonpass-series {
.card;
margin : 20px 0px;
.title {
font-weight: 300;
font-size: 24px;
line-height: 30px;
margin-left: 5px;
}
.season-select {
margin-bottom: 0px;
}
.expander {
.clickable;
line-height: 30px;
margin-left: 8px;
}
.season-grid {
margin-top: 10px;
}
}