Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

公众号发送模板消息小程序路径是pagepath而不是path #1367

Closed
lenvonsam opened this issue Jan 7, 2020 · 2 comments
Closed

Comments

@lenvonsam
Copy link

简要描述

公众号发送模板消息小程序路径是pagepath而不是path

模块版本情况

  • WxJava 模块名: WxMpTemplateMessage
  • WxJava 版本号:3.6.0

详细描述

公众号发送模板消息小程序路径是pagepath而不是path

mpService.getTemplateMsgService().sendTemplateMsg(tpltMessage)

WxMpTemplateMessage实例生成的json string中小程序路径的key是path而不是pagepath,导致用户从消息模板跳转到小程序永远是首页而不是指定页面,麻烦尽快解决,谢谢

@binarywang
Copy link
Owner

binarywang commented Jan 7, 2020

还有个参数,你注意下:
me.chanjar.weixin.mp.bean.template.WxMpTemplateMessage.MiniProgram 类里的:

    /**
     * 是否使用path,否则使用pagepath.
     * 加入此字段是基于微信官方接口变化多端的考虑
     */
    private boolean usePath = true;

@lenvonsam
Copy link
Author

谢谢,由于个人的疏忽,少看了usePath这个参数,问题解决了,开心~~~

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants