【portal】修复查询问题

dev-7.6.0-portal
fengshuonan 2023-06-17 12:32:28 +08:00
parent 38abd070cc
commit b5397833af
3 changed files with 16 additions and 3 deletions

View File

@ -692,6 +692,12 @@ public class HrOrganizationServiceImpl extends ServiceImpl<HrOrganizationMapper,
LambdaQueryWrapper<HrOrganization> queryWrapper = this.createWrapper(hrOrganizationRequest);
// parentId不是null的
queryWrapper.isNotNull(HrOrganization::getOrgParentId);
// 查询启用的状态
queryWrapper.eq(HrOrganization::getStatusFlag, StatusEnum.ENABLE.getCode());
// 数据范围过滤
// 如果是超级管理员,或者数据范围权限是所有,则不过滤数据范围
boolean needToDataScope = true;

View File

@ -153,6 +153,11 @@ public class HrPositionServiceImpl extends ServiceImpl<HrPositionMapper, HrPosit
sysUserLambdaQueryWrapper.eq(SysUser::getUserId, userId);
sysUserLambdaQueryWrapper.select(BaseExpandFieldEntity::getExpandField);
SysUser currentUser = this.sysUserService.getOne(sysUserLambdaQueryWrapper, false);
if (currentUser == null) {
return;
}
Map<String, Object> expandField = currentUser.getExpandField();
if (ObjectUtil.isEmpty(expandField)) {

View File

@ -900,9 +900,11 @@ public class SysUserServiceImpl extends ServiceImpl<SysUserMapper, SysUser> impl
}
// 获取用户的头像地址
String fileAuthUrl = fileInfoApi.getFileAuthUrl(detail.getAvatar());
if (fileAuthUrl != null) {
detail.setAvatarUrl(fileAuthUrl);
if(detail.getAvatar() != null){
String fileAuthUrl = fileInfoApi.getFileAuthUrl(detail.getAvatar());
if (fileAuthUrl != null) {
detail.setAvatarUrl(fileAuthUrl);
}
}
sysUserCacheOperatorApi.put(String.valueOf(userId), detail);