方式一:每个dao层的mapper,都需要一个@Mapper注解配置
@Mapper
public interface CategoryMapper {
@Select("select * from mall_category where id = #{id}")
Category findById(@Param("id") Integer id);
方式一:每个dao层的mapper,都需要一个@Mapper注解配置
@Mapper
public interface CategoryMapper {
@Select("select * from mall_category where id = #{id}")
Category findById(@Param("id") Integer id);