mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 02:26:55 -07:00
commit
6eab8c09cc
26 changed files with 737 additions and 168 deletions
|
@ -314,6 +314,7 @@ namespace Ombi.UI.Helpers
|
|||
{
|
||||
url = $"/{content}{url}";
|
||||
}
|
||||
|
||||
var returnString = context.Request.Path == url ?
|
||||
$"<li class=\"active\"><a href=\"{url}\"><i class=\"fa fa-{fontIcon}\"></i> {title}</a></li>"
|
||||
: $"<li><a href=\"{url}\"><i class=\"fa fa-{fontIcon}\"></i> {title}</a></li>";
|
||||
|
@ -328,7 +329,14 @@ namespace Ombi.UI.Helpers
|
|||
{
|
||||
url = $"/{content}{url}";
|
||||
}
|
||||
|
||||
if (url.Contains("issues"))
|
||||
{
|
||||
var custom = GetCustomizationSettings();
|
||||
if (!custom.EnableIssues)
|
||||
{
|
||||
return helper.Raw(string.Empty);
|
||||
}
|
||||
}
|
||||
var returnString = context.Request.Path == url
|
||||
? $"<li class=\"active\"><a href=\"{url}\"><i class=\"fa fa-{fontIcon}\"></i> {title} {extraHtml}</a></li>"
|
||||
: $"<li><a href=\"{url}\"><i class=\"fa fa-{fontIcon}\"></i> {title} {extraHtml}</a></li>";
|
||||
|
|
|
@ -35,6 +35,7 @@ using Ombi.Core;
|
|||
using Ombi.Core.SettingModels;
|
||||
using Ombi.Services.Interfaces;
|
||||
using Ombi.Services.Jobs;
|
||||
using Ombi.Services.Jobs.RecentlyAddedNewsletter;
|
||||
using Ombi.UI.Helpers;
|
||||
using Quartz;
|
||||
using Quartz.Impl;
|
||||
|
@ -70,7 +71,7 @@ namespace Ombi.UI.Jobs
|
|||
JobBuilder.Create<StoreBackup>().WithIdentity("StoreBackup", "Database").Build(),
|
||||
JobBuilder.Create<StoreCleanup>().WithIdentity("StoreCleanup", "Database").Build(),
|
||||
JobBuilder.Create<UserRequestLimitResetter>().WithIdentity("UserRequestLimiter", "Request").Build(),
|
||||
JobBuilder.Create<RecentlyAdded>().WithIdentity("RecentlyAddedModel", "Email").Build(),
|
||||
JobBuilder.Create<RecentlyAddedNewsletter>().WithIdentity("RecentlyAddedModel", "Email").Build(),
|
||||
JobBuilder.Create<FaultQueueHandler>().WithIdentity("FaultQueueHandler", "Fault").Build(),
|
||||
JobBuilder.Create<RadarrCacher>().WithIdentity("RadarrCacher", "Cache").Build(),
|
||||
|
||||
|
@ -304,8 +305,8 @@ namespace Ombi.UI.Jobs
|
|||
var embyEpisode =
|
||||
TriggerBuilder.Create()
|
||||
.WithIdentity("EmbyEpisodeCacher", "Emby")
|
||||
.StartNow()
|
||||
//.StartAt(DateBuilder.FutureDate(10, IntervalUnit.Minute))
|
||||
//.StartNow()
|
||||
.StartAt(DateBuilder.FutureDate(10, IntervalUnit.Minute))
|
||||
.WithSimpleSchedule(x => x.WithIntervalInHours(s.EmbyEpisodeCacher).RepeatForever())
|
||||
.Build();
|
||||
|
||||
|
|
|
@ -42,6 +42,7 @@ using Nancy.Validation;
|
|||
using NLog;
|
||||
using Ombi.Api;
|
||||
using Ombi.Api.Interfaces;
|
||||
using Ombi.Api.Models.Movie;
|
||||
using Ombi.Core;
|
||||
using Ombi.Core.Models;
|
||||
using Ombi.Core.SettingModels;
|
||||
|
@ -823,6 +824,10 @@ namespace Ombi.UI.Modules.Admin
|
|||
{
|
||||
return Response.AsJson(valid.SendJsonError());
|
||||
}
|
||||
if (!settings.Enabled)
|
||||
{
|
||||
return Response.AsJson(new CouchPotatoProfiles{list = new List<ProfileList>()});
|
||||
}
|
||||
var profiles = CpApi.GetProfiles(settings.FullUri, settings.ApiKey);
|
||||
|
||||
// set the cache
|
||||
|
@ -1141,6 +1146,8 @@ namespace Ombi.UI.Modules.Admin
|
|||
var emby = await EmbySettings.GetSettingsAsync();
|
||||
var plex = await PlexService.GetSettingsAsync();
|
||||
|
||||
|
||||
|
||||
var dict = new Dictionary<string, DateTime>();
|
||||
|
||||
|
||||
|
@ -1153,7 +1160,24 @@ namespace Ombi.UI.Modules.Admin
|
|||
}
|
||||
else
|
||||
{
|
||||
dict.Add(j.Name,j.LastRun);
|
||||
if (j.Name.Contains("Plex"))
|
||||
{
|
||||
if (plex.Enable)
|
||||
{
|
||||
dict.Add(j.Name, j.LastRun);
|
||||
}
|
||||
}
|
||||
else if (j.Name.Contains("Emby"))
|
||||
{
|
||||
if (emby.Enable)
|
||||
{
|
||||
dict.Add(j.Name, j.LastRun);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
dict.Add(j.Name, j.LastRun);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -142,7 +142,7 @@ namespace Ombi.UI.Modules.Admin
|
|||
}
|
||||
if (key.Equals(JobNames.RecentlyAddedEmail, StringComparison.CurrentCultureIgnoreCase))
|
||||
{
|
||||
RecentlyAdded.Start();
|
||||
RecentlyAdded.StartNewsLetter();
|
||||
}
|
||||
if (key.Equals(JobNames.FaultQueueHandler, StringComparison.CurrentCultureIgnoreCase))
|
||||
{
|
||||
|
|
|
@ -32,6 +32,7 @@ using Ombi.Helpers.Analytics;
|
|||
using Ombi.Services.Interfaces;
|
||||
using Ombi.Services.Jobs;
|
||||
using Ombi.Services.Jobs.Interfaces;
|
||||
using Ombi.Services.Jobs.RecentlyAddedNewsletter;
|
||||
using Ombi.UI.Jobs;
|
||||
using Quartz;
|
||||
using Quartz.Impl;
|
||||
|
@ -48,8 +49,8 @@ namespace Ombi.UI.NinjectModules
|
|||
Bind<IWatcherCacher>().To<WatcherCacher>();
|
||||
Bind<ISonarrCacher>().To<SonarrCacher>();
|
||||
Bind<ISickRageCacher>().To<SickRageCacher>();
|
||||
Bind<IRecentlyAdded>().To<RecentlyAdded>();
|
||||
Bind<IMassEmail>().To<RecentlyAdded>();
|
||||
Bind<IRecentlyAdded>().To<RecentlyAddedNewsletter>();
|
||||
Bind<IMassEmail>().To<RecentlyAddedNewsletter>();
|
||||
Bind<IRadarrCacher>().To<RadarrCacher>();
|
||||
Bind<IPlexContentCacher>().To<PlexContentCacher>();
|
||||
Bind<IJobFactory>().To<CustomJobFactory>();
|
||||
|
@ -65,6 +66,7 @@ namespace Ombi.UI.NinjectModules
|
|||
Bind<IEmbyContentCacher>().To<EmbyContentCacher>();
|
||||
Bind<IEmbyEpisodeCacher>().To<EmbyEpisodeCacher>();
|
||||
Bind<IEmbyUserChecker>().To<EmbyUserChecker>();
|
||||
Bind<IEmbyAddedNewsletter>().To<EmbyAddedNewsletter>();
|
||||
|
||||
|
||||
Bind<IAnalytics>().To<Analytics>();
|
||||
|
|
|
@ -104,7 +104,8 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
@Html.Checkbox(Model.Settings.NewSearch, "NewSearch", "Use New Search")
|
||||
@*@Html.Checkbox(Model.Settings.NewSearch, "NewSearch", "Use New Search")*@
|
||||
@Html.Checkbox(Model.Settings.EnableIssues, "EnableIssues", "Enable Issues")
|
||||
<div class="form-group">
|
||||
<div>
|
||||
<button type="submit" id="save" class="btn btn-primary-outline">Submit</button>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue