Add Entity & Migration for ChapterRatings
This commit is contained in:
parent
5c06e14a73
commit
a152f16cf6
7 changed files with 3721 additions and 0 deletions
36
API/Entities/AppUserChapterRating.cs
Normal file
36
API/Entities/AppUserChapterRating.cs
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
using API.Services.Plus;
|
||||
|
||||
namespace API.Entities;
|
||||
|
||||
#nullable enable
|
||||
|
||||
public enum ChapterRatingProvider
|
||||
{
|
||||
Kavita = 0,
|
||||
AniList = 1,
|
||||
Mal = 2,
|
||||
CbrUser = 3,
|
||||
CbrCritic = 4,
|
||||
}
|
||||
|
||||
public class AppUserChapterRating
|
||||
{
|
||||
|
||||
public int Id { get; set; }
|
||||
public float Rating { get; set; }
|
||||
public bool HasBeenRated { get; set; }
|
||||
public string? Review { get; set; }
|
||||
public ChapterRatingProvider Provider {get; set; }
|
||||
|
||||
public int SeriesId { get; set; }
|
||||
public Series Series { get; set; } = null!;
|
||||
|
||||
public int ChapterId { get; set; }
|
||||
public Chapter Chapter { get; set; } = null!;
|
||||
|
||||
public int VolumeId { get; set; }
|
||||
public Volume Volume { get; set; } = null!;
|
||||
|
||||
public int AppUserId { get; set; }
|
||||
public AppUser AppUser { get; set; } = null!;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue