Remove From On Deck (#2131)

* Allow admins to customize the amount of progress time or last item added time for on deck calculation

* Implemented the ability to remove series from on deck. They will be removed until the user reads a new chapter.

Quite a few db lookup reduction calls for reading based stuff, like continue point, bookmarks, etc.
This commit is contained in:
Joe Milazzo 2023-07-15 09:27:21 -05:00 committed by GitHub
parent 90a6c89486
commit 348bc062ee
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
24 changed files with 2597 additions and 87 deletions

View file

@ -37,6 +37,10 @@ public class AppUser : IdentityUser<int>, IHasConcurrencyToken
/// </summary>
public ICollection<Device> Devices { get; set; } = null!;
/// <summary>
/// A list of Series the user doesn't want on deck
/// </summary>
//public ICollection<Series> OnDeckRemovals { get; set; } = null!;
/// <summary>
/// An API Key to interact with external services, like OPDS
/// </summary>
public string? ApiKey { get; set; }

View file

@ -0,0 +1,11 @@
namespace API.Entities;
public class AppUserOnDeckRemoval
{
public int Id { get; set; }
public int SeriesId { get; set; }
public Series Series { get; set; }
public int AppUserId { get; set; }
public AppUser AppUser { get; set; }
}

View file

@ -133,5 +133,15 @@ public enum ServerSettingKey
/// </summary>
[Description("Cache")]
CacheSize = 24,
/// <summary>
/// How many Days since today in the past for reading progress, should content be considered for On Deck, before it gets removed automatically
/// </summary>
[Description("OnDeckProgressDays")]
OnDeckProgressDays = 25,
/// <summary>
/// How many Days since today in the past for chapter updates, should content be considered for On Deck, before it gets removed automatically
/// </summary>
[Description("OnDeckUpdateDays")]
OnDeckUpdateDays = 26,
}