Example #1
0
        /// <summary>
        /// 推送纯文字
        /// 2013-9-12
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public IResponseMessageBase GetResponseMessageTxtByContent(RequestMessageEventBase requestMessage, string content,int wid)
        {
            var responseMessage = ResponseMessageBase.CreateFromRequestMessage<ResponseMessageText>(requestMessage);
            var locationService = new LocationService();
            responseMessage.Content = content;
            string EventName = "";
            if (requestMessage.Event.ToString().Trim() != "")
            {
                EventName = requestMessage.Event.ToString();
            }
            else if (requestMessage.EventKey != null)
            {
                EventName += requestMessage.EventKey.ToString();
            }
            wxResponseBaseMgr.Add(wid, requestMessage.FromUserName, requestMessage.MsgType.ToString(), EventName, "text", "事件:推送纯粹的文字,内容为:" + content, requestMessage.ToUserName);

            return responseMessage;
        }
Example #2
0
 /// <summary>
 /// 推送纯文字
 /// 2013-9-12
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public IResponseMessageBase GetResponseMessageTxtByContent(RequestMessageImage requestMessage, string content, int wid)
 {
     var responseMessage = ResponseMessageBase.CreateFromRequestMessage<ResponseMessageText>(requestMessage);
     var locationService = new LocationService();
     responseMessage.Content = content;
     wxResponseBaseMgr.Add(wid, requestMessage.FromUserName, requestMessage.MsgType.ToString(), "微信上墙", "text", "文字请求,推送纯粹文字,内容为:" + content, requestMessage.ToUserName);
     return responseMessage;
 }