aijinhui
2023-09-19 2b0d7956faa548b2f913a333fbd2d0d99aedfa90
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java
@@ -4,6 +4,7 @@
import java.util.stream.Collectors;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.ruoyi.common.core.domain.TreeSelectWell;
import org.springframework.stereotype.Service;
import com.ruoyi.common.annotation.DataScope;
import com.ruoyi.common.constant.UserConstants;
@@ -351,5 +352,16 @@
        return deptList;
    }
    @Override
    public List<SysDept> all() {
        return deptMapper.selectList(null);
    }
    @Override
    public List<TreeSelectWell> wellTree(List<SysDept> depts) {
        List<SysDept> deptTrees = buildDeptTree(depts);
        return deptTrees.stream().map(TreeSelectWell::new).collect(Collectors.toList());
    }
}