AutoConfigure for SAB is setup, it works for systems with NzbDrone and SABnzbd on the same server only.

This commit is contained in:
Mark McDowall 2011-05-10 23:46:26 -07:00
parent 70bfc49b4e
commit 49a059bdea
7 changed files with 97 additions and 59 deletions

View file

@ -296,26 +296,18 @@ namespace NzbDrone.Web.Controllers
return new JsonResult { Data = "ok" };
}
public JsonResult AutoConfigureSab(string username, string password)
public JsonResult AutoConfigureSab()
{
SabnzbdInfoModel info;
try
{
//info = _autoConfigureProvider.AutoConfigureSab(username, password);
info = new SabnzbdInfoModel
{
ApiKey = "123456",
Port = 2222
};
var info = _autoConfigureProvider.AutoConfigureSab();
return Json(info, JsonRequestBehavior.AllowGet);
}
catch (Exception)
{
return new JsonResult { Data = "failed" };
}
return Json(info);
}
[HttpPost]