起步软件技术论坛
搜索
 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 1763|回复: 3

[处理中3] 公众号开发 二级菜单怎么写

[复制链接]

7

主题

17

帖子

35

积分

新手上路

Rank: 1

积分
35
QQ
发表于 2016-8-2 17:27:47 | 显示全部楼层 |阅读模式
本帖最后由 qw888 于 2016-8-2 17:31 编辑

发一个图片案例
QQ截图20160802172718.png

7

主题

17

帖子

35

积分

新手上路

Rank: 1

积分
35
QQ
 楼主| 发表于 2016-8-3 00:06:21 | 显示全部楼层
...没人理呀
回复

使用道具 举报

3

主题

20

帖子

80

积分

初级会员

Rank: 2

积分
80
QQ
发表于 2016-8-3 16:26:58 | 显示全部楼层
//------------主菜单------------------//
         WxMenuButton ab1 = new WxMenuButton();
         ab1.setName("信息查询");
         ab1.setType(WxConsts.BUTTON_CLICK);
         ab1.setKey("xxcx");
         
         WxMenuButton ab2 = new WxMenuButton();
         ab2.setName("生活助手");
         ab2.setType(WxConsts.BUTTON_CLICK);
         ab2.setKey("shzs");
                 
         WxMenuButton ab3 = new WxMenuButton();
         ab3.setName("积分商城");
         ab3.setType(WxConsts.BUTTON_VIEW);
         ab3.setUrl("http://m.suning.com");
         
         
         //------------信息查询子菜单------------------//
         WxMenuButton zbwd = new WxMenuButton();
         zbwd.setName("周边网点");
         zbwd.setType(WxConsts.BUTTON_VIEW);
         zbwd.setUrl("http://www.justep.com");
         xxcx.add(zbwd);
         
         WxMenuButton khxx = new WxMenuButton();
         khxx.setName("昆行信息");
         khxx.setType(WxConsts.BUTTON_VIEW);
         khxx.setUrl("http://x5.justep.com/x5/UI2/demo/index.w");
         xxcx.add(khxx);
         
         WxMenuButton jfcx = new WxMenuButton();
         jfcx.setName("积分查询");
         jfcx.setType(WxConsts.BUTTON_VIEW);
         jfcx.setUrl("https://open.weixin.qq.com/connect/oauth2/authorize?appid=" + this.getWxMpConfigStorage().getAppId() + "&redirect_uri=http%3A%2F%2Fx5.justep.com%2Fx5%2FUI2%2Fw%2Flogin.w&"
                         + "response_type=code&scope=snsapi_base&state=STATE#wechat_redirect");
         xxcx.add(jfcx);
         
         WxMenuButton wdzl = new WxMenuButton();
         wdzl.setName("我的资料");
         wdzl.setType(WxConsts.BUTTON_VIEW);
         wdzl.setUrl("https://open.weixin.qq.com/connect/oauth2/authorize?appid=" + this.getWxMpConfigStorage().getAppId() + "&redirect_uri=http%3A%2F%2F893596170hsk.vicp.cc%2Fx5%2FUI2%2Ftakeout%2Findex.w&"
                         + "response_type=code&scope=snsapi_base&state=STATE#wechat_redirect");
         xxcx.add(wdzl);
         
         
回复 支持 反对

使用道具 举报

发表于 2016-8-4 13:08:08 | 显示全部楼层
qq:1912779713
WeX5教程--WeX5下载
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|X3技术论坛|Justep Inc.    

GMT+8, 2024-5-3 03:59 , Processed in 0.061633 second(s), 26 queries .

Powered by Discuz! X3.4

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表