package com.ssm.service.system;

import java.util.List;

import com.ssm.model.system.SysDepartment;
import com.ssm.util.page.PagedResult;

public interface SysDepartmentService {
	/**
	 * 查询所有的 部门 ,并关联查询 他拥有的职位
	 * @param example
	 * @return
	 */
	public List<SysDepartment> findAll();
	
	
	/**
	 * 查询所有部门
	 * */
	public List<SysDepartment> getDepartmentList();
	
	/**
	 * 部门分页查询
	 * */
	public PagedResult<SysDepartment> sysDepartmentQuery(SysDepartment sysDepartment ,Integer pageNo,
			Integer pageSize);
	
	/**
	 * 编辑部门
	 * */
	public void updateByPrimaryKeySelective(SysDepartment sysDepartment);
	/**
	 * 新增部门
	 * */
	
	public void insertSelective(SysDepartment sysDepartment);
	
	/**
	 * 查询部门
	 * */
	public SysDepartment selectByPrimaryKey(Integer depid);
	
	public int countByExample();
	
	public SysDepartment sysDepartmentParentid(Integer parentid);
	
	public Integer selectParentid(Integer parentid);
	public Integer selectMaxParentid(Integer parentid);
}
