Browse Source

fix 科目

he2802 3 years ago
parent
commit
fe98cccc0e

+ 2 - 2
zhongzheng-system/src/main/resources/mapper/modules/goods/GoodsMapper.xml

@@ -250,7 +250,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             AND (#{validityStartTime} BETWEEN g.validity_start_time and g.validity_end_time or #{validityEndTime} BETWEEN g.validity_start_time and g.validity_end_time)
         </if>
         <if test="subjectId != null and subjectId >0">
-            AND FIND_IN_SET(g.subject_ids, #{subjectId})
+            AND FIND_IN_SET(#{subjectId},g.subject_ids)
         </if>
         <if test="goodsType ==1 and haveCourse != null and haveCourse == 1">
             AND (SELECT count(*) from goods_course gc LEFT JOIN course c ON gc.course_id = c.course_id where gc.goods_id = g.goods_id and c.`status` = 1
@@ -358,7 +358,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             AND (#{validityStartTime} BETWEEN g.validity_start_time and g.validity_end_time or #{validityEndTime} BETWEEN g.validity_start_time and g.validity_end_time)
         </if>
         <if test="subjectId != null and subjectId >0">
-            AND FIND_IN_SET( g.subject_ids, #{subjectId} )
+            AND FIND_IN_SET(#{subjectId},g.subject_ids)
         </if>
         <if test="goodsType ==1 and haveCourse != null and haveCourse == 1">
             AND (SELECT count(*) from goods_course gc LEFT JOIN course c ON gc.course_id = c.course_id where gc.goods_id = g.goods_id and c.`status` = 1