|
@@ -4,12 +4,14 @@ import cn.com.ty.lift.system.wechat.constants.WxConstants;
|
|
|
import cn.hutool.http.HttpUtil;
|
|
|
import cn.hutool.json.JSONObject;
|
|
|
import cn.hutool.json.JSONUtil;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
|
|
|
/**
|
|
|
* @author huangyuan
|
|
|
* @date 2019-12-30
|
|
|
* @description
|
|
|
*/
|
|
|
+@Slf4j
|
|
|
public class WxUtil {
|
|
|
|
|
|
/**
|
|
@@ -48,6 +50,7 @@ public class WxUtil {
|
|
|
.replace("SECRET", appSecret)
|
|
|
.replace("CODE", authCode);
|
|
|
JSONObject result = JSONUtil.parseObj(HttpUtil.get(url));
|
|
|
+ log.error(result.toString());
|
|
|
if (result.containsKey("openid")) {
|
|
|
return result.getStr("openid");
|
|
|
}
|