package com.dayou.service;
import com.dayou.bo.PrivilegeTreeBO;
import com.dayou.entity.PostPrivilege;
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;

/**
 * <p>
 * 岗位菜单权限 服务类
 * </p>
 *
 * @author wucl
 * @since 2022-11-29
 */
public interface IPostPrivilegeService extends IService<PostPrivilege> {

        Page<PostPrivilege> selectPage(Page page,PostPrivilege postPrivilege);

        PostPrivilege detail(Long id);

        Boolean add(PostPrivilege postPrivilege);

        Boolean update(PostPrivilege postPrivilege);

        Boolean delete(Long id);

        XSSFWorkbook generateImportTemplate();

        void importExcel(MultipartFile file);

        XSSFWorkbook exportExcel(PostPrivilege postPrivilege);

    void saveOrUpdateById(PostPrivilege postPrivilege);

    List<PrivilegeTreeBO> privilegeInitTree();

    List<PrivilegeTreeBO> postPrivilegeTree(Long postId);
}
