Отказ от отдельной легаси-сущности
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace Pf2eModel.Model.Base;
|
||||
|
||||
public class EntityAlias
|
||||
{
|
||||
/// <summary>
|
||||
/// Идентификатор источника.
|
||||
/// </summary>
|
||||
[Key]
|
||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||
[Column(Order = 1)]
|
||||
[Comment("Идентификатор")]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Идентификатор связанной сущности.
|
||||
/// </summary>
|
||||
[Column(Order = 2)]
|
||||
[Comment("Связанная сущность")]
|
||||
public int EntityId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Отображаемое имя источника.
|
||||
/// </summary>
|
||||
[Column(Order = 3)]
|
||||
[MaxLength(Pf2eDbContext.NameLength)]
|
||||
[Comment("Алиас")]
|
||||
public string Name { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// Связанная
|
||||
/// </summary>
|
||||
public Entity Entity { get; set; } = null!;
|
||||
}
|
||||
Reference in New Issue
Block a user