mirror of
https://gitee.com/dromara/RuoYi-Vue-Plus.git
synced 2026-09-21 02:25:56 +08:00
接口名改成绑定,和登录区分,适配客户端授权,支持选择租户切换授权平台登录
This commit is contained in:
parent
ff1f3bdc16
commit
a667c85344
@ -1,7 +1,6 @@
|
||||
package org.dromara.web.controller;
|
||||
|
||||
import cn.dev33.satoken.annotation.SaIgnore;
|
||||
import cn.dev33.satoken.stp.StpUtil;
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
|
||||
@ -92,7 +92,7 @@ public class SysLoginService {
|
||||
SysUser user = userMapper.selectOne(new LambdaQueryWrapper<SysUser>()
|
||||
.eq(SysUser::getUserId, social.getUserId()));
|
||||
// 执行登录
|
||||
return loginAndRecord(user.getTenantId(), user.getUserName(), authUserData);
|
||||
return loginAndRecord(user.getTenantId(), user.getUserName());
|
||||
} else {
|
||||
return R.fail("你还没有绑定第三方账号,绑定后才可以登录!");
|
||||
}
|
||||
@ -131,10 +131,9 @@ public class SysLoginService {
|
||||
*
|
||||
* @param tenantId 租户ID
|
||||
* @param userName 用户名
|
||||
* @param authUser 授权用户信息
|
||||
* @return 统一响应实体
|
||||
*/
|
||||
private R<String> loginAndRecord(String tenantId, String userName, AuthUser authUser) {
|
||||
private R<String> loginAndRecord(String tenantId, String userName) {
|
||||
checkTenant(tenantId);
|
||||
SysUserVo user = loadUserByUsername(tenantId, userName);
|
||||
SaLoginModel model = new SaLoginModel();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user