xiaofei 10 месяцев назад
Родитель
Сommit
80118d2c06
16 измененных файлов с 52 добавлено и 248 удалено
  1. 11 0
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/backup/MySQLDatabaseBackup.java
  2. 0 9
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/mapper/ExamStudentMapper.java
  3. 0 15
      distributed-print-business/src/main/resources/mapper/ClientStatusMapper.xml
  4. 0 31
      distributed-print-business/src/main/resources/mapper/ExamCardMapper.xml
  5. 8 6
      distributed-print-business/src/main/resources/mapper/ExamDetailCourseMapper.xml
  6. 4 2
      distributed-print-business/src/main/resources/mapper/ExamDetailMapper.xml
  7. 1 1
      distributed-print-business/src/main/resources/mapper/ExamPrintPlanMapper.xml
  8. 0 77
      distributed-print-business/src/main/resources/mapper/ExamStudentMapper.xml
  9. 6 8
      distributed-print-business/src/main/resources/mapper/ExamTaskDetailMapper.xml
  10. 12 17
      distributed-print-business/src/main/resources/mapper/ExamTaskMapper.xml
  11. 2 3
      distributed-print-business/src/main/resources/mapper/ExamTaskTempMapper.xml
  12. 5 3
      distributed-print/src/main/java/com/qmth/distributed/print/api/SysAdminSetController.java
  13. 0 8
      distributed-print/src/test/java/com/qmth/distributed/print/ServiceTest.java
  14. 0 19
      teachcloud-common/src/main/java/com/qmth/teachcloud/common/mapper/BasicCourseMapper.java
  15. 1 1
      teachcloud-common/src/main/java/com/qmth/teachcloud/common/service/impl/SysPrivilegeServiceImpl.java
  16. 2 48
      teachcloud-common/src/main/resources/mapper/BasicCourseMapper.xml

+ 11 - 0
distributed-print-business/src/main/java/com/qmth/distributed/print/business/backup/MySQLDatabaseBackup.java

@@ -21,6 +21,7 @@ import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Value;
+import org.springframework.scheduling.annotation.Async;
 import org.springframework.stereotype.Component;
 import org.springframework.util.CollectionUtils;
 
@@ -76,6 +77,16 @@ public class MySQLDatabaseBackup {
     @Resource
     DictionaryConfig dictionaryConfig;
 
+    @Async
+    public void backupAndDeleteData(Long schoolId) {
+        try {
+            this.exportDatabaseTool();
+            this.deleteDbTool(SystemConstant.PRINT_DELETE_DATA_FILE_NAME, schoolId);
+        } catch (Exception e) {
+            throw ExceptionResultEnum.ERROR.exception("清除数据失败" + e.getMessage());
+        }
+    }
+
     /**
      * Java代码实现MySQL数据库导出
      *

+ 0 - 9
distributed-print-business/src/main/java/com/qmth/distributed/print/business/mapper/ExamStudentMapper.java

@@ -24,15 +24,6 @@ public interface ExamStudentMapper extends BaseMapper<ExamStudent> {
     @SuppressWarnings("MybatisXMapperMethodInspection")
     Map<String, Object> getStudentDetail(Long id);
 
-    /**
-     * 根据班级id查询考生,班级可以是教学班或行政班(两表查)
-     *
-     * @param schoolId 学校id
-     * @param classId  班级id
-     * @return 考生查询结果
-     */
-    List<ExamStudent> listExamStudentBySchoolIdAndClazzId(@Param("schoolId") Long schoolId, @Param("classId") String classId);
-
 
     List<ExamStudentCourseClassDto> listMarkStudentInfo(@Param("examId") Long examId, @Param("paperNumber") String paperNumber, @Param("paperType") String paperType);
 

+ 0 - 15
distributed-print-business/src/main/resources/mapper/ClientStatusMapper.xml

@@ -1,19 +1,4 @@
 <?xml version="1.0" encoding="UTF-8" ?>
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
 <mapper namespace="com.qmth.distributed.print.business.mapper.ClientStatusMapper">
-    <!-- 通用查询映射结果 -->
-    <resultMap id="BaseResultMap" type="com.qmth.distributed.print.business.entity.ClientStatus">
-        <result column="id" property="id"/>
-        <result column="school_id" property="schoolId"/>
-        <result column="machine_code" property="machineCode"/>
-        <result column="course_code" property="courseCode"/>
-        <result column="course_name" property="courseName"/>
-        <result column="paper_number" property="paperNumber"/>
-        <result column="try_time" property="tryTime"/>
-        <result column="create_id" property="createId"/>
-        <result column="create_time" property="createTime"/>
-        <result column="update_id" property="updateId"/>
-        <result column="update_time" property="updateTime"/>
-    </resultMap>
-
 </mapper>

+ 0 - 31
distributed-print-business/src/main/resources/mapper/ExamCardMapper.xml

@@ -2,37 +2,6 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.qmth.distributed.print.business.mapper.ExamCardMapper">
 
-    <!-- 通用查询映射结果 -->
-    <resultMap id="BaseResultMap" type="com.qmth.distributed.print.business.entity.ExamCard">
-        <result column="id" property="id"/>
-        <result column="school_id" property="schoolId"/>
-        <result column="org_id" property="orgId"/>
-        <result column="course_code" property="courseCode"/>
-        <result column="course_name" property="courseName"/>
-        <result column="title" property="title"/>
-        <result column="make_method" property="makeMethod"/>
-        <result column="status" property="status"/>
-        <result column="create_id" property="createId"/>
-        <result column="create_time" property="createTime"/>
-        <result column="update_id" property="updateId"/>
-        <result column="update_time" property="updateTime"/>
-        <result column="type" property="type"/>
-        <result column="create_method" property="createMethod"/>
-        <result column="attachment_id" property="attachmentId"/>
-        <result column="content" property="content"/>
-        <result column="html_content" property="htmlContent"/>
-        <result column="backup_attachment" property="backupAttachment"/>
-        <result column="jpg_attachment" property="jpgAttachment"/>
-        <result column="enable" property="enable"/>
-        <result column="used" property="used"/>
-        <result column="remark" property="remark"/>
-        <result column="card_rule_id" property="cardRuleId"/>
-    </resultMap>
-
-    <!-- 通用查询结果列 -->
-    <sql id="Base_Column_List">
-       select id, school_id,org_id, course_code, course_name, title, make_method, status, type, create_method, content,html_content, backup_attachment, jpg_attachment,attachment_id, enable, used, remark, card_rule_id, create_id, create_time, update_id, update_time from exam_card
-    </sql>
     <select id="listGenericCard" resultType="com.qmth.distributed.print.business.entity.ExamCard">
         SELECT
             distinct a.id, a.title, a.type, a.make_method makeMethod, a.create_method createMethod

+ 8 - 6
distributed-print-business/src/main/resources/mapper/ExamDetailCourseMapper.xml

@@ -7,6 +7,7 @@
     <result column="id" property="id" />
         <result column="school_id" property="schoolId" />
         <result column="exam_detail_id" property="examDetailId" />
+        <result column="course_id" property="courseId" />
         <result column="course_code" property="courseCode" />
         <result column="course_name" property="courseName" />
         <result column="paper_number" property="paperNumber" />
@@ -14,8 +15,7 @@
 
     <!-- 通用查询结果列 -->
     <sql id="Base_Column_List">
-        id,
-        school_id, exam_detail_id, course_code, course_name, paper_number
+        id, school_id, exam_detail_id, course_id, course_code, course_name, paper_number
     </sql>
     <select id="listClientByExamDetailIdAndStatus" resultType="java.util.Map">
         SELECT
@@ -23,8 +23,8 @@
             ed.school_id schoolId,
             b.exam_id examId,
             a.id examDetailCourseId,
-            a.course_code courseCode,
-            a.course_name courseName,
+            bc.code courseCode,
+            bc.name courseName,
             a.paper_number paperNumber,
             c.paper_attachment_ids paperAttachmentIds,
             a.attachment_id cardAttachmentIds,
@@ -41,12 +41,14 @@
                 LEFT JOIN
             exam_task b ON a.school_id = b.school_id
                 AND ed.exam_id = b.exam_id
-                AND a.course_code = b.course_code
+                AND a.course_id = b.course_id
                 AND a.paper_number = b.paper_number
                 LEFT JOIN
             exam_task_detail c ON b.id = c.exam_task_id
                 LEFT JOIN
             t_f_flow_approve d ON b.flow_id = d.flow_id
+                LEFT JOIN
+            basic_course bc ON b.course_id = bc.id
         WHERE
             a.exam_detail_id = #{examDetailId}
             AND (b.status = 'SUBMIT' and (d.status is null or d.status = #{status}))
@@ -61,7 +63,7 @@
                 LEFT JOIN
             exam_task b ON a.school_id = b.school_id
                 AND ed.exam_id = b.exam_id
-                AND a.course_code = b.course_code
+                AND a.course_id = b.course_id
                 AND a.paper_number = b.paper_number
                 LEFT JOIN
             t_f_flow_approve c ON b.flow_id = c.flow_id

+ 4 - 2
distributed-print-business/src/main/resources/mapper/ExamDetailMapper.xml

@@ -526,8 +526,8 @@
     </select>
     <select id="listStudentByExamDetailCourseId" resultType="java.util.Map">
         SELECT
-            b.course_code courseCode,
-            b.course_name courseName,
+            bc.code courseCode,
+            bc.name courseName,
             b.paper_number paperNumber,
             c.student_name studentName,
             c.student_code studentCode,
@@ -539,6 +539,8 @@
             exam_detail_course b ON a.id = b.exam_detail_id
                 JOIN
             exam_student c ON b.id = c.exam_detail_course_id
+                LEFT JOIN
+            basic_course bc ON b.course_id = bc.id
         WHERE
             b.id = #{examDetailCourseId}
         <if test="type == 'ONE'">

+ 1 - 1
distributed-print-business/src/main/resources/mapper/ExamPrintPlanMapper.xml

@@ -42,7 +42,7 @@
             (
             SELECT
                 COUNT(
-                DISTINCT ( course_code ))
+                DISTINCT ( course_id ))
                 FROM
                 exam_detail_course
             WHERE

+ 0 - 77
distributed-print-business/src/main/resources/mapper/ExamStudentMapper.xml

@@ -56,83 +56,6 @@
         WHERE a.id = #{id}
     </select>
 
-    <select id="listExamStudentBySchoolIdAndClazzId"
-            resultType="com.qmth.distributed.print.business.entity.ExamStudent">
-        SELECT
-        *
-        FROM
-        (SELECT
-        bs.school_id AS schoolId,
-        bs.student_code AS studentCode,
-        bs.student_name AS studentName,
-        bs.clazz_id AS clazzId,
-        bc.clazz_name AS clazzName,
-        FROM
-        basic_student bs
-        INNER JOIN basic_clazz bc ON bs.clazz_id = bc.id
-        <where>
-            <if test="schoolId != null and schoolId != ''">
-                AND bs.school_id = #{schoolId}
-            </if>
-            <if test="classId != null and classId != ''">
-                AND bc.id = #{classId}
-            </if>
-        </where>
-        UNION
-        SELECT
-        ts.school_id AS schoolId,
-        bs.student_code AS studentCode,
-        bs.student_name AS studentName,
-        ts.teach_clazz_id AS clazzId,
-        tc.teach_clazz_name AS clazzName,
-        FROM
-        teach_student ts
-        join basic_student bs on ts.student_id = bs.id
-        INNER JOIN teach_clazz tc ON ts.teach_clazz_id = tc.id
-        <where>
-            <if test="schoolId != null and schoolId != ''">
-                AND ts.school_id = #{schoolId}
-            </if>
-            <if test="classId != null and classId != ''">
-                AND tc.id = #{classId}
-            </if>
-        </where>
-        ) t0;
-    </select>
-    <select id="listExamStudentByPaperNumberAndPaperType"
-            resultType="com.qmth.distributed.print.business.bean.dto.ExamStudentCourseClassDto">
-        SELECT
-            a.course_code courseCode,
-            a.course_name courseName,
-            a.paper_number paperNumber,
-            a.paper_type paperType,
-            a.clazz_name clazzName,
-            b.teacher_name teacherName,
-            b.teacher_number teacherNumber
-        FROM
-            (SELECT DISTINCT
-                 ms.course_code,
-                 ms.course_name,
-                 ms.paper_number,
-                 ms.paper_type,
-                 ms.class_name as clazz_name
-             FROM
-                 mark_student ms
-             WHERE
-                 ms.exam_id = #{examId}
-               AND ms.paper_number = #{paperNumber}
-               AND ms.paper_type = #{paperType}) a
-                LEFT JOIN
-            (SELECT
-                 *
-             FROM
-                 grade_batch_student_clazz
-             WHERE
-                 batch_id = #{batchId}) b ON a.course_code = b.course_code
-                AND a.paper_number = b.paper_number
-                AND a.paper_type = b.paper_type
-                AND a.clazz_name = b.clazz_name
-    </select>
     <select id="listByExamDetailCourseIdNotIntMarkStudent" resultType="com.qmth.distributed.print.business.entity.ExamStudent">
         SELECT
             es.*,

+ 6 - 8
distributed-print-business/src/main/resources/mapper/ExamTaskDetailMapper.xml

@@ -89,7 +89,7 @@
                 </if>
             </if>
         </where>
-        GROUP BY a.school_id , a.exam_id, a.exam_name, a.print_plan_id, a.semester_id, a.semester_name, b.paper_number , b.course_code , b.course_name , b.paper_type) a
+        GROUP BY a.school_id , a.exam_id, a.exam_name, a.print_plan_id, a.semester_id, a.semester_name, b.paper_number , b.paper_type) a
             LEFT JOIN
         exam_task c ON a.school_id = c.school_id
             AND a.exam_id = c.exam_id
@@ -167,16 +167,14 @@
             etd.*,
             bs.name as semesterName,
             be.name as examName,
-            GROUP_CONCAT(CONCAT(et.course_name, '(', et.course_code, ')')) as courseNameCode,
+            GROUP_CONCAT(CONCAT(bc.name, '(', bc.code, ')')) as courseNameCode,
             GROUP_CONCAT(et.paper_number) paperNumber
         from
             exam_task_detail etd
-                join exam_task et on
-                et.id = etd.exam_task_id
-                join basic_exam be on
-                be.id = et.exam_id
-                join basic_semester bs on
-                bs.id = be.semester_id
+                join exam_task et on et.id = etd.exam_task_id
+                join basic_exam be on be.id = et.exam_id
+                join basic_semester bs on bs.id = be.semester_id
+                join basic_course bc on et.course_id = bc.id
         <where>
             <if test="examTaskId != null and examTaskId != ''">
                 etd.exam_task_id = #{examTaskId}

+ 12 - 17
distributed-print-business/src/main/resources/mapper/ExamTaskMapper.xml

@@ -6,6 +6,7 @@
     <resultMap id="BaseResultMap" type="com.qmth.distributed.print.business.entity.ExamTask">
         <result column="id" property="id"/>
         <result column="school_id" property="schoolId"/>
+        <result column="course_id" property="courseId"/>
         <result column="course_code" property="courseCode"/>
         <result column="course_name" property="courseName"/>
         <result column="paper_number" property="paperNumber"/>
@@ -1141,8 +1142,8 @@
               et.id,
               et.school_id schoolId,
               et.org_id as orgId,
-              et.course_code courseCode,
-              et.course_name courseName,
+              bc.code courseCode,
+              bc.name courseName,
               et.specialty,
               et.paper_number paperNumber,
               et.card_rule_id cardRuleId,
@@ -1173,20 +1174,14 @@
               et.exam_id as examId
           from
               ACT_RU_TASK art
-                  left join t_f_flow_join tffj on
-                  tffj.flow_id = art.PROC_INST_ID_
-                  left join exam_task et on
-                  et.id = tffj.object_id
-                  left join basic_card_rule b ON
-                  et.card_rule_id = b.id
-                  left join t_f_flow_approve tffa on
-                  tffa.school_id = et.school_id and tffa.flow_id = et.flow_id
-                  left join sys_user c ON
-                  art.ASSIGNEE_ = c.id
-                  LEFT JOIN sys_user d ON
-                  et.user_id= d.id
-                  LEFT JOIN
-                  sys_org so ON et.teaching_room_id = so.id
+                  left join t_f_flow_join tffj on tffj.flow_id = art.PROC_INST_ID_
+                  left join exam_task et on et.id = tffj.object_id
+                  left join basic_card_rule b ON et.card_rule_id = b.id
+                  left join t_f_flow_approve tffa on tffa.school_id = et.school_id and tffa.flow_id = et.flow_id
+                  left join sys_user c ON art.ASSIGNEE_ = c.id
+                  LEFT JOIN sys_user d ON et.user_id= d.id
+                  LEFT JOIN sys_org so ON et.teaching_room_id = so.id
+                  LEFT JOIN basic_course bc ON et.course_id = bc.id
           <where>
               et.enable = true
               <if test="flowId != null and flowId != ''">
@@ -1279,7 +1274,7 @@
             ed.id,
             ed.print_plan_id,
             ed.exam_id,
-            edc.course_code,
+            edc.course_id,
             edc.paper_number,
             ed.total_subjects,
             ed.backup_count,

+ 2 - 3
distributed-print-business/src/main/resources/mapper/ExamTaskTempMapper.xml

@@ -7,18 +7,17 @@
     <result column="id" property="id" />
         <result column="school_id" property="schoolId" />
         <result column="batch_no" property="batchNo" />
+        <result column="course_id" property="courseId" />
         <result column="course_code" property="courseCode" />
         <result column="course_name" property="courseName" />
         <result column="paper_number" property="paperNumber" />
-        <result column="specialty" property="specialty" />
         <result column="create_id" property="createId" />
         <result column="create_time" property="createTime" />
     </resultMap>
 
     <!-- 通用查询结果列 -->
     <sql id="Base_Column_List">
-        id,
-        school_id, batch_no, course_code, course_name, paper_number, specialty, create_id, create_time
+        id,school_id, batch_no,course_id, course_code, course_name, paper_number, specialty, create_id, create_time
     </sql>
 
 </mapper>

+ 5 - 3
distributed-print/src/main/java/com/qmth/distributed/print/api/SysAdminSetController.java

@@ -81,9 +81,8 @@ public class SysAdminSetController {
     @ApiResponses({@ApiResponse(code = 200, message = "数据还原信息", response = ResultUtil.class)})
     @RequestMapping(value = "/backup", method = RequestMethod.POST)
     @OperationLogDetail(operationType = OperationTypeEnum.UPDATE)
-    public Result sysadminBackup(@ApiParam(value = "学校id ", required = true) @RequestParam Long schoolId) throws Exception {
-        mySQLDatabaseBackup.exportDatabaseTool();
-        mySQLDatabaseBackup.deleteDbTool(SystemConstant.PRINT_DELETE_DATA_FILE_NAME, schoolId);
+    public Result sysadminBackup(@ApiParam(value = "学校ID", required = true) @RequestParam Long schoolId) {
+        mySQLDatabaseBackup.backupAndDeleteData(schoolId);
         return ResultUtil.ok(true);
     }
 
@@ -337,6 +336,9 @@ public class SysAdminSetController {
             commonCacheService.updateUserMenuCache(Long.valueOf(userId));
             commonCacheService.updateUserAuthCache(Long.valueOf(userId));
         }
+
+        // 更新自定义菜单
+        sysPrivilegeService.updateCustomList();
         return ResultUtil.ok(true);
     }
 

+ 0 - 8
distributed-print/src/test/java/com/qmth/distributed/print/ServiceTest.java

@@ -148,14 +148,6 @@ public class ServiceTest {
         System.out.println(var);
     }
 
-    @Test
-    public void findExamStudent() {
-        Long schoolId = 2L;
-        String clazzId = "225944699725156352";
-        List<ExamStudent> examStudentList = examStudentMapper.listExamStudentBySchoolIdAndClazzId(schoolId, clazzId);
-        System.out.println(JSON.toJSONString(examStudentList));
-    }
-
     @Test
     public void testFindExamObject() throws Exception {
     }

+ 0 - 19
teachcloud-common/src/main/java/com/qmth/teachcloud/common/mapper/BasicCourseMapper.java

@@ -45,9 +45,6 @@ public interface BasicCourseMapper extends BaseMapper<BasicCourse> {
             @Param("courseCodeOrName") String courseCodeOrName, @Param("startCreateTime") Long startCreateTime, @Param("endCreateTime") Long endCreateTime,
             @Param("schoolId") Long schoolId, @Param("dpr") DataPermissionRule dpr);
 
-    @SuppressWarnings("MybatisXMapperMethodInspection")
-    Set<Map<String, Object>> findExamTaskByCourseCode(@Param("schoolId") Long schoolId, @Param("courseCodeSet") Set<String> courseCodeSet);
-
     List<BasicCourseExportDto> listExportData(@Param("belongOrgId") Long belongOrgId, @Param("courseName") String courseName, @Param("startCreateTime") Long startCreateTime,
             @Param("endCreateTime") Long endCreateTime, @Param("schoolId") Long schoolId, @Param("dpr") DataPermissionRule dpr);
     /**
@@ -59,22 +56,6 @@ public interface BasicCourseMapper extends BaseMapper<BasicCourse> {
      */
     List<String> findOccupiedCourseCode(@Param("examId") Long examId, @Param("userId") Long userId);
 
-    /**
-     * 查询考生字典中的课程名集合
-     *
-     * @param courseCodeSet 课程编号集合
-     * @return 课程名集合
-     */
-    List<String> findBasicExamStudentCourseName(@Param("schoolId") Long schoolId, @Param("courseCodeSet") Set<String> courseCodeSet);
-
-    /**
-     * 查询教学课程中的课程名集合
-     *
-     * @param courseCodeSet 课程编号集合
-     * @return 课程名集合
-     */
-    List<String> findTeachCourseCourseName(@Param("schoolId") Long schoolId, @Param("courseCodeSet") Set<String> courseCodeSet);
-
     int countBasicExamStudentByCourseId(Long courseId);
 
     int countExamTaskByCourseId(Long courseId);

+ 1 - 1
teachcloud-common/src/main/java/com/qmth/teachcloud/common/service/impl/SysPrivilegeServiceImpl.java

@@ -333,7 +333,7 @@ public class SysPrivilegeServiceImpl extends ServiceImpl<SysPrivilegeMapper, Sys
      * @return
      */
     @Override
-//    @Cacheable(value = SystemConstant.CUSTOM_PRIVILEGE_CACHE, unless = "#result == null")
+    @Cacheable(value = SystemConstant.CUSTOM_PRIVILEGE_CACHE, unless = "#result == null")
     public List<PrivilegeDto> addCustomList() {
         return this.commonCustomList();
     }

+ 2 - 48
teachcloud-common/src/main/resources/mapper/BasicCourseMapper.xml

@@ -100,22 +100,6 @@
         ORDER BY createTime DESC
     </select>
 
-    <select id="findExamTaskByCourseCode" resultType="java.util.Map">
-        SELECT
-        course_code AS courseCode, course_name AS courseName
-        FROM
-        exam_task
-        <where>
-            AND school_id = #{schoolId}
-            <if test="courseCodeSet != null and courseCodeSet != '' and courseCodeSet.size > 0">
-                AND course_code IN
-                <foreach collection="courseCodeSet" item="item" index="index" open="(" separator="," close=")">
-                    #{item}
-                </foreach>
-            </if>
-        </where>
-        GROUP BY course_code,course_name
-    </select>
     <select id="listExportData" resultType="com.qmth.teachcloud.common.bean.dto.BasicCourseExportDto">
         SELECT
         bc.id,
@@ -163,9 +147,9 @@
     </select>
     <select id="findOccupiedCourseCode" resultType="java.lang.String">
         SELECT
-            course_code
+            bc.code
         FROM
-            teach_course
+            teach_course tc join basic_course bc on tc.course_id = bc.id
         <where>
             <if test="examId != null">
                 AND exam_id = #{examId}
@@ -175,36 +159,6 @@
             </if>
         </where>
     </select>
-    <select id="findBasicExamStudentCourseName" resultType="java.lang.String">
-        SELECT DISTINCT
-            (course_code)
-        FROM
-            basic_exam_student
-        <where>
-            AND school_id = #{schoolId}
-            <if test="courseCodeSet != null and courseCodeSet != '' and courseCodeSet.size > 0">
-                AND course_code IN
-                <foreach collection="courseCodeSet" item="item" index="index" open="(" separator="," close=")">
-                    #{item}
-                </foreach>
-            </if>
-        </where>
-    </select>
-    <select id="findTeachCourseCourseName" resultType="java.lang.String">
-        SELECT DISTINCT
-            (course_code)
-        FROM
-            teach_course
-        <where>
-            AND school_id = #{schoolId}
-            <if test="courseCodeSet != null and courseCodeSet != '' and courseCodeSet.size > 0">
-                AND course_code IN
-                <foreach collection="courseCodeSet" item="item" index="index" open="(" separator="," close=")">
-                    #{item}
-                </foreach>
-            </if>
-        </where>
-    </select>
     <select id="countBasicExamStudentByCourseId" resultType="java.lang.Integer">
         select count(1) from basic_exam_student where course_id = #{courseId}
     </select>