Ver Fonte

BUG修复

wangliang há 3 anos atrás
pai
commit
e3fe173af1

+ 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>