feat: 添加微信小程序环境版本配置及相关功能实现

This commit is contained in:
2026-07-23 17:23:10 +08:00
parent ba9f32fd02
commit 05d68d106c
7 changed files with 586 additions and 18 deletions

View File

@@ -42,14 +42,15 @@ public class WeChatMiniProgramApiClient
return new AccessTokenResult(accessToken, expiresIn == null ? 7200 : expiresIn);
}
public QrCodeImage getUnlimitedQrCode(String accessToken, String scene, String page)
public QrCodeImage getUnlimitedQrCode(String accessToken, String scene, String page,
String envVersion)
{
JSONObject requestBody = new JSONObject();
requestBody.put("scene", scene);
requestBody.put("page", page);
// 新页面尚未随小程序版本发布时也允许先生成码;扫码仍会进入正式版小程序。
// 新页面尚未随小程序版本发布时也允许先生成码;扫码进入配置指定的小程序版本
requestBody.put("check_path", false);
requestBody.put("env_version", "release");
requestBody.put("env_version", envVersion);
requestBody.put("width", 430);
HttpResponse response = null;