|
|
@ -281,18 +281,18 @@ module.exports = Marionette.Layout.extend({
|
|
|
|
var series = MoviesCollection.models.length;
|
|
|
|
var series = MoviesCollection.models.length;
|
|
|
|
var episodes = 0;
|
|
|
|
var episodes = 0;
|
|
|
|
var episodeFiles = 0;
|
|
|
|
var episodeFiles = 0;
|
|
|
|
var ended = 0;
|
|
|
|
var announced = 0;
|
|
|
|
var continuing = 0;
|
|
|
|
var released = 0;
|
|
|
|
var monitored = 0;
|
|
|
|
var monitored = 0;
|
|
|
|
|
|
|
|
|
|
|
|
_.each(MoviesCollection.models, function(model) {
|
|
|
|
_.each(MoviesCollection.models, function(model) {
|
|
|
|
episodes += model.get('episodeCount');
|
|
|
|
episodes += model.get('episodeCount');
|
|
|
|
episodeFiles += model.get('episodeFileCount');
|
|
|
|
episodeFiles += model.get('episodeFileCount');
|
|
|
|
|
|
|
|
|
|
|
|
if (model.get('status').toLowerCase() === 'ended') {
|
|
|
|
if (model.get('status').toLowerCase() === 'released') {
|
|
|
|
ended++;
|
|
|
|
released++;
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
continuing++;
|
|
|
|
announced++;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (model.get('monitored')) {
|
|
|
|
if (model.get('monitored')) {
|
|
|
@ -302,8 +302,8 @@ module.exports = Marionette.Layout.extend({
|
|
|
|
|
|
|
|
|
|
|
|
footerModel.set({
|
|
|
|
footerModel.set({
|
|
|
|
series : series,
|
|
|
|
series : series,
|
|
|
|
ended : ended,
|
|
|
|
released : released,
|
|
|
|
continuing : continuing,
|
|
|
|
announced : announced,
|
|
|
|
monitored : monitored,
|
|
|
|
monitored : monitored,
|
|
|
|
unmonitored : series - monitored,
|
|
|
|
unmonitored : series - monitored,
|
|
|
|
episodes : episodes,
|
|
|
|
episodes : episodes,
|
|
|
|