Backlog searching will be disabled by default. Option is available in Settings/Misc

This commit is contained in:
Mark McDowall 2012-01-14 16:01:51 -08:00
parent 3e9593ba3b
commit 11b6720cd1
8 changed files with 92 additions and 2 deletions

View file

@ -221,6 +221,14 @@ namespace NzbDrone.Web.Controllers
return View(model);
}
public ActionResult Misc()
{
var model = new MiscSettingsModel();
model.EnableBacklogSearching = _configProvider.EnableBacklogSearching;
return View(model);
}
public PartialViewResult AddProfile()
{
var qualityProfile = new QualityProfile
@ -582,6 +590,19 @@ namespace NzbDrone.Web.Controllers
return GetInvalidModelResult();
}
[HttpPost]
public JsonResult SaveMisc(MiscSettingsModel data)
{
if (ModelState.IsValid)
{
_configProvider.EnableBacklogSearching = data.EnableBacklogSearching;
return GetSuccessResult();
}
return GetInvalidModelResult();
}
private JsonResult GetSuccessResult()
{
return Json(new NotificationResult() { Title = "Settings Saved" });