/// <summary> /// 发送站内信 /// </summary> public void SendInnerMail(InnerMailInfo_Send innerMail, string createBy) { if (innerMail == null || string.IsNullOrEmpty(innerMail.Receivers)) { return; } var arrReceive = innerMail.Receivers.Split('|'); if (arrReceive.Length <= 0) { return; } using (var biz = new GameBiz.Business.GameBizBusinessManagement()) { using (var manager = new InnerMailManager()) { biz.BeginTran(); foreach (var item in arrReceive) { if (string.IsNullOrEmpty(item)) { continue; } var mail = new SiteMessageInnerMailListNew { MailId = Guid.NewGuid().ToString(), SendTime = DateTime.Now, SenderId = createBy, HandleType = InnerMailHandleType.UnRead, MsgContent = innerMail.Content, ReceiverId = item, Title = innerMail.Title, }; manager.AddSiteMessageInnerMailListNew(mail); } biz.CommitTran(); } } }
public void UpdateSiteMessageInnerMailListNew(SiteMessageInnerMailListNew entity) { this.Add <SiteMessageInnerMailListNew>(entity); }