Корректировка моделей Host, Template

This commit is contained in:
Mikhail Kuznetsov
2023-09-19 10:19:05 +10:00
parent 7a88a7c198
commit 4cde851a33
3 changed files with 17 additions and 14 deletions

View File

@@ -21,10 +21,11 @@ namespace PARR.AIHIT.MappingProfiles
.ForMember(d => d.Responsible, o => o.MapFrom(s => s.Attributes!["ОТВЕТСТВЕННЫЙ_ЗАК"]!.Value.Trim())); .ForMember(d => d.Responsible, o => o.MapFrom(s => s.Attributes!["ОТВЕТСТВЕННЫЙ_ЗАК"]!.Value.Trim()));
CreateMap<RawDataEK, Host>() CreateMap<RawDataEK, Host>()
.ForMember(d => d.HostName, o => o.MapFrom(s => s.EKFindCode))//TODO Определить имя хоста по .ForMember(d => d.Ek, o => o.MapFrom(s => s.EKFindCode))//TODO Определить имя хоста по
.ForMember(d => d.IP, o => o.MapFrom(s => s.IP)) .ForMember(d => d.IP, o => o.MapFrom(s => s.IP))
.ForMember(d => d.Status, o => o.MapFrom(s => s.Status)) .ForMember(d => d.Status, o => o.MapFrom(s => s.Status))
.ForMember(d => d.WorkGroup, o => o.MapFrom(s => s.WorkGroup)); .ForMember(d => d.WorkGroup, o => o.MapFrom(s => s.WorkGroup))
.ForMember(d => d.ResponseArea, o => o.MapFrom(s => s.ResponseArea));
//CreateMap<PARR.DAL.Models.Host, PARR.DAL.Models.Host>() //CreateMap<PARR.DAL.Models.Host, PARR.DAL.Models.Host>()
// .ForMember(d => d.HostName, o => o.MapFrom(s => s.HostName)) // .ForMember(d => d.HostName, o => o.MapFrom(s => s.HostName))
// .ForMember(d => d.IP, o => o.MapFrom(s => s.IP)) // .ForMember(d => d.IP, o => o.MapFrom(s => s.IP))

View File

@@ -11,14 +11,13 @@ namespace PARR.DAL.Models
public Guid Id { get; set; } public Guid Id { get; set; }
public DateTimeOffset DateCreated { get; set; } public DateTimeOffset DateCreated { get; set; }
public DateTimeOffset? DateModified { get; set; } public DateTimeOffset? DateModified { get; set; }
public string? HostName { get; set; } public string? Ek { get; set; }
public required string IP { get; set; } public required string IP { get; set; }
//public string? RegionalEK { get; set; } //public string? RegionalEK { get; set; }
//public string? LinkEK { get; set; } //public string? LinkEK { get; set; }
public string? Status { get; set; } public string? Status { get; set; }
public string? WorkGroup { get; set; } public string? WorkGroup { get; set; }
//public string? Responsible { get; set; } public string? ResponseArea { get; set; }
public ICollection<ApplicationInHost> ApplicationsInHosts { get; set; } = new HashSet<ApplicationInHost>(); public ICollection<ApplicationInHost> ApplicationsInHosts { get; set; } = new HashSet<ApplicationInHost>();

View File

@@ -20,31 +20,34 @@ namespace PARR.DAL.Models
public bool IsActive { get; set; } public bool IsActive { get; set; }
//??? Рабочая группа //Рабочая группа из Host
public required string WorkGroup { get; set; } public required string WorkGroup { get; set; }
// settings из Work
public required string ShortDescription { get; set; } public required string ShortDescription { get; set; }
//settings ? регламентная работа //settings регламентная работа. не меняется
public required string Category { get; set; } public required string Category { get; set; }
// ДВС, ?? // из Host
public required string ResponseArea { get; set; } public required string ResponseArea { get; set; }
//works ?? //works
public required string Duration { get; set; } public required string EsppDuration { get; set; }
//works
public required string EsppStartAt { get; set; }
//public required string EK { get; set; } //public required string EK { get; set; }
// settings // settings. Возможно руководитель повыше
public required string Initiator { get; set; } public required string Initiator { get; set; }
// settings из Work
public required string FullDescription { get; set; } public required string FullDescription { get; set; }
// settings // settings
public required string ClosingCode { get; set; } public required string ClosingCode { get; set; }
// settings // settings из Work
public required string Solution { get; set; } public required string Solution { get; set; }
//public required string Process { get; set; } //public required string Process { get; set; }