소스 검색

BUG修复

wangliang 3 년 전
부모
커밋
e3fe173af1
1개의 변경된 파일7개의 추가작업 그리고 7개의 파일을 삭제
  1. 7 7
      distributed-print-business/src/main/resources/mapper/TCStatisticsMapper.xml

+ 7 - 7
distributed-print-business/src/main/resources/mapper/TCStatisticsMapper.xml

@@ -3,7 +3,7 @@
 <mapper namespace="com.qmth.distributed.print.business.mapper.TCStatisticsMapper">
 
     <select id="list" resultType="com.qmth.distributed.print.business.bean.dto.TCStatisticsDto">
-        select
+        select temp.* from(select
         t.id,
         t.collegeId,
         t.collegeName,
@@ -64,22 +64,22 @@
         join exam_print_plan epp on
         epp.id = tcs.print_plan_id
         where
-        epp.school_id = #{schoolId}) t
+        epp.school_id = #{schoolId}) t) temp
         <where>
             <if test="collegeId != null and collegeId != ''">
-                and t.collegeId = #{collegeId}
+                and temp.collegeId = #{collegeId}
             </if>
             <if test="teachingRoomId != null and teachingRoomId != ''">
-                and t.teachingRoomId = #{teachingRoomId}
+                and temp.teachingRoomId = #{teachingRoomId}
             </if>
             <if test="status != null and status != ''">
-                and t.status = #{status}
+                and temp.status = #{status}
             </if>
             <if test="courseName != null and courseName != ''">
-                and t.courseName like concat('%',#{courseName},'%')
+                and temp.courseName like concat('%',#{courseName},'%')
             </if>
             <if test="teacherName != null and teacherName != ''">
-                and t.teacherName like concat('%',#{teacherName},'%')
+                and temp.teacherName like concat('%',#{teacherName},'%')
             </if>
         </where>
     </select>