فهرست منبع

exists条件修改

wangliang 4 سال پیش
والد
کامیت
135a315357
1فایلهای تغییر یافته به همراه2 افزوده شده و 11 حذف شده
  1. 2 11
      themis-business/src/main/resources/mapper/TEExamReexamMapper.xml

+ 2 - 11
themis-business/src/main/resources/mapper/TEExamReexamMapper.xml

@@ -32,7 +32,7 @@
             <if test="userId != null and userId != ''">
                 and tbeiu.user_id = #{userId}
             </if>
-            and tbeiu.exam_id = tees.exam_id
+                and tbeiu.exam_id = tees.exam_id and tees.room_code = tbeiu.room_code
             )
             <if test="examId != null and examId != ''">
                 and tees.exam_id = #{examId}
@@ -127,9 +127,6 @@
             <if test="applyName != null and applyName !=''">
                 and tbu.name like CONCAT('%', #{applyName},'%')
             </if>
-            and tee.enable = 1
-            and teea.enable = 1
-            and tees.enable = 1
             and teer.status = 1
         </where>
         order by tees.room_code
@@ -159,9 +156,6 @@
             <if test="orgId != null and orgId != ''">
                 and tee.org_id = #{orgId}
             </if>
-            and tee.enable = 1
-            and teea.enable = 1
-            and tees.enable = 1
             and teer.status = 1
         </where>
     </select>
@@ -198,7 +192,7 @@
         tbu.id = teer.create_id
         left join t_b_user tbu1 on
         tbu1.id = teer.auditing_id
-        <where>
+        <where> 1 = 1
             <if test="userId != null and userId !=''">
                 and teer.auditing_id = #{userId}
             </if>
@@ -235,9 +229,6 @@
             <if test="applyName != null and applyName !=''">
                 and tbu.name like CONCAT('%', #{applyName},'%')
             </if>
-            and tee.enable = 1
-            and teea.enable = 1
-            and tees.enable = 1
             and (teer.status = 0 or teer.status = 2)
         </where>
         order by tees.room_code