package com.dayou.service;
import com.dayou.common.SimpleListModel;
import com.dayou.dto.SimplePostModel;
import com.dayou.entity.UserPost;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.core.metadata.IPage;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;
import java.util.Set;

/**
 * <p>
 * 用户岗位 服务类
 * </p>
 *
 * @author wucl
 * @since 2022-11-29
 */
public interface IUserPostService extends IService<UserPost> {

        Page<UserPost> selectPage(Page page,UserPost userPost);

        UserPost detail(Long id);

        Boolean add(UserPost userPost);

        Boolean update(UserPost userPost);

        Boolean delete(Long id);

        XSSFWorkbook generateImportTemplate();

        void importExcel(MultipartFile file);

        XSSFWorkbook exportExcel(UserPost userPost);

        List<SimplePostModel> getPostList(Long userId);

    void saveOrUpdateById(UserPost userPost);

    Set<Long> getPostUserId(Set<Long> juniorPost);

    SimplePostModel getMarketPostList(Long userId);

    void checkMultiPostInMarketDepartment(Set<Long> postIds);

    Long getUniqueHandlerByPostForWorkNode(Long postId);
}
