42 lines
1.5 KiB
C#
42 lines
1.5 KiB
C#
using AutoMapper;
|
|
using IRaCIS.Application.ViewModels;
|
|
using IRaCIS.Application.ViewModels.Pay;
|
|
using IRaCIS.Core.Domain.Models;
|
|
|
|
namespace IRaCIS.Core.Application.Contracts.AutoMapper
|
|
{
|
|
public class LogicChangeMappingProfile : Profile
|
|
{
|
|
public LogicChangeMappingProfile()
|
|
{
|
|
|
|
|
|
//医生列表、项目显示列表模型转换
|
|
CreateMap<DoctorDTO, SelectionReviewerDTO>();
|
|
|
|
|
|
CreateMap<Message, SysMessageDTO>()
|
|
.ForMember(o => o.MessageTime, t => t.MapFrom(u => u.MessageTime.ToString()));
|
|
|
|
|
|
CreateMap<CRO, InstitutionDTO>()
|
|
.ForMember(o => o.InstitutionName, t => t.MapFrom(u => u.CROName));
|
|
CreateMap<Sponsor, InstitutionDTO>()
|
|
.ForMember(o => o.InstitutionName, t => t.MapFrom(u => u.SponsorName));
|
|
CreateMap<Hospital, InstitutionDTO>()
|
|
.ForMember(o => o.InstitutionName, t => t.MapFrom(u => u.HospitalName));
|
|
CreateMap<Site, InstitutionDTO>()
|
|
.ForMember(o => o.InstitutionName, t => t.MapFrom(u => u.SiteName));
|
|
|
|
CreateMap<PaymentAdjustmentCommand, PaymentAdjustment>()
|
|
.ForMember(t=>t.YearMonthDate,
|
|
u=>u.MapFrom(t=>t.YearMonth))
|
|
.ForMember(t=>t.YearMonth,
|
|
u=>u.MapFrom(t=>t.YearMonth.ToString("yyyy-MM")));
|
|
|
|
CreateMap<LesionInformation, VisitLesion>();
|
|
|
|
CreateMap<EnrollCommand, Enroll>();
|
|
}
|
|
}
|
|
} |