mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-12 16:22:55 -07:00
Fixed #718
This commit is contained in:
parent
d8e7693d8d
commit
5bd8e5f313
2 changed files with 20 additions and 3 deletions
|
@ -950,7 +950,24 @@ namespace PlexRequests.UI.Modules
|
||||||
{
|
{
|
||||||
var s = await ScheduledJobSettings.GetSettingsAsync();
|
var s = await ScheduledJobSettings.GetSettingsAsync();
|
||||||
var allJobs = await JobRecorder.GetJobsAsync();
|
var allJobs = await JobRecorder.GetJobsAsync();
|
||||||
var jobsDict = allJobs.ToDictionary(k => k.Name, v => v.LastRun);
|
|
||||||
|
var dict = new Dictionary<string, DateTime>();
|
||||||
|
|
||||||
|
|
||||||
|
foreach (var j in allJobs)
|
||||||
|
{
|
||||||
|
DateTime dt;
|
||||||
|
if (dict.TryGetValue(j.Name, out dt))
|
||||||
|
{
|
||||||
|
// We already have the key... Somehow, we should have never got this record.
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dict.Add(j.Name,j.LastRun);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
var model = new ScheduledJobsViewModel
|
var model = new ScheduledJobsViewModel
|
||||||
{
|
{
|
||||||
CouchPotatoCacher = s.CouchPotatoCacher,
|
CouchPotatoCacher = s.CouchPotatoCacher,
|
||||||
|
@ -959,7 +976,7 @@ namespace PlexRequests.UI.Modules
|
||||||
SonarrCacher = s.SonarrCacher,
|
SonarrCacher = s.SonarrCacher,
|
||||||
StoreBackup = s.StoreBackup,
|
StoreBackup = s.StoreBackup,
|
||||||
StoreCleanup = s.StoreCleanup,
|
StoreCleanup = s.StoreCleanup,
|
||||||
JobRecorder = jobsDict,
|
JobRecorder = dict,
|
||||||
RecentlyAddedCron = s.RecentlyAddedCron
|
RecentlyAddedCron = s.RecentlyAddedCron
|
||||||
};
|
};
|
||||||
return View["SchedulerSettings", model];
|
return View["SchedulerSettings", model];
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="PlexUserChecker" class="control-label">Plex User Checker (hours)</label>
|
<label for="PlexUserChecker" class="control-label">Plex User Checker (hours)</label>
|
||||||
<input type="text" class="form-control form-control-custom " id="PlexUserChecker" name="PlexContentCacher" value="@Model.PlexUserChecker">
|
<input type="text" class="form-control form-control-custom " id="PlexUserChecker" name="PlexUserChecker" value="@Model.PlexUserChecker">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue