分类管理

This commit is contained in:
slhaf
2024-09-10 16:04:46 +08:00
parent d6471726b9
commit 241afd6478
4 changed files with 53 additions and 4 deletions

View File

@@ -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);
}