苍穹外卖--菜品管理-删除功能实现
This commit is contained in:
@@ -12,4 +12,10 @@ public interface DishFlavorMapper {
|
||||
* @param flavors
|
||||
*/
|
||||
void insertBath(List<DishFlavor> flavors);
|
||||
|
||||
/**
|
||||
* 菜品口味的批量删除
|
||||
* @param ids
|
||||
*/
|
||||
void deleteBath(List<Long> ids);
|
||||
}
|
||||
|
||||
@@ -10,6 +10,8 @@ import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Options;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Mapper
|
||||
public interface DishMapper {
|
||||
|
||||
@@ -34,4 +36,18 @@ public interface DishMapper {
|
||||
* @return
|
||||
*/
|
||||
Page<DishVO> pageQuery(DishPageQueryDTO dto);
|
||||
|
||||
/**
|
||||
* 根据菜品id,查询菜品数据
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@Select("select * from dish where id = #{id}")
|
||||
Dish getById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除菜品
|
||||
* @param ids
|
||||
*/
|
||||
void deleteBath(List<Long> ids);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
package com.sky.mapper;
|
||||
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 菜品--套餐--中间表setmeal_dish
|
||||
*/
|
||||
@Mapper
|
||||
public interface SetmealDishMapper {
|
||||
|
||||
|
||||
/**
|
||||
* 根据多个菜品id,查询关联的套餐id
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
List<Long> getSetmealIdsByDishIds(List<Long> ids);
|
||||
}
|
||||
Reference in New Issue
Block a user