Browse Source

课表查询调整

dzx 2 months ago
parent
commit
258098340d
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/main/resources/mapper/courseTable/CourseTable.xml

+ 2 - 1
src/main/resources/mapper/courseTable/CourseTable.xml

@@ -46,9 +46,10 @@
         </if>
     </select>
     <select id="getAdjustList" parameterType="com.xjrsoft.module.schedule.dto.CourseTableAdjustDto" resultType="com.xjrsoft.module.schedule.vo.CourseListVo">
-        SELECT t1.time_period,t1.time_number,t1.course_name,t2.name AS class_name,t3.name AS classroom_name,t1.id,t2.id as class_id FROM course_table t1
+        SELECT t1.time_period,t4.short_name as time_number,t1.course_name,t2.name AS class_name,t3.name AS classroom_name,t1.id,t2.id as class_id FROM course_table t1
         LEFT JOIN base_class t2 ON t1.class_id = t2.id
         LEFT JOIN base_classroom t3 ON t1.site_id = t3.id
+        left join class_time t4 on t1.time_number = t4.number and t1.time_period = t4.time_period
         WHERE t1.status = 1
         <if test="dto.adjustType != null and dto.adjustType == 'course_exchange'">
             AND t1.teacher_id = #{dto.teacherId}