Exemplo n.º 1
0
        /// <summary>
        /// 充值过短信但是现在短信为0的客户清单并给出提示
        /// </summary>
        public void StartMsgZero()
        {
            //获取账户里面有1周前未审核评价的卖家
            ShopData        dbShop = new ShopData();
            List <ShopInfo> list   = dbShop.GetShopInfoListMsgZero();

            MessageData dbMessage = new MessageData();
            string      typ       = "msgzero";

            //循环获取这些卖家的未审核订单
            for (int i = 0; i < list.Count; i++)
            {
                ShopInfo shop = list[i];
                //告之这些卖家他们的优惠券已经过期,需要重新设置
                string msg = "好评有礼:亲爱的" + shop.Nick + ",您的短信已用完,请尽快充值以免影响正常使用,详情请联系客服!";

                //如果7天内已经发送过类似短信的话则不再提醒
                if (!dbMessage.IsSendMsgNearDays(shop, typ))
                {
                    string msgResult = Message.SendGuodu(shop.Mobile, msg);
                    dbMessage.InsertShopAlertMsgLog(shop, msg, msgResult, typ);
                }
            }
        }