Administrator
3 days ago 4ae921dacc0f64e7a4fa09c0cdd28af7719aa347
src/main/resources/mapper/modules/AiProductCategoryMapper.xml
@@ -1,4 +1,19 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="cc.mrbird.febs.ai.mapper.AiProductCategoryMapper">
    <select id="selectPageListByQuery" resultType="cc.mrbird.febs.ai.res.productCategory.ApiProductCategoryVo">
        select
            a.id as id,
            a.name as name,
            a.back_img as backImg,
            a.icon_img as iconImg
        from ai_product_category a
        where
            a.state = 1
            <if test="record.parentId != null and record.parentId != ''">
                and a.parent_id = #{record.parentId}
            </if>
        order by a.sort asc
    </select>
</mapper>