fix
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
package com.starry.admin.modules.weichat.service;
|
||||
|
||||
|
||||
import com.starry.common.utils.IdUtils;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.starry.admin.common.exception.ServiceException;
|
||||
import com.starry.admin.modules.clerk.module.entity.PlayClerkUserInfoEntity;
|
||||
import com.starry.admin.modules.clerk.service.IPlayClerkLevelInfoService;
|
||||
@@ -11,6 +11,7 @@ import com.starry.admin.modules.custom.module.entity.PlayCustomUserInfoEntity;
|
||||
import com.starry.admin.modules.custom.service.IPlayCustomLevelInfoService;
|
||||
import com.starry.admin.modules.custom.service.IPlayCustomUserInfoService;
|
||||
import com.starry.common.utils.ConvertUtil;
|
||||
import com.starry.common.utils.IdUtils;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import me.chanjar.weixin.common.bean.WxOAuth2UserInfo;
|
||||
import me.chanjar.weixin.common.bean.oauth2.WxOAuth2AccessToken;
|
||||
@@ -92,6 +93,7 @@ public class WxOauthService {
|
||||
WxOAuth2AccessToken token = getWxOAuth2AccessToken(code);
|
||||
String openId = getOpenId(token);
|
||||
WxOAuth2UserInfo userInfo = getWxOAuth2UserInfo(token);
|
||||
log.info("微信登录返回用户信息:" + JSONObject.toJSONString(userInfo));
|
||||
PlayCustomUserInfoEntity entity = ConvertUtil.entityToVo(userInfo, PlayCustomUserInfoEntity.class);
|
||||
entity.setAvatar(userInfo.getHeadImgUrl());
|
||||
PlayCustomUserInfoEntity item = customUserInfoService.selectByOpenid(openId);
|
||||
|
||||
Reference in New Issue
Block a user