package com.dayou.service;
import com.dayou.dto.SimpleDepartmentModel;
import com.dayou.entity.Department;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.dayou.entity.User;
import com.dayou.vo.DepartmentStatVO;
import com.dayou.vo.DepartmentVO;
import com.dayou.vo.UserVO;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

/**
 * <p>
 * 机构 服务类
 * </p>
 *
 * @author wucl
 * @since 2022-11-29
 */
public interface IDepartmentService extends IService<Department> {

        Page<DepartmentVO> selectPage(Page page,Department department);

        Department detail(Long id);

        Boolean add(Department department);

        Boolean update(Department department);

        Boolean delete(Long id);

        XSSFWorkbook generateImportTemplate();

        void importExcel(MultipartFile file);


    IPage<DepartmentVO> xPage(SimpleDepartmentModel department, Page page);

        DepartmentStatVO stat();

    /**
     * 根据业务code获取接单部门
     * @param businessCode 业务code
     * @return List<Department>
     */
    List<Department> getAllotDepartmentByBusiness(String businessCode);

}
