public static void SendMobileMsg(string CompanyCD, string FlowNo, int BillTypeFlag, int BillTypeCode, int BillID, string BillNo, int State, int OperateType) { try { DataTable dt = XBase.Business.Common.FlowBus.GetMsgRemindList(CompanyCD, FlowNo, BillTypeFlag, BillTypeCode, BillID, State, OperateType); XBase.Business.Personal.MessageBox.MobileMsgMonitor bll = new XBase.Business.Personal.MessageBox.MobileMsgMonitor(); if (dt.Rows.Count > 0) { if (!string.IsNullOrEmpty(dt.Rows[0]["EmployeeID"].ToString()) && !string.IsNullOrEmpty(dt.Rows[0]["Mobile"].ToString())) { if (int.Parse(dt.Rows[0]["MsgCount"].ToString()) > 0) { XBase.Model.Personal.MessageBox.MobileMsgMonitor entity; entity = new XBase.Model.Personal.MessageBox.MobileMsgMonitor(); entity.CompanyCD = ((UserInfoUtil)SessionUtil.Session["UserInfo"]).CompanyCD; entity.Content = dt.Rows[0]["MsgContents"].ToString(); entity.CreateDate = DateTime.Now; entity.ReceiveMobile = dt.Rows[0]["Mobile"].ToString(); entity.ReceiveUserID = int.Parse(dt.Rows[0]["EmployeeID"].ToString()); entity.ReceiveUserName = dt.Rows[0]["EmployeeName"].ToString(); entity.SendDate = DateTime.Now; entity.SendUserID = ((UserInfoUtil)SessionUtil.Session["UserInfo"]).EmployeeID; entity.SendUserName = ((UserInfoUtil)SessionUtil.Session["UserInfo"]).EmployeeName; entity.Status = "1"; entity.MsgType = "0"; bll.Add(entity); XBase.Common.SMSender.SendBatch(entity.ReceiveMobile, entity.Content); } } } } catch (System.Exception ex) { throw ex; } }
public static void SendMobileMsg(string CompanyCD, string FlowNo, int BillTypeFlag, int BillTypeCode, int BillID, string BillNo, int State, int OperateType) { try { DataTable dt = XBase.Business.Common.FlowBus.GetMsgRemindList(CompanyCD, FlowNo, BillTypeFlag, BillTypeCode, BillID, State, OperateType); XBase.Business.Personal.MessageBox.MobileMsgMonitor bll = new XBase.Business.Personal.MessageBox.MobileMsgMonitor(); if (dt.Rows.Count > 0) { if (!string.IsNullOrEmpty(dt.Rows[0]["EmployeeID"].ToString()) && !string.IsNullOrEmpty(dt.Rows[0]["Mobile"].ToString())) { if (int.Parse(dt.Rows[0]["MsgCount"].ToString())>0) { XBase.Model.Personal.MessageBox.MobileMsgMonitor entity; entity = new XBase.Model.Personal.MessageBox.MobileMsgMonitor(); entity.CompanyCD = ((UserInfoUtil)SessionUtil.Session["UserInfo"]).CompanyCD; entity.Content = dt.Rows[0]["MsgContents"].ToString(); entity.CreateDate = DateTime.Now; entity.ReceiveMobile = dt.Rows[0]["Mobile"].ToString(); entity.ReceiveUserID = int.Parse(dt.Rows[0]["EmployeeID"].ToString()); entity.ReceiveUserName = dt.Rows[0]["EmployeeName"].ToString(); entity.SendDate = DateTime.Now; entity.SendUserID = ((UserInfoUtil)SessionUtil.Session["UserInfo"]).EmployeeID; entity.SendUserName = ((UserInfoUtil)SessionUtil.Session["UserInfo"]).EmployeeName; entity.Status = "1"; entity.MsgType = "0"; bll.Add(entity); XBase.Common.SMSender.SendBatch(entity.ReceiveMobile, entity.Content); } } } } catch (System.Exception ex) { throw ex; } }