扫描小程序码分享
微信自定义菜单连续触发事件后回复失效
如果菜单类型为:location_select,用户点击发送地理位置后,会触发location_select和location两个事件,当两个事件一个返回对应的XML文本,另一个返回success时,回复会失效,用户不会接受到任何信息
2 个回答
加粗
标红
插入代码
插入链接
插入图片
上传视频
那怎么处理,我需要回复location_select的消息,
因为这个消息有eventkey,localtion事件没有我定义的key。
我怀疑因为排重所以localtion时间默认回复“”覆盖或排重掉location_select的回复消息。
不知道该怎么解决
你好,麻烦通过点击下方“反馈信息”按钮,提供出现问题的。
你好,建议可以先查看是否是以下情况,https://developers.weixin.qq.com/doc/offiaccount/Custom_Menus/Creating_Custom-Defined_Menu.html
[2021-08-24 11:32:28] <xml><ToUserName><![CDATA[xxx]]></ToUserName>\n<FromUserName><![CDATA[xxx]]></FromUserName>\n<CreateTime>1629775948</CreateTime>\n<MsgType><![CDATA[event]]></MsgType>\n<Event><![CDATA[location_select]]></Event>\n<EventKey><![CDATA[文字]]></EventKey>\n<SendLocationInfo><Location_X><![CDATA[37.807090258661852]]></Location_X>\n<Location_Y><![CDATA[112.53274236973682]]></Location_Y>\n<Scale><![CDATA[15]]></Scale>\n<Label><![CDATA[山西省太原市晋源区广南街]]></Label>\n<Poiname><![CDATA[山西大剧院(太原市晋源区商务区广南街)]]></Poiname>\n</SendLocationInfo>\n</xml>
[2021-08-24 11:32:28 <xml><MsgType><![CDATA[text]]></MsgType><Content><![CDATA[顶顶顶顶/呲牙]]></Content><ToUserName><![CDATA[xxxxx]]></ToUserName><FromUserName><![CDATA[xxx]]></FromUserName><CreateTime>1629775948</CreateTime></xml>
[2021-08-24 11:32:28] <xml><ToUserName><![CDATA[xxx]]></ToUserName>\n<FromUserName><![CDATA[xxx]]></FromUserName>\n<CreateTime>1629775948</CreateTime>\n<MsgType><![CDATA[location]]></MsgType>\n<Location_X>37.807090</Location_X>\n<Location_Y>112.532742</Location_Y>\n<Scale>15</Scale>\n<Label><![CDATA[山西省太原市晋源区广南街]]></Label>\n<MsgId>23332781470237984</MsgId>\n</xml>
[2021-08-24 11:32:28] success
关注后,可在微信内接收相应的重要提醒。
请使用微信扫描二维码关注 “微信开放社区” 公众号
那怎么处理,我需要回复location_select的消息,
因为这个消息有eventkey,localtion事件没有我定义的key。
我怀疑因为排重所以localtion时间默认回复“”覆盖或排重掉location_select的回复消息。
不知道该怎么解决
你好,建议可以先查看是否是以下情况,https://developers.weixin.qq.com/doc/offiaccount/Custom_Menus/Creating_Custom-Defined_Menu.html
[2021-08-24 11:32:28] <xml><ToUserName><![CDATA[xxx]]></ToUserName>\n<FromUserName><![CDATA[xxx]]></FromUserName>\n<CreateTime>1629775948</CreateTime>\n<MsgType><![CDATA[event]]></MsgType>\n<Event><![CDATA[location_select]]></Event>\n<EventKey><![CDATA[文字]]></EventKey>\n<SendLocationInfo><Location_X><![CDATA[37.807090258661852]]></Location_X>\n<Location_Y><![CDATA[112.53274236973682]]></Location_Y>\n<Scale><![CDATA[15]]></Scale>\n<Label><![CDATA[山西省太原市晋源区广南街]]></Label>\n<Poiname><![CDATA[山西大剧院(太原市晋源区商务区广南街)]]></Poiname>\n</SendLocationInfo>\n</xml>
[2021-08-24 11:32:28 <xml><MsgType><![CDATA[text]]></MsgType><Content><![CDATA[顶顶顶顶/呲牙]]></Content><ToUserName><![CDATA[xxxxx]]></ToUserName><FromUserName><![CDATA[xxx]]></FromUserName><CreateTime>1629775948</CreateTime></xml>
[2021-08-24 11:32:28] <xml><ToUserName><![CDATA[xxx]]></ToUserName>\n<FromUserName><![CDATA[xxx]]></FromUserName>\n<CreateTime>1629775948</CreateTime>\n<MsgType><![CDATA[location]]></MsgType>\n<Location_X>37.807090</Location_X>\n<Location_Y>112.532742</Location_Y>\n<Scale>15</Scale>\n<Label><![CDATA[山西省太原市晋源区广南街]]></Label>\n<MsgId>23332781470237984</MsgId>\n</xml>
[2021-08-24 11:32:28] success