|
|
|
|
using Mapster;
|
|
|
|
|
using Myshipping.Application.Entity;
|
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
public class EmailParserServerMapper : IRegister
|
|
|
|
|
{
|
|
|
|
|
public void Register(TypeAdapterConfig config)
|
|
|
|
|
{
|
|
|
|
|
config.ForType<EmaiReceiveRecordInfo, EmaiReceiveRecordDto>()
|
|
|
|
|
.Map(dest => dest.GID, src => src.GID)
|
|
|
|
|
.Map(dest => dest.MailAccount, src => src.MAIL_ACCOUNT)
|
|
|
|
|
.Map(dest => dest.MailSubject, src => src.MAIL_SUBJECT)
|
|
|
|
|
.Map(dest => dest.Sender, src => src.SENDER)
|
|
|
|
|
.Map(dest => dest.RecTime, src => src.REC_TIME)
|
|
|
|
|
.Map(dest => dest.IsCheck, src => src.IS_CHECK)
|
|
|
|
|
.Map(dest => dest.IsParse , src => src.IS_PARSE)
|
|
|
|
|
.Map(dest => dest.IsProcess, src => src.IS_PROCESS)
|
|
|
|
|
.Map(dest => dest.ParserCode, src => src.PARSER_CODE)
|
|
|
|
|
.Map(dest => dest.ParserName, src => src.PARSER_NAME)
|
|
|
|
|
.Map(dest => dest.MailBody, src => src.MAIL_BODY)
|
|
|
|
|
.Map(dest => dest.MailAttachments, src => src.MAIL_ATTACHMENTS)
|
|
|
|
|
.Map(dest => dest.MailDate, src => src.MAIL_DATE)
|
|
|
|
|
.Map(dest => dest.MailFilepath, src => src.MAIL_FILEPATH)
|
|
|
|
|
.Map(dest => dest.MessageUid, src => src.MESSAGE_UID)
|
|
|
|
|
.Map(dest => dest.ProcCode, src => src.PROC_CODE)
|
|
|
|
|
.Map(dest => dest.ProcName, src => src.PROC_NAME)
|
|
|
|
|
.Map(dest => dest.StepNote, src => src.STEP_NOTE)
|
|
|
|
|
.Map(dest => dest.ExecDetailTotal, src => src.EXEC_DETAIL_TOTAL)
|
|
|
|
|
.Map(dest => dest.ExecDetailSucc, src => src.EXEC_DETAIL_SUCC)
|
|
|
|
|
.Map(dest => dest.ExecDetailFail, src => src.EXEC_DETAIL_FAIL)
|
|
|
|
|
.Map(dest => dest.LstRespNote, src => src.LST_RESP_NOTE);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
config.ForType<EmaiReceiveRecordInfo, EmaiReceiveRecordPageDto>()
|
|
|
|
|
.Map(dest => dest.GID, src => src.GID)
|
|
|
|
|
.Map(dest => dest.MailAccount, src => src.MAIL_ACCOUNT)
|
|
|
|
|
.Map(dest => dest.MailSubject, src => src.MAIL_SUBJECT)
|
|
|
|
|
.Map(dest => dest.Sender, src => src.SENDER)
|
|
|
|
|
.Map(dest => dest.RecTime, src => src.REC_TIME)
|
|
|
|
|
.Map(dest => dest.IsCheck, src => src.IS_CHECK)
|
|
|
|
|
.Map(dest => dest.IsParse, src => src.IS_PARSE)
|
|
|
|
|
.Map(dest => dest.IsProcess, src => src.IS_PROCESS)
|
|
|
|
|
.Map(dest => dest.ParserCode, src => src.PARSER_CODE)
|
|
|
|
|
.Map(dest => dest.ParserName, src => src.PARSER_NAME)
|
|
|
|
|
.Map(dest => dest.MailDate, src => src.MAIL_DATE)
|
|
|
|
|
.Map(dest => dest.ProcCode, src => src.PROC_CODE)
|
|
|
|
|
.Map(dest => dest.ProcName, src => src.PROC_NAME)
|
|
|
|
|
.Map(dest => dest.StepNote, src => src.STEP_NOTE)
|
|
|
|
|
.Map(dest => dest.ExecDetailTotal, src => src.EXEC_DETAIL_TOTAL)
|
|
|
|
|
.Map(dest => dest.ExecDetailSucc, src => src.EXEC_DETAIL_SUCC)
|
|
|
|
|
.Map(dest => dest.ExecDetailFail, src => src.EXEC_DETAIL_FAIL)
|
|
|
|
|
.Map(dest => dest.LstRespNote, src => src.LST_RESP_NOTE);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
config.ForType<EmailUserAccountDto, EmailUserAccountInfo>()
|
|
|
|
|
.Map(dest => dest.GID, src => src.GID)
|
|
|
|
|
.Map(dest => dest.EMAIL_ACCOUNT, src => src.EmailAccount)
|
|
|
|
|
.Map(dest => dest.PASSWORD, src => src.Password)
|
|
|
|
|
.Map(dest => dest.RECEIVE_SERVER, src => src.ReceiveServer)
|
|
|
|
|
.Map(dest => dest.USE_IMAP, src => src.UseIMAP)
|
|
|
|
|
.Map(dest => dest.RECEIVE_PORT, src => src.ReceivePort)
|
|
|
|
|
.Map(dest => dest.RECEIVE_SSL, src => src.ReceiveSSL)
|
|
|
|
|
.Map(dest => dest.SMTP_SERVER, src => src.SmtpServer)
|
|
|
|
|
.Map(dest => dest.SMTP_PORT, src => src.SmtpPort)
|
|
|
|
|
.Map(dest => dest.SMTP_SSL, src => src.SmtpSSL);
|
|
|
|
|
|
|
|
|
|
config.ForType<EmailUserAccountInfo,EmailUserAccountDto> ()
|
|
|
|
|
.Map(dest => dest.GID, src => src.GID)
|
|
|
|
|
.Map(dest => dest.EmailAccount, src => src.EMAIL_ACCOUNT)
|
|
|
|
|
.Map(dest => dest.Password, src => src.PASSWORD)
|
|
|
|
|
.Map(dest => dest.ReceiveServer, src => src.RECEIVE_SERVER)
|
|
|
|
|
.Map(dest => dest.UseIMAP, src => src.USE_IMAP)
|
|
|
|
|
.Map(dest => dest.ReceivePort, src => src.RECEIVE_PORT)
|
|
|
|
|
.Map(dest => dest.ReceiveSSL, src => src.RECEIVE_SSL)
|
|
|
|
|
.Map(dest => dest.SmtpServer, src => src.SMTP_SERVER)
|
|
|
|
|
.Map(dest => dest.SmtpPort, src => src.SMTP_PORT)
|
|
|
|
|
.Map(dest => dest.SmtpSSL, src => src.SMTP_SSL);
|
|
|
|
|
|
|
|
|
|
config.ForType<EmailUserAccountInfo,EmailUserAccountPageDto > ()
|
|
|
|
|
.Map(dest => dest.GID, src => src.GID)
|
|
|
|
|
.Map(dest => dest.EmailAccount, src => src.EMAIL_ACCOUNT)
|
|
|
|
|
.Map(dest => dest.Password, src => src.PASSWORD)
|
|
|
|
|
.Map(dest => dest.ReceiveServer, src => src.RECEIVE_SERVER)
|
|
|
|
|
.Map(dest => dest.UseIMAP, src => src.USE_IMAP)
|
|
|
|
|
.Map(dest => dest.ReceivePort, src => src.RECEIVE_PORT)
|
|
|
|
|
.Map(dest => dest.ReceiveSSL, src => src.RECEIVE_SSL)
|
|
|
|
|
.Map(dest => dest.SmtpServer, src => src.SMTP_SERVER)
|
|
|
|
|
.Map(dest => dest.SmtpPort, src => src.SMTP_PORT)
|
|
|
|
|
.Map(dest => dest.SmtpSSL, src => src.SMTP_SSL);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|