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