package com.dayou.service;
import com.dayou.bo.MenuTreeBO;
import com.dayou.bo.PrivilegeTreeBO;
import com.dayou.entity.Menu;
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.Collection;
import java.util.List;

/**
 * <p>
 * 菜单 服务类
 * </p>
 *
 * @author wucl
 * @since 2022-11-29
 */
public interface IMenuService extends IService<Menu> {

        Page<Menu> selectPage(Page page,Menu menu);

        Menu detail(Long id);

        Boolean add(Menu menu);

        Boolean update(Menu menu);

        Boolean delete(Long id);

        XSSFWorkbook generateImportTemplate();

        void importExcel(MultipartFile file);

        XSSFWorkbook exportExcel(Menu menu);

        Collection<PrivilegeTreeBO> syncMenu(Collection<PrivilegeTreeBO> collection);

        List<MenuTreeBO> menuTree();

        List<Menu> menuList();
}
