update 优化 调整方法位置

master
疯狂的狮子Li 1 year ago
parent 29c5ff89ba
commit c566f2ae28

@ -176,6 +176,31 @@ public class SysDeptServiceImpl implements ISysDeptService, DeptService {
return String.join(StringUtils.SEPARATOR, list);
}
/**
* ID
*
* @param deptId ID
* @return ID
*/
@Override
public Long selectDeptLeaderById(Long deptId) {
SysDeptVo vo = SpringUtils.getAopProxy(this).selectDeptById(deptId);
return vo.getLeader();
}
/**
*
*
* @return
*/
@Override
public List<DeptDTO> selectDeptsByList() {
List<SysDeptVo> list = baseMapper.selectDeptList(new LambdaQueryWrapper<SysDept>()
.select(SysDept::getDeptId, SysDept::getDeptName, SysDept::getParentId)
.eq(SysDept::getStatus, SystemConstants.NORMAL));
return BeanUtil.copyToList(list, DeptDTO.class);
}
/**
* ID
*
@ -356,29 +381,4 @@ public class SysDeptServiceImpl implements ISysDeptService, DeptService {
return baseMapper.deleteById(deptId);
}
/**
* ID
*
* @param deptId ID
* @return ID
*/
@Override
public Long selectDeptLeaderById(Long deptId) {
SysDeptVo vo = SpringUtils.getAopProxy(this).selectDeptById(deptId);
return vo.getLeader();
}
/**
*
*
* @return
*/
@Override
public List<DeptDTO> selectDeptsByList() {
List<SysDeptVo> list = baseMapper.selectDeptList(new LambdaQueryWrapper<SysDept>()
.select(SysDept::getDeptId, SysDept::getDeptName, SysDept::getParentId)
.eq(SysDept::getStatus, SystemConstants.NORMAL));
return BeanUtil.copyToList(list, DeptDTO.class);
}
}

Loading…
Cancel
Save