eight
2024-12-18 72e3d6bb6c90d4d917d27f3cc26346aece060caa
设备管理: 查询完善
已修改1个文件
21 ■■■■■ 文件已修改
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/devmanage/DevModelMapper.java 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/mysql/devmanage/DevModelMapper.java
@@ -28,10 +28,27 @@
                .orderByDesc(DevModelDO::getId));
    }
    @Select("select distinct brand from lihu.device_model where category=#{category}")
    @Select("<script> " +
            " select distinct brand from lihu.device_model " +
            " <where> deleted = 0 " +
            "   <if test=\"category != null and category != ''\"> " +
            "     and category = #{category} " +
            "   </if> " +
            " </where> " +
            "</script>")
    List<String> getBrandByCategory(@Param("category") String category);
    @Select("select model from lihu.device_model where category=#{category} and brand=#{brand}")
    @Select("<script> " +
            " select distinct brand from lihu.device_model " +
            " <where> deleted = 0 " +
            "   <if test=\"category != null and category != ''\"> " +
            "     and category = #{category} " +
            "   </if> " +
            "   <if test=\"brand != null and brand != ''\"> " +
            "     and brand = #{brand} " +
            "   </if> " +
            " </where> " +
            "</script>")
    List<String> getModelByCategoryBrand(@Param("category") String category, @Param("brand") String brand);
}