|
@@ -64,6 +64,7 @@ class WeixinAuthService extends AxiosService {
|
|
|
throw new BusinessError(ErrorCode.SERVICE_FAULT, '未获取到openid');
|
|
|
}
|
|
|
// 获取微信的用户信息
|
|
|
+ console.log({ access_token, appid, openid });
|
|
|
const res = await this.httpGet('https://api.weixin.qq.com/cgi-bin/user/info?lang=zh_CN', { access_token, appid, openid });
|
|
|
const object = _.pick(res, [ 'nickname', 'headimgurl', 'openid' ]); // 昵称,头像,openid
|
|
|
console.log(object);
|