From cd85964edd22db1a88097e85c8b18b00504a1c80 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Sun, 29 May 2011 15:44:05 -0700 Subject: [PATCH] Fixed add new profile. Removed DownloadPropers bool. --- NzbDrone.Web/Controllers/SettingsController.cs | 8 +------- NzbDrone.Web/Models/QualityModel.cs | 4 ---- NzbDrone.Web/Views/Settings/Quality.cshtml | 13 +------------ 3 files changed, 2 insertions(+), 23 deletions(-) diff --git a/NzbDrone.Web/Controllers/SettingsController.cs b/NzbDrone.Web/Controllers/SettingsController.cs index f70e006ba..b88d81708 100644 --- a/NzbDrone.Web/Controllers/SettingsController.cs +++ b/NzbDrone.Web/Controllers/SettingsController.cs @@ -134,17 +134,13 @@ namespace NzbDrone.Web.Controllers ViewData["Qualities"] = qualityTypes; var profiles = _qualityProvider.GetAllProfiles().ToList(); - var defaultQualityQualityProfileId = Convert.ToInt32(_configProvider.DefaultQualityProfile); - var downloadPropers = _configProvider.DownloadPropers; - var qualityProfileSelectList = new SelectList(profiles, "QualityProfileId", "Name"); var model = new QualityModel { Profiles = profiles, DefaultQualityProfileId = defaultQualityQualityProfileId, - DownloadPropers = downloadPropers, QualityProfileSelectList = qualityProfileSelectList }; @@ -208,7 +204,7 @@ namespace NzbDrone.Web.Controllers qualityTypes.Add(qual); } - ViewData["Qualities"] = new SelectList(qualityTypes); + ViewData["Qualities"] = qualityTypes; var qualityProfile = new QualityProfile { @@ -219,7 +215,6 @@ namespace NzbDrone.Web.Controllers var id = _qualityProvider.Add(qualityProfile); qualityProfile.QualityProfileId = id; - qualityProfile.Allowed = null; ViewData["ProfileId"] = id; @@ -460,7 +455,6 @@ namespace NzbDrone.Web.Controllers if (ModelState.IsValid) { _configProvider.DefaultQualityProfile = data.DefaultQualityProfileId; - _configProvider.DownloadPropers = data.DownloadPropers; //Saves only the Default Quality, skips User Profiles since none exist if (data.Profiles == null) diff --git a/NzbDrone.Web/Models/QualityModel.cs b/NzbDrone.Web/Models/QualityModel.cs index 43794feec..0b6263b46 100644 --- a/NzbDrone.Web/Models/QualityModel.cs +++ b/NzbDrone.Web/Models/QualityModel.cs @@ -13,10 +13,6 @@ namespace NzbDrone.Web.Models [Description("The default quality to use when adding series to NzbDrone")] public int DefaultQualityProfileId { get; set; } - [DisplayName("Download Propers")] - [Description("Should NzbDrone download proper releases (to replace non-proper files)?")] - public bool DownloadPropers { get; set; } - public SelectList QualityProfileSelectList { get; set; } } } \ No newline at end of file diff --git a/NzbDrone.Web/Views/Settings/Quality.cshtml b/NzbDrone.Web/Views/Settings/Quality.cshtml index f25800fa9..6443077fd 100644 --- a/NzbDrone.Web/Views/Settings/Quality.cshtml +++ b/NzbDrone.Web/Views/Settings/Quality.cshtml @@ -48,17 +48,6 @@ Quality
-
-
-
@Html.LabelFor(m => m.DownloadPropers)
-
@Html.CheckBoxFor(m => m.DownloadPropers)
-
-
-
@Html.ValidationMessageFor(m => m.DownloadPropers)
-
@Html.DescriptionFor(m => m.DownloadPropers)
-
-
-
@Html.LabelFor(m => m.DefaultQualityProfileId)
@@ -103,7 +92,7 @@ url: this.href, cache: false, success: function (html) { - $("#profiles").prepend(html); + $("#profiles").append(html); } });