Commit d1686dde authored by xianjun's avatar xianjun

获取小程序码

parent 6c0e48e9
package com.yanzuoguang.wxxcx.codeorlink.wxacode; package com.yanzuoguang.wxxcx.codeorlink.wxacode;
import com.yanzuoguang.util.vo.BaseVo;
/** /**
* 获取小程序码 请求 * 获取小程序码 请求
* 适用于需要的码数量极多的业务场景。通过该接口生成的小程序码,永久有效,数量暂无限制 * 适用于需要的码数量极多的业务场景。通过该接口生成的小程序码,永久有效,数量暂无限制
* *
* @author 李贤军 * @author 李贤军
*/ */
public class WxXcxWxaCodeGetUnlimitedReq { public class WxXcxWxaCodeGetUnlimitedReq extends BaseVo {
/** /**
* 最大32个可见字符,只支持数字,大小写英文以及部分特殊字符:!#$&'()*+,/:;=?@-._~,其它字符请自行编码为合法字符(因不支持%,中文无法使用 urlencode 处理,请使用其他编码方式 * 最大32个可见字符,只支持数字,大小写英文以及部分特殊字符:!#$&'()*+,/:;=?@-._~,其它字符请自行编码为合法字符(因不支持%,中文无法使用 urlencode 处理,请使用其他编码方式
...@@ -16,6 +18,11 @@ public class WxXcxWxaCodeGetUnlimitedReq { ...@@ -16,6 +18,11 @@ public class WxXcxWxaCodeGetUnlimitedReq {
* 页面 page,例如 pages/index/index,根路径前不要填加 /,不能携带参数(参数请放在 scene 字段里),如果不填写这个字段,默认跳主页面 * 页面 page,例如 pages/index/index,根路径前不要填加 /,不能携带参数(参数请放在 scene 字段里),如果不填写这个字段,默认跳主页面
*/ */
private String page; private String page;
/**
* 二维码的宽度,单位 px,最小 280px,最大 1280px
*/
private int width;
/** /**
* 检查 page 是否存在,为 true 时 page 必须是已经发布的小程序存在的页面(否则报错);为 false 时允许小程序未发布或者 page 不存在, 但 page 有数量上限(60000个)请勿滥用 * 检查 page 是否存在,为 true 时 page 必须是已经发布的小程序存在的页面(否则报错);为 false 时允许小程序未发布或者 page 不存在, 但 page 有数量上限(60000个)请勿滥用
*/ */
...@@ -37,6 +44,14 @@ public class WxXcxWxaCodeGetUnlimitedReq { ...@@ -37,6 +44,14 @@ public class WxXcxWxaCodeGetUnlimitedReq {
*/ */
private boolean is_hyaline; private boolean is_hyaline;
public int getWidth() {
return width;
}
public void setWidth(int width) {
this.width = width;
}
public String getScene() { public String getScene() {
return scene; return scene;
} }
......
...@@ -32,7 +32,6 @@ public class WxXcxWxaCodeGetUnlimitedRequest implements WxXcxRequestUrl, WxXcxRe ...@@ -32,7 +32,6 @@ public class WxXcxWxaCodeGetUnlimitedRequest implements WxXcxRequestUrl, WxXcxRe
@Override @Override
public String getUrlPara() { public String getUrlPara() {
accessToken.setAccess_token("58_e5G4V2hsQWsBzlkCyZj0I3MNF2DP6Mk5iE_Gc4NgMlUjKdEhxEMtRn20PTXh_hWiiD4pqAaW2BUZvok4iUNa5DcGcIvklbQ3eg7Y-dESZocQY2zjYYJrzmN0i41RCa1yyhg26S2gQkJuBbwyMBBfAFAETT");
return HttpHelper.getUrlParameter(accessToken); return HttpHelper.getUrlParameter(accessToken);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment