package shop.alien.store.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import shop.alien.entity.store.SportsEquipmentFacility;
import shop.alien.entity.store.vo.SportsEquipmentFacilityCategoryVo;
import shop.alien.entity.store.vo.SportsEquipmentFacilityVo;

import java.util.List;

/**
 * 运动器材设施服务接口
 *
 * @author system
 * @since 2025-01-XX
 */
public interface SportsEquipmentFacilityService extends IService<SportsEquipmentFacility> {

    /**
     * 分页查询运动器材设施列表
     *
     * @param pageNum          页码
     * @param pageSize         页大小
     * @param storeId           门店ID
     * @param facilityCategory 设施分类
     * @return IPage<SportsEquipmentFacilityVo>
     */
    IPage<SportsEquipmentFacilityVo> getPageList(Integer pageNum, Integer pageSize, Integer storeId, Integer facilityCategory);

    /**
     * 查询运动器材设施列表
     *
     * @param storeId           门店ID
     * @param facilityCategory 设施分类
     * @return List<SportsEquipmentFacilityVo>
     */
    List<SportsEquipmentFacilityVo> getList(Integer storeId, Integer facilityCategory);

    /**
     * 根据ID查询详情
     *
     * @param id 主键ID
     * @return SportsEquipmentFacilityVo
     */
    SportsEquipmentFacilityVo getDetail(Integer id);

    /**
     * 新增运动器材设施
     *
     * @param facility 设施信息
     * @param imageList 图片列表
     * @return boolean
     */
    boolean saveFacility(SportsEquipmentFacility facility, List<String> imageList);

    /**
     * 修改运动器材设施
     *
     * @param facility 设施信息
     * @param imageList 图片列表
     * @return boolean
     */
    boolean updateFacility(SportsEquipmentFacility facility, List<String> imageList);

    /**
     * 删除运动器材设施
     *
     * @param id 主键ID
     * @return boolean
     */
    boolean deleteFacility(Integer id);

    /**
     * 查询指定店铺按分类汇总的设备信息
     * 包含每个分类的设备数量、图片列表和设备列表
     *
     * @param storeId 门店ID
     * @return List<SportsEquipmentFacilityCategoryVo>
     */
    List<SportsEquipmentFacilityCategoryVo> getCategorySummary(Integer storeId);

    SportsEquipmentFacilityVo getStoreDetail(Integer id);

    List<SportsEquipmentFacilityCategoryVo> getstoreCategorySummary(Integer storeId);
}

