| /** | 
|  * Copyright (c) 2018 人人开源 All rights reserved. | 
|  * | 
|  * https://www.renren.io | 
|  * | 
|  * 版权所有,侵权必究! | 
|  */ | 
|   | 
| package com.zt.core.sys.service; | 
|   | 
| import com.zt.core.sys.model.SysDept; | 
|   | 
| import java.util.List; | 
|   | 
| /** | 
|  * 部门管理 | 
|  * | 
|  * @author hehz | 
|  */ | 
| public interface ISysDeptService { | 
|   | 
|     SysDept get(Long id); | 
|   | 
|     void insert(SysDept dept); | 
|   | 
|     void update(SysDept dept); | 
|   | 
|     void delete(Long id); | 
|   | 
|     /** | 
|      * 通过deptId查找所有祖先,按照祖先的层级排序 | 
|      * | 
|      * @param id | 
|      * @return | 
|      */ | 
|     List<SysDept> getAncestor(Long id); | 
|   | 
|     /** | 
|      * 根据部门ID,获取本部门及子部门ID列表 | 
|      * | 
|      * @param id | 
|      *            部门ID | 
|      */ | 
|     List<Long> getWithDescendantIds(Long id); | 
|   | 
|     /** | 
|      * 获取下级 | 
|      * | 
|      * @param id | 
|      * @return | 
|      */ | 
|     List<SysDept> getDescendant(Long id); | 
|   | 
|     /** | 
|      * 获取某部门的子节点 | 
|      * | 
|      * @param id | 
|      * @return | 
|      */ | 
|     List<SysDept> getChildren(Long id); | 
| } |