template controller
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using AutoMapper;
|
||||
using PARR.API.Contracts.V1.Responses;
|
||||
using PARR.DAL.Models;
|
||||
using PARR.DAL.Models.V1;
|
||||
|
||||
namespace PARR.API.MappingProfiles
|
||||
@@ -23,9 +24,27 @@ namespace PARR.API.MappingProfiles
|
||||
.ForMember(d => d.Script, o => o.MapFrom(s => s.ScriptName));
|
||||
// === Job ===
|
||||
|
||||
|
||||
|
||||
CreateMap<V1_JobMode, JobModeResponse>();
|
||||
|
||||
CreateMap<Template, TemplateResponse>()
|
||||
.ForMember(d => d.ParrTemplateId, o => o.MapFrom(s => s.Id))
|
||||
.ForMember(d => d.Assignment, o => o.MapFrom(s => s.WorkGroup))
|
||||
.ForMember(d => d.Title, o => o.MapFrom(s => s.ShortDescription))
|
||||
.ForMember(d => d.Branch, o => o.MapFrom(s => s.ResponseArea))
|
||||
.ForMember(d => d.SlaInterval, o => o.MapFrom(s => s.Duration))
|
||||
.ForMember(d => d.ConfigurationItem, o => o.MapFrom(s => s.EK))
|
||||
.ForMember(d => d.ContactName, o => o.MapFrom(s => s.Initiator))
|
||||
.ForMember(d => d.Description, o => o.MapFrom(s => s.FullDescription))
|
||||
.ForMember(d => d.ResolutionCode, o => o.MapFrom(s => s.ClosingCode))
|
||||
.ForMember(d => d.Resolution, o => o.MapFrom(s => s.Solution))
|
||||
.ForMember(d => d.RzdMTNKprocess, o => o.MapFrom(s => s.Process))
|
||||
.ForMember(d => d.RzdMTNKsubprocess, o => o.MapFrom(s => s.SubProcess))
|
||||
.ForMember(d => d.RzdMTNKtnk, o => o.MapFrom(s => s.TNK))
|
||||
.ForMember(d => d.RzdMTNKjob, o => o.MapFrom(s => s.Work))
|
||||
.ForMember(d => d.Assignee, o => o.MapFrom(s => s.Worker));
|
||||
|
||||
CreateMap<StatusTemplate, StatusTemplateResponse>();
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user