mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 02:26:55 -07:00
Also fixed the issue for the Emby Newsletter where episodes were not getting added :(
This commit is contained in:
parent
d53864fef1
commit
e22dac963a
2 changed files with 8 additions and 3 deletions
|
@ -116,7 +116,7 @@ namespace Ombi.Services.Jobs.RecentlyAddedNewsletter
|
|||
var firstRun = !recentlyAdded.Any();
|
||||
|
||||
var filteredMovies = movie.Where(m => recentlyAdded.All(x => x.ProviderId != m.ProviderId)).ToList();
|
||||
var filteredEp = episodes.Where(m => recentlyAdded.All(x => x.ProviderId != m.ProviderId)).ToList();
|
||||
var filteredEp = episodes.Where(m => recentlyAdded.All(x => x.ProviderId != m.EmbyId)).ToList();
|
||||
var filteredSeries = series.Where(m => recentlyAdded.All(x => x.ProviderId != m.ProviderId)).ToList();
|
||||
|
||||
var info = new List<EmbyRecentlyAddedModel>();
|
||||
|
@ -144,6 +144,11 @@ namespace Ombi.Services.Jobs.RecentlyAddedNewsletter
|
|||
|
||||
// Check if there are any epiosdes, then get the series info.
|
||||
// Otherwise then just add the series to the newsletter
|
||||
if (test && !filteredEp.Any() && episodes.Any())
|
||||
{
|
||||
// if this is a test make sure we show something
|
||||
filteredEp = episodes.Take(5).ToList();
|
||||
}
|
||||
if (filteredEp.Any())
|
||||
{
|
||||
var recentlyAddedModel = new List<EmbyRecentlyAddedModel>();
|
||||
|
@ -247,7 +252,7 @@ namespace Ombi.Services.Jobs.RecentlyAddedNewsletter
|
|||
{
|
||||
RecentlyAddedLog.Insert(new RecentlyAddedLog
|
||||
{
|
||||
ProviderId = a.ProviderId,
|
||||
ProviderId = a.EmbyId,
|
||||
AddedAt = DateTime.UtcNow
|
||||
});
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
<div class="form-group">
|
||||
<div>
|
||||
|
||||
<button id="recentlyAddedBtn" class="btn btn-primary-outline">Send test email to Admin @Html.ToolTip("Note: If there is nothing new when testing this, we will just grab some random titles")
|
||||
<button id="recentlyAddedBtn" class="btn btn-primary-outline">Send test email to Admin @Html.ToolTip("Note: If there is nothing new when testing this, we will just grab some random titles. If there are new items, then we will show those new items. Testing will not mark the content as 'Previously Sent'")
|
||||
<div id="testEmailSpinner"></div></button>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue