mirror of
https://github.com/Kareadita/Kavita.git
synced 2025-06-22 23:10:34 -04:00
* Stashing code * removed some debug code on series detail page. Now detail is collapsed by default. * Added AgeRating * Fixed a crash when NetVips tries to write a cover file and cover directory is not existing. * When a card is selected for bulk actions, show an outline in addition to select box * Added AgeRating into the metadata parsing. Added a hack where ComicInfo uses Number in ComicInfo rather than Volume. This is to test out the effects on users libraries. * Added AgeRating and ReleaseDate to the metadata implelentation.
49 lines
1.3 KiB
C#
49 lines
1.3 KiB
C#
using System.Collections.Generic;
|
|
using System.ComponentModel.DataAnnotations;
|
|
using API.Entities.Enums;
|
|
using API.Entities.Interfaces;
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
namespace API.Entities.Metadata
|
|
{
|
|
[Index(nameof(Id), nameof(SeriesId), IsUnique = true)]
|
|
public class SeriesMetadata : IHasConcurrencyToken
|
|
{
|
|
public int Id { get; set; }
|
|
|
|
public string Summary { get; set; }
|
|
|
|
|
|
public ICollection<CollectionTag> CollectionTags { get; set; }
|
|
|
|
public ICollection<Genre> Genres { get; set; } = new List<Genre>();
|
|
/// <summary>
|
|
/// All people attached at a Series level.
|
|
/// </summary>
|
|
public ICollection<Person> People { get; set; } = new List<Person>();
|
|
|
|
/// <summary>
|
|
/// Highest Age Rating from all Chapters
|
|
/// </summary>
|
|
public AgeRating AgeRating { get; set; }
|
|
/// <summary>
|
|
/// Earliest Year from all chapters
|
|
/// </summary>
|
|
public int ReleaseYear { get; set; }
|
|
|
|
// Relationship
|
|
public Series Series { get; set; }
|
|
public int SeriesId { get; set; }
|
|
|
|
/// <inheritdoc />
|
|
[ConcurrencyCheck]
|
|
public uint RowVersion { get; private set; }
|
|
|
|
/// <inheritdoc />
|
|
public void OnSavingChanges()
|
|
{
|
|
RowVersion++;
|
|
}
|
|
}
|
|
}
|