| | |
| | | |
| | | return s; |
| | | } |
| | | @Override |
| | | public JSONObject getUser(String token, String openId) { |
| | | String requestUrl = "https://api.weixin.qq.com/sns/userinfo"; |
| | | |
| | | Map<String, String> requestUrlParam = new HashMap<>(); |
| | | |
| | | requestUrlParam.put("access_token", token); |
| | | |
| | | requestUrlParam.put("openid", openId); |
| | | |
| | | requestUrlParam.put("lang", "zh_CN"); |
| | | |
| | | JSONObject s = JSON.parseObject(HttpClientUtil.doGet(requestUrl, requestUrlParam)); |
| | | |
| | | return s; |
| | | } |
| | | // private String getWechatHeadImgUrl(String unionId) { |
| | | // WechatUserDO wxUser = this.template.findOne(Query.query(condition().and("unionId").is(unionId)), WechatUserDO.class); |
| | | // return wxUser.getHeadImgUrl(); |