he2802 3 лет назад
Родитель
Сommit
0c9fc9d372

+ 10 - 0
zhongzheng-system/src/main/resources/mapper/modules/exam/ExamApplyMapper.xml

@@ -108,9 +108,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <if test="projectId != null and projectId != ''">
             and g.project_id = #{projectId}
         </if>
+        <if test="subjectId != null and subjectId >0">
+            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
+            AND c.subject_id = #{subjectId}) >0
+        </if>
         <if test="goodsType != null and goodsType != ''">
             and g.goods_type = #{goodsType}
         </if>
+        <if test="searchKey != null and searchKey != ''">
+            and (g.goods_name like concat('%', #{searchKey}, '%'))
+        </if>
+        <if test="standPrice != null and standPrice != ''">
+            AND g.stand_price = #{standPrice}
+        </if>
         order by g.create_time desc
     </select>