mirror of
https://github.com/dromara/RuoYi-Vue-Plus.git
synced 2025-09-24 07:19:46 +08:00
update 优化 登录用户增加岗位数据
This commit is contained in:
@ -25,6 +25,14 @@ public interface ISysPostService {
|
||||
*/
|
||||
List<SysPostVo> selectPostList(SysPostBo post);
|
||||
|
||||
/**
|
||||
* 查询用户所属岗位组
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 岗位ID
|
||||
*/
|
||||
List<SysPostVo> selectPostsByUserId(Long userId);
|
||||
|
||||
/**
|
||||
* 查询所有岗位
|
||||
*
|
||||
|
@ -8,6 +8,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.dromara.common.core.constant.SystemConstants;
|
||||
import org.dromara.common.core.exception.ServiceException;
|
||||
import org.dromara.common.core.service.PostService;
|
||||
import org.dromara.common.core.utils.MapstructUtils;
|
||||
import org.dromara.common.core.utils.StreamUtils;
|
||||
import org.dromara.common.core.utils.StringUtils;
|
||||
@ -34,7 +35,7 @@ import java.util.List;
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class SysPostServiceImpl implements ISysPostService {
|
||||
public class SysPostServiceImpl implements ISysPostService, PostService {
|
||||
|
||||
private final SysPostMapper baseMapper;
|
||||
private final SysDeptMapper deptMapper;
|
||||
@ -57,6 +58,17 @@ public class SysPostServiceImpl implements ISysPostService {
|
||||
return baseMapper.selectVoList(buildQueryWrapper(post));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询用户所属岗位组
|
||||
*
|
||||
* @param userId 用户ID
|
||||
* @return 岗位ID
|
||||
*/
|
||||
@Override
|
||||
public List<SysPostVo> selectPostsByUserId(Long userId) {
|
||||
return baseMapper.selectPostsByUserId(userId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据查询条件构建查询包装器
|
||||
*
|
||||
|
Reference in New Issue
Block a user