|
@@ -155,6 +155,7 @@ public class SysUserServiceImpl extends ServiceImpl<SysUserRepository,SysUserPO>
|
|
|
assignUserRole(source.getId(),source.getRoleIds());
|
|
assignUserRole(source.getId(),source.getRoleIds());
|
|
|
assignUserPortal(source.getId(),source.getPortalIds());
|
|
assignUserPortal(source.getId(),source.getPortalIds());
|
|
|
assignUserPosition(source.getId(),source.getPostIds());
|
|
assignUserPosition(source.getId(),source.getPostIds());
|
|
|
|
|
+ sysUserService.delUserIdAndNickNameCache();
|
|
|
}
|
|
}
|
|
|
return result;
|
|
return result;
|
|
|
}
|
|
}
|
|
@@ -172,7 +173,9 @@ public class SysUserServiceImpl extends ServiceImpl<SysUserRepository,SysUserPO>
|
|
|
if(CollectionUtil.isEmpty(ids)){
|
|
if(CollectionUtil.isEmpty(ids)){
|
|
|
throw new ServiceException(TRExcCode.SYSTEM_ERROR_B0001,"请选择要删除的数据");
|
|
throw new ServiceException(TRExcCode.SYSTEM_ERROR_B0001,"请选择要删除的数据");
|
|
|
}
|
|
}
|
|
|
- return baseMapper.deleteBatchIds(ids);
|
|
|
|
|
|
|
+ int result = baseMapper.deleteBatchIds(ids);
|
|
|
|
|
+ sysUserService.delUserIdAndNickNameCache();
|
|
|
|
|
+ return result;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|
|
@@ -203,6 +206,18 @@ public class SysUserServiceImpl extends ServiceImpl<SysUserRepository,SysUserPO>
|
|
|
user.setLastLoginIp(ip);
|
|
user.setLastLoginIp(ip);
|
|
|
user.setLastLoginAddress(cityInfo);
|
|
user.setLastLoginAddress(cityInfo);
|
|
|
this.updateById(user);
|
|
this.updateById(user);
|
|
|
|
|
+ sysUserService.delUserIdAndNickNameCache();
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ @Override
|
|
|
|
|
+ public List<Pair<String, String>> selectAllUserIdAndNickName() {
|
|
|
|
|
+ List<SysUserPO> allUser = baseMapper.selectList(new LambdaQueryWrapper<SysUserPO>()
|
|
|
|
|
+ .select(SysUserPO::getId, SysUserPO::getNickname));
|
|
|
|
|
+ List<Pair<String, String>> result = new ArrayList<>();
|
|
|
|
|
+ for (SysUserPO userPO : allUser) {
|
|
|
|
|
+ result.add(Pair.of(userPO.getId(),userPO.getNickname()));
|
|
|
|
|
+ }
|
|
|
|
|
+ return result;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|