Ajoute les thèmes communs sur les fiches de livres
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
co-authored by
Copilot
parent
e28d5bce32
commit
c2d408afc6
@@ -0,0 +1,33 @@
|
||||
using MaBibli.Shared.Textes;
|
||||
|
||||
namespace MaBibli.Shared.Entites;
|
||||
|
||||
/// <summary>Étiquette thématique commune au catalogue.</summary>
|
||||
public class Theme
|
||||
{
|
||||
public int Id { get; set; }
|
||||
|
||||
public string Nom { get; set; } = string.Empty;
|
||||
|
||||
public string NomNormalise { get; set; } = string.Empty;
|
||||
|
||||
public List<LivreTheme> Livres { get; set; } = [];
|
||||
|
||||
public void RecalculerFormes()
|
||||
{
|
||||
Nom = Nom.Trim();
|
||||
NomNormalise = NormalisationTexte.Normaliser(Nom);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Lien entre un livre et une étiquette thématique.</summary>
|
||||
public class LivreTheme
|
||||
{
|
||||
public int LivreId { get; set; }
|
||||
|
||||
public Livre? Livre { get; set; }
|
||||
|
||||
public int ThemeId { get; set; }
|
||||
|
||||
public Theme? Theme { get; set; }
|
||||
}
|
||||
Reference in New Issue
Block a user