6 Commits

Author SHA1 Message Date
ageerle
c105d47d99 Merge pull request #125 from MuSan-Li/feature_20250626_fix_update_role
修复修改角色时候报错
2025-06-27 10:45:32 +08:00
l90215
4e2ec2dc82 feat: 修复修改角色时候报错&优化一些代码风格 2025-06-26 10:19:08 +08:00
evo
bf790ceb51 Merge branch 'ageerle:main' into main 2025-06-24 11:43:08 +08:00
GH Action - Upstream Sync
c77a245a4d Merge branch 'main' of https://github.com/ageerle/ruoyi-ai 2025-06-24 01:57:42 +00:00
GH Action - Upstream Sync
e1dc22348c Merge branch 'main' of https://github.com/ageerle/ruoyi-ai 2025-06-07 01:53:26 +00:00
GH Action - Upstream Sync
3e097d9a68 Merge branch 'main' of https://github.com/ageerle/ruoyi-ai 2025-06-06 01:54:02 +00:00
3 changed files with 4 additions and 3 deletions

View File

@@ -440,7 +440,7 @@ public class SysRoleServiceImpl implements ISysRoleService {
return;
}
// 角色关联的在线用户量过大会导致redis阻塞卡顿 谨慎操作
keys.parallelStream().forEach(key -> {
keys.forEach(key -> {
String token = StringUtils.substringAfterLast(key, ":");
// 如果已经过期则跳过
if (StpUtil.stpLogic.getTokenActivityTimeoutByToken(token) < -1) {

View File

@@ -325,9 +325,9 @@ public class SysUserServiceImpl implements ISysUserService, UserService {
@Transactional(rollbackFor = Exception.class)
public int updateUser(SysUserBo user) {
// 新增用户与角色管理
//insertUserRole(user, true);
insertUserRole(user, true);
// 新增用户与岗位管理
//insertUserPost(user, true);
insertUserPost(user, true);
SysUser sysUser = MapstructUtils.convert(user, SysUser.class);
// 防止错误更新后导致的数据误删除
int flag = baseMapper.updateById(sysUser);

View File

@@ -169,6 +169,7 @@ public class ChatCostServiceImpl implements IChatCostService {
/**
* 获取用户Id
*/
@Override
public Long getUserId() {
LoginUser loginUser = LoginHelper.getLoginUser();
if (loginUser == null) {