feat(application): register AutoMapper mappings for new commands and add SendAndAppend to IImapEmailService
This commit is contained in:
@@ -20,6 +20,16 @@ public class EmailMappingProfile : Profile
|
||||
.ForMember(dest => dest.Sender, opt => opt.Ignore())
|
||||
.ForMember(dest => dest.Attachments, opt => opt.MapFrom(src => src.Attachments));
|
||||
|
||||
// PublishEmailViaImapCommand -> EmailContext
|
||||
CreateMap<PublishEmailViaImapCommand, EmailContext>()
|
||||
.ForMember(dest => dest.Sender, opt => opt.Ignore())
|
||||
.ForMember(dest => dest.Attachments, opt => opt.MapFrom(src => src.Attachments));
|
||||
|
||||
// PublishEmailViaOAuth2Command -> EmailContext
|
||||
CreateMap<PublishEmailViaOAuth2Command, EmailContext>()
|
||||
.ForMember(dest => dest.Sender, opt => opt.Ignore())
|
||||
.ForMember(dest => dest.Attachments, opt => opt.MapFrom(src => src.Attachments));
|
||||
|
||||
// EmailAccountDto -> EmailAccount
|
||||
CreateMap<EmailAccount, EmailAccountDto>();
|
||||
CreateMap<EmailAccountModificationDto, EmailAccount>();
|
||||
|
||||
Reference in New Issue
Block a user