From 9d29776e8e39780005746122d313e903238de94e Mon Sep 17 00:00:00 2001 From: geogolem Date: Thu, 23 Feb 2017 06:33:54 -0500 Subject: [PATCH] some minor cleanup + changed filter on wanted/missing (#845) --- src/NzbDrone.Api/Wanted/MovieMissingModule.cs | 6 +++--- src/UI/Handlebars/Helpers/Series.js | 3 --- src/UI/Movies/Details/InfoViewTemplate.hbs | 4 ---- src/UI/Wanted/Missing/MissingLayout.js | 18 +++++++++--------- 4 files changed, 12 insertions(+), 19 deletions(-) diff --git a/src/NzbDrone.Api/Wanted/MovieMissingModule.cs b/src/NzbDrone.Api/Wanted/MovieMissingModule.cs index 1d90cbcb7..10ac7a7a8 100644 --- a/src/NzbDrone.Api/Wanted/MovieMissingModule.cs +++ b/src/NzbDrone.Api/Wanted/MovieMissingModule.cs @@ -41,11 +41,11 @@ namespace NzbDrone.Api.Wanted else if (pagingResource.FilterKey == "moviestatus" && pagingResource.FilterValue == "available") { //TODO: might need to handle PreDB here - pagingSpec.FilterExpression = v => - (v.MinimumAvailability == MovieStatusType.Released && v.Status >= MovieStatusType.Released) || + pagingSpec.FilterExpression = v => v.Monitored == true && + ((v.MinimumAvailability == MovieStatusType.Released && v.Status >= MovieStatusType.Released) || (v.MinimumAvailability == MovieStatusType.InCinemas && v.Status >= MovieStatusType.InCinemas) || (v.MinimumAvailability == MovieStatusType.Announced && v.Status >= MovieStatusType.Announced) || - (v.MinimumAvailability == MovieStatusType.PreDB && v.Status >= MovieStatusType.Released); + (v.MinimumAvailability == MovieStatusType.PreDB && v.Status >= MovieStatusType.Released)); } else if (pagingResource.FilterKey == "moviestatus" && pagingResource.FilterValue == "announced") { diff --git a/src/UI/Handlebars/Helpers/Series.js b/src/UI/Handlebars/Helpers/Series.js index 6aceb21a7..0df810e74 100644 --- a/src/UI/Handlebars/Helpers/Series.js +++ b/src/UI/Handlebars/Helpers/Series.js @@ -54,9 +54,6 @@ Handlebars.registerHelper('tmdbUrl', function() { Handlebars.registerHelper('youTubeTrailerUrl', function() { return 'https://www.youtube.com/watch?v=' + this.youTubeTrailerId; }); -Handlebars.registerHelper('allFlicksUrl', function() { - return this.allFlicksUrl; -}); Handlebars.registerHelper('homepage', function() { return this.website; diff --git a/src/UI/Movies/Details/InfoViewTemplate.hbs b/src/UI/Movies/Details/InfoViewTemplate.hbs index 3c04b4439..e8051dc34 100644 --- a/src/UI/Movies/Details/InfoViewTemplate.hbs +++ b/src/UI/Movies/Details/InfoViewTemplate.hbs @@ -39,10 +39,6 @@ {{#if youTubeTrailerId}} Trailer {{/if}} - - {{#if allFlicksUrl}} - AllFlicks - {{/if}} diff --git a/src/UI/Wanted/Missing/MissingLayout.js b/src/UI/Wanted/Missing/MissingLayout.js index 6df8dee37..88195419f 100644 --- a/src/UI/Wanted/Missing/MissingLayout.js +++ b/src/UI/Wanted/Missing/MissingLayout.js @@ -132,10 +132,17 @@ module.exports = Marionette.Layout.extend({ }; var filterOptions = { type : 'radio', - storeState : true, + storeState : false, menuKey : 'wanted.filterMode', - defaultAction : 'monitored', + defaultAction : 'available', items : [ + { + key : 'available', + title : '', + tooltip : 'Available & Monitored', + icon : 'icon-sonarr-available', + callback : this._setFilter + }, { key : 'monitored', title : '', @@ -170,13 +177,6 @@ module.exports = Marionette.Layout.extend({ tooltip : 'Released Only', icon : 'icon-sonarr-movie-released', callback : this._setFilter - }, - { - key : 'available', - title : '', - tooltip : 'Available Only', - icon : 'icon-sonarr-available', - callback : this._setFilter } ] };