API mostly working, starting to work on webapp
This commit is contained in:
17
Entities/Author.cs
Normal file
17
Entities/Author.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Swashbuckle.AspNetCore.Annotations;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
//using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace ComiServ.Entities
|
||||
{
|
||||
[Index(nameof(Name), IsUnique = true)]
|
||||
public class Author
|
||||
{
|
||||
public int Id { get; set; }
|
||||
[Required]
|
||||
public string Name { get; set; } = null!;
|
||||
public ICollection<ComicAuthor> ComicAuthors = null!;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user