Refactored Volume to have Name and Number (int) so that we can properly sort and still handle possible split volumes.

Refactored ScanLibrary into Library controller and updated it so it adds the new library to all admins.
This commit is contained in:
Joseph Milazzo 2021-01-02 12:21:36 -06:00
parent d632e53f18
commit 9168e12483
13 changed files with 622 additions and 49 deletions

View file

@ -1,16 +1,16 @@
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using API.Entities.Interfaces;
using Microsoft.AspNetCore.Identity;
namespace API.Entities
{
public class AppUser : IdentityUser<int>
public class AppUser : IdentityUser<int>, IHasConcurrencyToken
{
public DateTime Created { get; set; } = DateTime.Now;
public DateTime LastActive { get; set; }
public bool IsAdmin { get; set; }
public ICollection<Library> Libraries { get; set; }
[ConcurrencyCheck]

View file

@ -7,7 +7,8 @@ namespace API.Entities
public class Volume : IEntityDate
{
public int Id { get; set; }
public string Number { get; set; }
public string Name { get; set; }
public int Number { get; set; }
public ICollection<MangaFile> Files { get; set; }
public DateTime Created { get; set; }
public DateTime LastModified { get; set; }