feat(api): управление job auto control из api
This commit is contained in:
@@ -320,26 +320,14 @@ namespace PARR.API.MappingProfiles
|
||||
|
||||
#endregion
|
||||
|
||||
#region ApplicationInWork
|
||||
|
||||
//CreateMap<ApplicationsInWork, ApplicationInWorkBaseResponse>()
|
||||
// .Include<ApplicationsInWork, ApplicationInWorkResponse>()
|
||||
// .ForMember(d => d.Application, o => o.MapFrom(s => s.Application));
|
||||
|
||||
//CreateMap<ApplicationsInWork, ApplicationInWorkBaseResponse>();
|
||||
|
||||
//CreateMap<ApplicationsInWork, ApplicationInWorkResponse>()
|
||||
// .ForMember(d => d.Work, o => o.MapFrom(s => s.Work))
|
||||
// //.ForMember(d => d.TemplatesCount, o => o.MapFrom(s => s.Templates.Count()))
|
||||
// .ForMember(d => d.Schedule, o => o.MapFrom<ApplicationInWorkScheduleResolver>())
|
||||
// .ForMember(d => d.WorkGroups, o => o.MapFrom(s => s.WorkGroups.OrderBy(t => t.WorkGroup!.Name).Select(t => t.WorkGroup)))
|
||||
// .ForMember(d => d.AutoControl, o => o.MapFrom(s => s.JobAutoControl));
|
||||
|
||||
#endregion
|
||||
|
||||
#region Job
|
||||
CreateMap<Job, JobBaseResponse>();
|
||||
CreateMap<Job, JobResponse>();
|
||||
|
||||
CreateMap<Job, JobBaseResponse>()
|
||||
.Include<Job, JobResponse>();
|
||||
|
||||
CreateMap<Job, JobResponse>()
|
||||
.ForMember(d => d.AutoControl, o => o.MapFrom(s => s.AutoControl));
|
||||
|
||||
CreateMap<JobUnitFilter, UnitFilterResponse>()
|
||||
.ForMember(d => d.UnitFilterMask, o => o.MapFrom(s => s.UnitFilter))
|
||||
@@ -354,6 +342,8 @@ namespace PARR.API.MappingProfiles
|
||||
CreateMap<JobRelationshipFilter, RelationshipFilterResponse>()
|
||||
.ForMember(d => d.Field, o => o.MapFrom(s => s.UnitField));
|
||||
|
||||
CreateMap<JobAutoControl, JobAutoControlResponse>();
|
||||
|
||||
#endregion
|
||||
|
||||
#region JobGroup
|
||||
|
||||
@@ -13,6 +13,7 @@ namespace PARR.API.MappingProfiles
|
||||
CreateMap<PaginationQuery, PaginationFilter>();
|
||||
|
||||
#region Job
|
||||
|
||||
CreateMap<JobRequest, Job>()
|
||||
.ForMember(d => d.Id, o => o.MapFrom(s => Guid.NewGuid()))
|
||||
.ForMember(d => d.DateCreated, o => o.MapFrom(s => DateTimeOffset.UtcNow))
|
||||
@@ -42,6 +43,7 @@ namespace PARR.API.MappingProfiles
|
||||
.ForMember(d => d.DateCreated, o => o.MapFrom(s => DateTimeOffset.UtcNow));
|
||||
|
||||
CreateMap<RelationshipFilterRequest, JobRelationshipFilter>();
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user