package com.inspect.system.service;

import com.inspect.system.base.domain.SysDept;
import com.inspect.system.domain.vo.TreeSelect;

import java.util.List;

public interface ISysDeptService {
    List<SysDept> selectDeptList(SysDept sysDept);

    List<SysDept> buildDeptTree(List<SysDept> sysDeptList);

    List<TreeSelect> buildDeptTreeSelect(List<SysDept> sysDeptList);

    List<Long> selectDeptListByRoleId(Long roleId);

    SysDept selectDeptById(Long id);

    int selectNormalChildrenDeptById(Long id);

    boolean hasChildByDeptId(Long deptId);

    boolean checkDeptExistUser(Long deptId);

    String checkDeptNameUnique(SysDept sysDept);

    void checkDeptDataScope(Long deptId);

    int insertDept(SysDept sysDept);

    int updateDept(SysDept sysDept);

    int deleteDeptById(Long deptId);
}
