DD.WellWorkover.Cloud/AsbCloudDb/Model/Manuals/Manual.cs

32 lines
923 B
C#
Raw Normal View History

using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using Microsoft.EntityFrameworkCore;
namespace AsbCloudDb.Model.Manuals;
[Table("t_manual"), Comment("Инструкции")]
public class Manual : IId
{
[Key]
[Column("id")]
public int Id { get; set; }
[Column("name"), Comment("Название файла")]
public string Name { get; set; } = null!;
[Column("date_download"), Comment("Дата загрузки файла")]
public DateTime DateDownload { get; set; }
[Column("id_category"), Comment("Категория")]
public int? IdCategory { get; set; }
[ForeignKey(nameof(IdCategory))]
public virtual FileCategory? Category { get; set; }
[Column("id_folder"), Comment("Id папки инструкций")]
public int? IdFolder { get; set; }
[ForeignKey(nameof(IdFolder))]
public virtual ManualFolder? Folder { get; set; }
}