NzbIndex and NzbClub added to the UI.

pull/6/head
Mark McDowall 13 years ago
parent c24cb16127
commit 5ed53008c6

Binary file not shown.

After

Width:  |  Height:  |  Size: 603 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 260 B

@ -83,6 +83,8 @@ namespace NzbDrone.Web.Controllers
NewznabEnabled = _indexerProvider.GetSettings(typeof(Newznab)).Enable,
WomblesEnabled = _indexerProvider.GetSettings(typeof(Wombles)).Enable,
FileSharingTalkEnabled = _indexerProvider.GetSettings(typeof(FileSharingTalk)).Enable,
NzbIndexEnabled = _indexerProvider.GetSettings(typeof(NzbIndex)).Enable,
NzbClubEnabled = _indexerProvider.GetSettings(typeof(NzbClub)).Enable,
NewznabDefinitions = _newznabProvider.All(),
});
@ -376,6 +378,14 @@ namespace NzbDrone.Web.Controllers
fileSharingTalkSettings.Enable = data.FileSharingTalkEnabled;
_indexerProvider.SaveSettings(fileSharingTalkSettings);
var nzbIndexSettings = _indexerProvider.GetSettings(typeof(NzbIndex));
nzbIndexSettings.Enable = data.NzbIndexEnabled;
_indexerProvider.SaveSettings(nzbIndexSettings);
var nzbClubSettings = _indexerProvider.GetSettings(typeof(NzbClub));
nzbClubSettings.Enable = data.NzbClubEnabled;
_indexerProvider.SaveSettings(nzbClubSettings);
_configProvider.NzbsOrgUId = data.NzbsOrgUId;
_configProvider.NzbsOrgHash = data.NzbsOrgHash;

@ -107,6 +107,14 @@ namespace NzbDrone.Web.Models
[Description("Enable downloading episodes from File Sharing Talk")]
public bool FileSharingTalkEnabled { get; set; }
[DisplayName("NzbIndex")]
[Description("Enable downloading episodes from NzbIndex")]
public bool NzbIndexEnabled { get; set; }
[DisplayName("NzbClub")]
[Description("Enable downloading episodes from NzbClub")]
public bool NzbClubEnabled { get; set; }
[Required(ErrorMessage = "Please enter a valid number of days")]
[DataType(DataType.Text)]
[DisplayName("Retention")]

@ -147,12 +147,17 @@
<Content Include="Content\DataTables-1.9.0\media\images\sort_both.png" />
<Content Include="Content\DataTables-1.9.0\media\images\sort_desc.png" />
<Content Include="Content\DataTables-1.9.0\media\images\sort_desc_disabled.png" />
<Content Include="Content\Images\AirsToday.png" />
<Content Include="Content\Images\background.jpg" />
<Content Include="Content\Images\blue.png" />
<Content Include="Content\Images\Gear.png" />
<Content Include="Content\Images\green.png" />
<Content Include="Content\Images\Indexers\FileSharingTalk.png" />
<Content Include="Content\Images\Indexers\Newznab.png" />
<Content Include="Content\Images\Indexers\NzbClub.png" />
<Content Include="Content\Images\Indexers\NzbIndex.png" />
<Content Include="Content\Images\Indexers\Nzbs.org.png" />
<Content Include="Content\Images\Indexers\WomblesIndex.png" />
<Content Include="Content\Images\logo.png" />
<Content Include="Content\Images\pause.png" />
<Content Include="Content\Images\play.png" />

@ -30,6 +30,12 @@
@Html.CheckBox("fileSharingTalkStatus", @Model.FileSharingTalkEnabled, new { @class = "indexerStatusButton" })
<label for="fileSharingTalkStatus">File Sharing Talk</label>
@Html.CheckBox("nzbIndexStatus", @Model.NzbIndexEnabled, new { @class = "indexerStatusButton" })
<label for="nzbIndexStatus">NzbIndex</label>
@Html.CheckBox("nzbClubStatus", @Model.NzbClubEnabled, new { @class = "indexerStatusButton" })
<label for="nzbClubStatus">Nzb Club</label>
</div>
<div id="stylized">
@using (Html.BeginForm("SaveIndexers", "Settings", FormMethod.Post, new { id = "IndexersForm", name = "IndexersForm", @class = "settingsForm" }))
@ -157,6 +163,22 @@
</label>
@Html.TextBoxFor(m => m.FileSharingTalkSecret, new { @class = "inputClass" })
</div>
<h3><a href="#">NzbIndex</a></h3>
<div class="indexerPanel">
<label class="labelClass">
Enable <span class="small">@Html.DescriptionFor(m => m.NzbIndexEnabled)</span>
</label>
@Html.CheckBoxFor(m => m.NzbIndexEnabled, new { @class = "inputClass checkClass enabledCheck" })
</div>
<h3><a href="#">NzbClub</a></h3>
<div class="indexerPanel">
<label class="labelClass">
Enable <span class="small">@Html.DescriptionFor(m => m.NzbClubEnabled)</span>
</label>
@Html.CheckBoxFor(m => m.NzbClubEnabled, new { @class = "inputClass checkClass enabledCheck" })
</div>
</div>
<div class="retentionContainer">
@ -227,6 +249,12 @@
if (id == 'FileSharingTalkEnabled')
$('#fileSharingTalkStatus').prop('checked', checked);
if (id == 'NzbIndexEnabled')
$('#nzbIndexStatus').prop('checked', checked);
if (id == 'NzbClubEnabled')
$('#nzbClubStatus').prop('checked', checked);
$('.indexerStatusButton').button("refresh");
reValidate();
});
@ -256,6 +284,12 @@
if (id == 'fileSharingTalkStatus')
$('#FileSharingTalkEnabled').prop('checked', checked);
if (id == 'nzbIndexStatus')
$('#NzbIndexEnabled').prop('checked', checked);
if (id == 'nzbClubStatus')
$('#NzbClubEnabled').prop('checked', checked);
reValidate();
});

Loading…
Cancel
Save