package com.judong.chuanyiserver.service;

import com.judong.chuanyiserver.entity.Department;
import com.judong.chuanyiserver.util.Result;

import java.util.List;

public interface DepartmentService {

    Result addDepartment(Department department);

    Result updateDepartment(Department department);

    Result getDepartmentListByPage(Integer page, Integer limit);

    Result getDepartmentById(Integer id);

    /**
     * 根据父亲id查孩子部门（一级列表）
     */
    Result queryDepartmentByParentId(Integer parentId);

    /**
     * 查询所有子节点
     */
    List<Department> queryDepartmentAllChildren(Integer parentId);

    /**
     *批量删除
     */
    Result isDeleteById(List<Integer> id);


}
