外卖项目day02-分类管理代码导入

This commit is contained in:
xx
2026-11-16 11:48:35 +08:00
parent 78b22f7cfa
commit 66a596e452
7 changed files with 420 additions and 0 deletions
@@ -0,0 +1,17 @@
package com.sky.mapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
@Mapper
public interface DishMapper {
/**
* 根据分类id查询菜品数量
* @param categoryId
* @return
*/
@Select("select count(id) from dish where category_id = #{categoryId}")
Integer countByCategoryId(Long categoryId);
}