27 lines
728 B
C#
27 lines
728 B
C#
using AutoMapper;
|
|
using IRaCIS.Application.Contracts;
|
|
using IRaCIS.Core.Application.Contracts;
|
|
using IRaCIS.Core.Application.ViewModel;
|
|
using IRaCIS.Core.Domain.Models;
|
|
|
|
namespace IRaCIS.Core.Application.Service
|
|
{
|
|
public class AllocationConfig : Profile
|
|
{
|
|
public AllocationConfig()
|
|
{
|
|
|
|
CreateMap<TaskAllocationRule, TaskAllocationRuleView>();
|
|
|
|
CreateMap<VisitTask, VisitTaskView>()
|
|
.ForMember(o => o.SiteId, t => t.MapFrom(u => u.Subject.SiteId))
|
|
.ForMember(o => o.TrialSiteCode, t => t.MapFrom(u => u.Subject.TrialSite.TrialSiteCode))
|
|
.ForMember(o => o.SubjectCode, t => t.MapFrom(u => u.Subject.Code));
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
|
}
|