Tranga/API/Schema/MangaAltTitle.cs
Glax 7d4a6be569 MangaConnectors do not have to return an Object with 6 Parameters.
Job-Start Logic readable and optimized
More robust Database design
2025-05-09 06:28:44 +02:00

18 lines
509 B
C#

using System.ComponentModel.DataAnnotations;
using Microsoft.EntityFrameworkCore;
namespace API.Schema;
[PrimaryKey("AltTitleId")]
public class MangaAltTitle(string language, string title)
{
[StringLength(64)]
[Required]
public string AltTitleId { get; init; } = TokenGen.CreateToken("AltTitle", language, title);
[StringLength(8)]
[Required]
public string Language { get; init; } = language;
[StringLength(256)]
[Required]
public string Title { get; set; } = title;
}