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() .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() .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() .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 () .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 () .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() .Map(dest => dest.GID, src => src.GID) .Map(dest => dest.ParserCode, src => src.PARSER_CODE) .Map(dest => dest.ParserName, src => src.PARSER_NAME) .Map(dest => dest.InjectId, src => src.INJECT_ID) .Map(dest => dest.SubjectRegexPattern, src => src.SUBJECT_REGEX_PATTERN) .Map(dest => dest.BodyRegexPattern, src => src.BODY_REGEX_PATTERN) .Map(dest => dest.SenderRegexPattern, src => src.SENDER_REGEX_PATTERN) .Map(dest => dest.AttachRegexPattern, src => src.ATTACH_REGEX_PATTERN); config.ForType() .Map(dest => dest.GID, src => src.GID) .Map(dest => dest.ParserCode, src => src.PARSER_CODE) .Map(dest => dest.ParserName, src => src.PARSER_NAME) .Map(dest => dest.InjectId, src => src.INJECT_ID) .Map(dest => dest.SubjectRegexPattern, src => src.SUBJECT_REGEX_PATTERN) .Map(dest => dest.BodyRegexPattern, src => src.BODY_REGEX_PATTERN) .Map(dest => dest.SenderRegexPattern, src => src.SENDER_REGEX_PATTERN) .Map(dest => dest.AttachRegexPattern, src => src.ATTACH_REGEX_PATTERN) .Map(dest => dest.CreatedTime, src => src.CreatedTime) .Map(dest => dest.CreatedUserName, src => src.CreatedUserName) .Map(dest => dest.UpdatedTime, src => src.UpdatedTime) .Map(dest => dest.UpdatedUserName, src => src.UpdatedUserName) .Map(dest => dest.UseEmailAccountNum, src => src.USE_EMAIL_ACCOUNT_NUM); config.ForType () .Map(dest => dest.GID, src => src.GID) .Map(dest => dest.PARSER_CODE, src => src.ParserCode) .Map(dest => dest.PARSER_NAME, src => src.ParserName) .Map(dest => dest.INJECT_ID, src => src.InjectId) .Map(dest => dest.SUBJECT_REGEX_PATTERN, src => src.SubjectRegexPattern) .Map(dest => dest.BODY_REGEX_PATTERN, src => src.BodyRegexPattern) .Map(dest => dest.SENDER_REGEX_PATTERN, src => src.SenderRegexPattern) .Map(dest => dest.ATTACH_REGEX_PATTERN, src => src.AttachRegexPattern); config.ForType() .Map(dest => dest.GID, src => src.GID) .Map(dest => dest.InjectCode, src => src.INJECT_CODE) .Map(dest => dest.InjectName, src => src.INJECT_NAME) .Map(dest => dest.InjectFullName, src => src.INJECT_FULLNAME) .Map(dest => dest.CreatedTime, src => src.CreatedTime) .Map(dest => dest.CreatedUserName, src => src.CreatedUserName) .Map(dest => dest.UpdatedTime, src => src.UpdatedTime) .Map(dest => dest.UpdatedUserName, src => src.UpdatedUserName); config.ForType() .Map(dest => dest.GID, src => src.GID) .Map(dest => dest.INJECT_CODE, src => src.InjectCode) .Map(dest => dest.INJECT_NAME, src => src.InjectName) .Map(dest => dest.INJECT_FULLNAME, src => src.InjectFullName) .Map(dest => dest.CreatedTime, src => src.CreatedTime) .Map(dest => dest.UpdatedTime, src => src.UpdatedTime); } } }