101captain
2022-05-17 4b0fc642f33c05e6c31b959a7e6574b14c550237
花城E+bug更新
1个文件已修改
14 ■■■■ 已修改文件
springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/utlis/WxXCXTempSend.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/utlis/WxXCXTempSend.java
@@ -113,18 +113,8 @@
    public String getAppAccessToken() throws Exception {
        String accessToken = "0";
        try {
            // 此处APP_ID APP_SECRET 在微信小程序后端可见
            // String accessTokenUrl = String.format(TEMP_URL, APP_ID, APP_SECRET);
            String appId = getAppId();
            String appSecret = getAppSecret();
            if(StringUtils.isEmpty(appId)){
                appId = APP_ID;
            }
            if(StringUtils.isEmpty(appSecret)){
                appSecret = APP_SECRET;
            }
            log.info("获取微信token参数:appid=" + appId + ",appSecret=" + appSecret);
            String accessTokenUrl = ACCESS_TOKEN_URL + "&appid=" + appId + "&secret=" + appSecret;
            log.info("获取微信token参数:appid=" + APP_ID + ",appSecret=" + APP_SECRET);
            String accessTokenUrl = ACCESS_TOKEN_URL + "&appid=" + APP_ID + "&secret=" + APP_SECRET;
            String result = HttpClientUtil.httpGet(accessTokenUrl, null, null);
            Map<String, Object> resultMap = JSON.parseObject(result, Map.class);
            if (resultMap.containsKey("access_token")) {