Administrator
2 days ago de8c62ac93ee9a91c1f4c8ead69e36697346acd5
feat(ai): 添加产品热度状态筛选功能

- 在 AiProductMapper.xml 中增加 hotState 条件查询
- 新增 ApiProductPageDto 热度状态字段
- 支持按推荐状态筛选产品列表
- 完善接口文档注释信息
2 files modified
6 ■■■■■ changed files
src/main/java/cc/mrbird/febs/ai/req/product/ApiProductPageDto.java 3 ●●●●● patch | view | raw | blame | history
src/main/resources/mapper/modules/AiProductMapper.xml 3 ●●●●● patch | view | raw | blame | history
src/main/java/cc/mrbird/febs/ai/req/product/ApiProductPageDto.java
@@ -21,6 +21,9 @@
    @ApiModelProperty(value = "每页数量", example = "10")
    private Integer pageSize;
    @ApiModelProperty(value = "是否推荐到首页 1-推荐 0-不推荐", example = "1")
    private String hotState;
    @ApiModelProperty(value = "分类ID", example = "123")
    private String categoryId;
src/main/resources/mapper/modules/AiProductMapper.xml
@@ -15,6 +15,9 @@
                <if test="record.categoryId != null and record.categoryId != ''">
                    and a.product_category_id = #{record.categoryId}
                </if>
                <if test="record.hotState != null and record.hotState != ''">
                    and a.hot_state = #{record.hotState}
                </if>
                <if test="record.companyId != null and record.companyId != ''">
                    and a.company_id = #{record.companyId}
                </if>