/// <summary> /// 批量添加失败记录 /// </summary> /// <param name="emailInfo"></param> /// <param name="bccAccountID"></param> /// <param name="emailAccount"></param> private void InsertFailureByList(EmailInfo emailInfo, List <EmailSendBccAccount> emailbccAccountList, EmailAccount emailAccount) { foreach (EmailSendBccAccount emailSendBccAccount in emailbccAccountList) { EmailSendFailure model = new EmailSendFailure(); model.EmailAccountID = emailAccount.EmailAccountID; model.EmailID = emailInfo.EmailID; model.EmailSendFailureID = Guid.NewGuid().ToString(); model.EmailSendFailureSendTime = DateTime.Now; model.EmailBccAccountID = emailSendBccAccount.EmailBccAccountID;; EmailSendFailureBLL.Current.Add(model); } }
/// <summary> /// 单个添加失败记录 /// </summary> /// <param name="emailInfo"></param> /// <param name="bccAccountID"></param> /// <param name="emailAccount"></param> private void InsertFailure(EmailInfo emailInfo, string bccAccountID, EmailAccount emailAccount) { //foreach (EmailSendBccAccount emailSendBccAccount in emailbccAccountList) //{ EmailSendFailure model = new EmailSendFailure(); model.EmailAccountID = emailAccount.EmailAccountID; model.EmailID = emailInfo.EmailID; model.EmailSendFailureID = Guid.NewGuid().ToString(); model.EmailSendFailureSendTime = DateTime.Now; model.EmailBccAccountID = bccAccountID; EmailSendFailureBLL.Current.Add(model); //} }