|
|
|
|
@ -12,6 +12,7 @@ import com.google.common.collect.Lists;
|
|
|
|
|
import com.ruoyi.common.core.domain.entity.SysDept;
|
|
|
|
|
import com.ruoyi.common.core.domain.model.LoginUser;
|
|
|
|
|
import com.ruoyi.common.utils.SecurityUtils;
|
|
|
|
|
import com.ruoyi.system.mapper.SysDeptMapper;
|
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
@ -30,6 +31,9 @@ public class BusinessSysDeptService {
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
private ISysDeptService sysDeptService;
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
private SysDeptMapper deptMapper;
|
|
|
|
|
@Autowired
|
|
|
|
|
private ISysUserDeptService userDeptService;
|
|
|
|
|
@Autowired
|
|
|
|
|
@ -180,8 +184,9 @@ public class BusinessSysDeptService {
|
|
|
|
|
// sysDept.setDeptType("2");
|
|
|
|
|
LoginUser loginUser = SecurityUtils.getLoginUser();
|
|
|
|
|
sysDept.setTenantId(loginUser.getNowTenantId());
|
|
|
|
|
QueryWrapper<SysDept> qw = new QueryWrapper<>(sysDept);
|
|
|
|
|
List<SysDept> list = sysDeptService.list(qw);
|
|
|
|
|
// QueryWrapper<SysDept> qw = new QueryWrapper<>(sysDept);
|
|
|
|
|
// List<SysDept> list = sysDeptService.list(qw);
|
|
|
|
|
List<SysDept> list = deptMapper.selectDeptList(sysDept);
|
|
|
|
|
return list.stream().map(RespTreeSelect::new).collect(Collectors.toList());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|