package com.bonus.canteen.core.menu.mapper;

import java.util.List;
import com.bonus.canteen.core.menu.domain.MenuCollectionDishes;
import org.apache.ibatis.annotations.Param;

/**
 * 菜品收藏Mapper接口
 * 
 * @author xsheng
 * @date 2025-04-20
 */
public interface MenuCollectionDishesMapper {
    /**
     * 查询菜品收藏
     * 
     * @param dishesId 菜品收藏主键
     * @return 菜品收藏
     */
    public MenuCollectionDishes selectMenuCollectionDishesById(Long dishesId);

    public int getCollectionCountByUserIdAndDishesId(@Param("userId") Long userId, @Param("dishesId") Long dishesId);

    /**
     * 查询菜品收藏列表
     * 
     * @param menuCollectionDishes 菜品收藏
     * @return 菜品收藏集合
     */
    public List<MenuCollectionDishes> selectMenuCollectionDishesList(MenuCollectionDishes menuCollectionDishes);

    /**
     * 新增菜品收藏
     * 
     * @param menuCollectionDishes 菜品收藏
     * @return 结果
     */
    public int insertMenuCollectionDishes(MenuCollectionDishes menuCollectionDishes);

    /**
     * 修改菜品收藏
     * 
     * @param menuCollectionDishes 菜品收藏
     * @return 结果
     */
    public int updateMenuCollectionDishes(MenuCollectionDishes menuCollectionDishes);

    /**
     * 删除菜品收藏
     * 
     * @param dishesId 菜品收藏主键
     * @return 结果
     */
    public int deleteMenuCollectionDishesById(String dishesId);

    /**
     * 批量删除菜品收藏
     * 
     * @param dishesIds 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteMenuCollectionDishesByIds(@Param("userId") Long userId, @Param("dishesIds") String[] dishesIds);
}
