Browse Source

Merge remote-tracking branch 'origin/dev' into pre

dzx 11 months ago
parent
commit
df12540def

+ 13 - 0
src/main/java/com/xjrsoft/module/ledger/controller/LedgerCustomController.java

@@ -1,6 +1,7 @@
 package com.xjrsoft.module.ledger.controller;
 
 import cn.dev33.satoken.annotation.SaCheckPermission;
+import cn.dev33.satoken.stp.StpUtil;
 import cn.hutool.db.Entity;
 import com.xjrsoft.common.model.result.RT;
 import com.xjrsoft.common.mybatis.SqlRunnerAdapter;
@@ -16,6 +17,10 @@ import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 
 import javax.validation.Valid;
+import java.time.LocalDateTime;
+import java.time.format.DateTimeFormatter;
+import java.util.Date;
+import java.util.Map;
 
 /**
 * @title: 台账自定义接口
@@ -40,6 +45,14 @@ public class LedgerCustomController {
         Entity where = Entity.create(dto.getTableName());
         where.set("id", dto.getId());
 
+        Map<String, Object> objectMap = SqlRunnerAdapter.db().dynamicSelectOne(dto.getTableName(), where);
+        if(objectMap.containsKey("modify_user_id")){
+            params.set("modify_user_id", StpUtil.getLoginIdAsLong());
+        }
+        if(objectMap.containsKey("modify_date")){
+            params.set("modify_date", LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss")));
+        }
+
         return RT.ok(SqlRunnerAdapter.db().dynamicUpdate(dto.getTableName(), params, where));
     }
 

+ 23 - 1
src/main/java/com/xjrsoft/module/room/controller/RoomBedAdjustController.java

@@ -17,6 +17,7 @@ import com.xjrsoft.module.room.service.IRoomBedService;
 import com.xjrsoft.module.room.vo.AdjustBedClassPageVo;
 import com.xjrsoft.module.room.vo.AdjustBedStudentPageVo;
 import com.xjrsoft.module.room.vo.NoBedStudentPageVo;
+import com.xjrsoft.module.room.vo.TeacherRoomListVo;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import lombok.AllArgsConstructor;
@@ -86,10 +87,11 @@ public class RoomBedAdjustController {
         List<BaseClass> classList = baseClassService.list(
                 new QueryWrapper<BaseClass>().lambda().eq(BaseClass::getTeacherId, teacherId)
         );
-        if(roleList.size() == 2 && roleList.contains("CLASSTE") && roleList.contains("TEACHER")){
+        if(roleList.size() == 2 && roleList.contains("CLASSTE") && roleList.contains("TEACHER") && dto.getRoomId() != null){
             if(classList != null && !classList.isEmpty()){
                 dto.setClassId(classList.get(0).getId());
             }
+            //dto.setIsTeacher(1);
         }
         List<AdjustBedStudentPageVo> result = roomBedService.getBedStudetInfo(dto);
         if (result == null) {
@@ -149,4 +151,24 @@ public class RoomBedAdjustController {
         Boolean result = roomBedService.adjustBedBatch(dto);
         return RT.ok(result);
     }
+
+    @GetMapping("/teacher-room-list")
+    @ApiOperation(value = "班主任查看寝室")
+    @SaCheckPermission("roomBedAdjust:edit")
+    public RT<List<TeacherRoomListVo>> roomList(@Valid AdjustBedPageDto dto){
+        List<String> roleList = StpUtil.getRoleList();
+
+        long teacherId = StpUtil.getLoginIdAsLong();
+        List<BaseClass> classList = baseClassService.list(
+                new QueryWrapper<BaseClass>().lambda().eq(BaseClass::getTeacherId, teacherId)
+        );
+        if(roleList.size() == 2 && roleList.contains("CLASSTE") && roleList.contains("TEACHER") && dto.getRoomId() != null){
+            if(classList != null && !classList.isEmpty()){
+                dto.setClassId(classList.get(0).getId());
+            }
+            //dto.setIsTeacher(1);
+        }
+        List<TeacherRoomListVo> teacherRoomList = roomBedService.getTeacherRoomList(dto);
+        return RT.ok(teacherRoomList);
+    }
 }

+ 3 - 0
src/main/java/com/xjrsoft/module/room/dto/AdjustBedPageDto.java

@@ -40,5 +40,8 @@ public class AdjustBedPageDto extends PageInput {
     @ApiModelProperty("寝室id")
     public Long roomId;
 
+    @ApiModelProperty("是否是班主任(1:是,0:否)")
+    public Integer isTeacher;
+
 
 }

+ 3 - 0
src/main/java/com/xjrsoft/module/room/mapper/RoomBedMapper.java

@@ -22,6 +22,7 @@ import com.xjrsoft.module.room.vo.RoomBedInfoVo;
 import com.xjrsoft.module.room.vo.RoomBedPageVo;
 import com.xjrsoft.module.room.vo.RoomBedVo;
 import com.xjrsoft.module.room.vo.StudentPayStatusVo;
+import com.xjrsoft.module.room.vo.TeacherRoomListVo;
 import org.apache.ibatis.annotations.Mapper;
 import org.apache.ibatis.annotations.Param;
 
@@ -146,4 +147,6 @@ public interface RoomBedMapper extends MPJBaseMapper<RoomBed> {
 
     String getRoomNameByStudentUserId(Long id);
 
+    List<TeacherRoomListVo> getTeacherRoomList(@Param("dto") AdjustBedPageDto dto);
+
 }

+ 4 - 0
src/main/java/com/xjrsoft/module/room/service/IRoomBedService.java

@@ -18,6 +18,8 @@ import com.xjrsoft.module.room.vo.DistributeRoomBedPageVo;
 import com.xjrsoft.module.room.vo.NoBedStudentPageVo;
 import com.xjrsoft.module.room.vo.RoomBedExcelVo;
 import com.xjrsoft.module.room.vo.RoomBedPageVo;
+import com.xjrsoft.module.room.vo.TeacherRoomListVo;
+import org.apache.ibatis.annotations.Param;
 
 import java.util.List;
 
@@ -109,4 +111,6 @@ public interface IRoomBedService extends MPJBaseService<RoomBed> {
 
 
     String getRoomNameByStudentUserId(Long id);
+
+    List<TeacherRoomListVo> getTeacherRoomList(AdjustBedPageDto dto);
 }

+ 6 - 0
src/main/java/com/xjrsoft/module/room/service/impl/RoomBedServiceImpl.java

@@ -43,6 +43,7 @@ import com.xjrsoft.module.room.vo.RoomBedPageVo;
 import com.xjrsoft.module.room.vo.RoomClassCountVo;
 import com.xjrsoft.module.room.vo.RoomClassExistentVo;
 import com.xjrsoft.module.room.vo.StudentPayStatusVo;
+import com.xjrsoft.module.room.vo.TeacherRoomListVo;
 import com.xjrsoft.module.student.entity.BaseStudent;
 import com.xjrsoft.module.student.entity.BaseStudentSchoolRoll;
 import com.xjrsoft.module.student.mapper.BaseStudentMapper;
@@ -674,4 +675,9 @@ public class RoomBedServiceImpl extends MPJBaseServiceImpl<RoomBedMapper, RoomBe
         return roomBedMapper.getRoomNameByStudentUserId(id);
     }
 
+    @Override
+    public List<TeacherRoomListVo> getTeacherRoomList(AdjustBedPageDto dto) {
+        return this.roomBedMapper.getTeacherRoomList(dto);
+    }
+
 }

+ 31 - 0
src/main/java/com/xjrsoft/module/room/vo/TeacherRoomListVo.java

@@ -0,0 +1,31 @@
+package com.xjrsoft.module.room.vo;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+/**
+* @title: 寝室床位表单出参
+* @Author dzx
+* @Date: 2023-12-27
+* @Version 1.0
+*/
+@Data
+public class TeacherRoomListVo {
+
+    /**
+    * 主键编号
+    */
+    @ApiModelProperty("寝室id")
+    private Long id;
+    /**
+    * 序号
+    */
+    @ApiModelProperty("寝室名称")
+    private String roomName;
+
+    @ApiModelProperty("楼栋名称")
+    private String buildName;
+
+
+
+}

+ 9 - 10
src/main/java/com/xjrsoft/module/student/service/impl/BaseStudentAssessmentInspectionServiceImpl.java

@@ -232,7 +232,7 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
         List<BaseStudentAssessmentCategory> baseStudentAssessmentCategorieList = categoryMapper.selectList(baseStudentAssessmentCategoryLambdaQueryWrapper);
 
         //导出子表
-        if(baseStudentAssessmentCategorieList.size() > 0){
+        if(!baseStudentAssessmentCategorieList.isEmpty()){
             //需要合并的列
             int[] mergeColumeIndex = {0, 1, 2, 3, 4};
             ExcelMergeUtil excelFillCellMergeStrategy = new ExcelMergeUtil(1, mergeColumeIndex);
@@ -268,7 +268,7 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
                         .eq(dto.getGradeId() != null, BaseClass::getGradeId, dto.getGradeId())
                         .eq(dto.getClassId() != null, BaseClass::getId, dto.getClassId())
                         .eq(dto.getClassStatus() != null, BaseClass::getIsGraduate, dto.getClassStatus())
-                        .like(dto.getName() != null && !dto.getName().equals(""), XjrUser::getName, dto.getName());
+                        .like(dto.getName() != null && !dto.getName().isEmpty(), XjrUser::getName, dto.getName());
 
                 List<CalssQuantitativeAssessmentPageVo> resultList = baseClassMapper.selectJoinList(CalssQuantitativeAssessmentPageVo.class, baseClassMPJLambdaWrapper);
 
@@ -423,7 +423,6 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
                             }
                         }
 
-
                         c.setAssessMoney(" ");
                         c.setAssessSumScore(" ");
                     }
@@ -475,7 +474,7 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
                 .eq(dto.getGradeId() != null, BaseClass::getGradeId, dto.getGradeId())
                 .eq(dto.getClassId() != null, BaseClass::getId, dto.getClassId())
                 .eq(dto.getClassStatus() != null, BaseClass::getIsGraduate, dto.getClassStatus())
-                .like(dto.getName() != null && !dto.getName().equals(""), XjrUser::getName, dto.getName());
+                .like(dto.getName() != null && !dto.getName().isEmpty(), XjrUser::getName, dto.getName());
 
         IPage<CalssQuantitativeAssessmentPageVo> resultPage = baseClassMapper.selectJoinPage(page, CalssQuantitativeAssessmentPageVo.class, baseClassMPJLambdaWrapper);
 
@@ -542,7 +541,7 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
             for(CalssQuantitativeAssessmentPageVo c: resultPage.getRecords()){
                 Long classId = Long.parseLong(c.getClassId());
                 //学生个人行为
-                if(individualBehaviorMap.get(classId) != null){
+                if(individualBehaviorMap.get(classId) != null && individualBehaviorMap.get(classId) != null){
                     Double sumScore = individualBehaviorMap.get(classId).getSumScore();
                     c.setStuPersonalBehaviorSubScore(sumScore==null?"":sumScore.toString());
                     String replacedExpression = xsgrFormula.replace("xsgrKouFen", Double.toString(sumScore));
@@ -556,7 +555,7 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
                     }
                 }
                 //常规管理
-                if(conventionalManagementMap.get(classId) != null){
+                if(conventionalManagementMap.get(classId) != null && conventionalManagementMap.get(classId) != null){
                     Double sumScore = conventionalManagementMap.get(classId).getSumScore();
                     if(sumScore != null){
                         String scoreStr = sumScore.toString();
@@ -574,7 +573,7 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
                     }
                 }
                 //获奖和荣誉
-                if(awardsAndHonorableMap.get(classId) != null){
+                if(awardsAndHonorableMap.get(classId) != null && awardsAndHonorableMap.get(classId) != null){
                     Double sumScore = awardsAndHonorableMap.get(classId).getSumScore();
                     if(sumScore != null){
                         c.setHonorSumScore(sumScore.toString());
@@ -591,8 +590,8 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
                     }
                 }
                 //军事化
-                if(paramilitaryMap.get(classId) != null){
-                    Double sumScore = awardsAndHonorableMap.get(classId).getSumScore();
+                if(paramilitaryMap.get(classId) != null && paramilitaryMap.get(classId) != null){
+                    Double sumScore = paramilitaryMap.get(classId).getSumScore();
                     if(sumScore != null){
                         c.setMilitaryManageComprehensiveIndex(sumScore.toString());
                         //此项得分
@@ -633,7 +632,7 @@ public class BaseStudentAssessmentInspectionServiceImpl extends MPJBaseServiceIm
                     }
                 }
                 //班级文化建设
-                if(classCultureMap.containsKey(classId)){
+                if(classCultureMap.containsKey(classId) && classCultureMap.get(classId) != null){
                     Double sumScore = classCultureMap.get(classId).getSumScore();
                     if(sumScore != null){
                         c.setClassCultureScore(sumScore.toString());

+ 10 - 2
src/main/java/com/xjrsoft/module/student/vo/BaseStudentAssessmentInspectionMobileVo.java

@@ -1,5 +1,7 @@
 package com.xjrsoft.module.student.vo;
 
+import com.baomidou.mybatisplus.annotation.FieldFill;
+import com.baomidou.mybatisplus.annotation.TableField;
 import com.xjrsoft.module.student.entity.BaseStudentAssessmentStudentRelation;
 import com.xjrsoft.module.system.entity.File;
 import io.swagger.annotations.ApiModelProperty;
@@ -112,8 +114,14 @@ public class BaseStudentAssessmentInspectionMobileVo {
     private List<File> fileInfos;
 
     @ApiModelProperty("类型")
-    private  String assessmentType;
+    private String assessmentType;
 
     @ApiModelProperty("考核项目")
-    private  String assessmentItemName;
+    private String assessmentItemName;
+
+    @ApiModelProperty("修改人")
+    private String modifyUserName;
+
+    @ApiModelProperty("修改时间")
+    private Date modifyDate;
 }

+ 1 - 1
src/main/java/com/xjrsoft/module/system/dto/AddMenuDto.java

@@ -46,7 +46,7 @@ public class AddMenuDto implements Serializable {
     private String iconUrl;
 
     @NotNull(message = "菜单地址不能为空!")
-    @Length(max = 100,message = "菜单地址不能大于100个字符!")
+    @Length(max = 500,message = "菜单地址不能大于500个字符!")
     @ApiModelProperty("地址")
     private String path;
 

+ 1 - 1
src/main/java/com/xjrsoft/module/system/dto/UpdateMenuDto.java

@@ -50,7 +50,7 @@ public class UpdateMenuDto implements Serializable {
     private String iconUrl;
 
     @NotNull(message = "菜单地址不能为空!")
-    @Length(max = 100,message = "菜单地址不能大于100个字符!")
+    @Length(max = 500,message = "菜单地址不能大于500个字符!")
     @ApiModelProperty("地址")
     private String path;
 

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

@@ -106,7 +106,7 @@
         SELECT COUNT(t1.id) FROM course_table t1
         INNER JOIN course_table_bak t2 ON t1.schedule_date = t2.schedule_date
         AND t1.time_number = t2.time_number
-        AND t1.time_period = t2.time_number
+        AND t1.time_period = t2.time_period
         WHERE t2.wf_course_adjust_id = #{dto.wfCourseAdjustId}
         AND t1.teacher_id LIKE concat('%', #{dto.teacherId},'%') AND t1.adjust_type IS NULL;
     </select>

+ 34 - 8
src/main/resources/mapper/room/RoomBedMapper.xml

@@ -337,10 +337,10 @@
         WHERE t1.delete_mark = 0 AND t2.delete_mark = 0
         <if test="dto.isEmptyRoom != null">
             <if test="dto.isEmptyRoom == 1">
-                and t2.bed_count = (SELECT COUNT(*) FROM room_bed WHERE delete_mark = 0 AND student_user_id IS NULL AND is_check_in = 0 AND room_id = t2.id)
+                and t2.bed_count = (SELECT COUNT(*) FROM room_bed WHERE delete_mark = 0 AND student_user_id IS NULL AND room_id = t2.id)
             </if>
             <if test="dto.isEmptyRoom == 0">
-                and t2.bed_count != (SELECT COUNT(*) FROM room_bed WHERE delete_mark = 0 AND student_user_id IS NULL AND is_check_in = 0 AND room_id = t2.id)
+                and t2.bed_count != (SELECT COUNT(*) FROM room_bed WHERE delete_mark = 0 AND student_user_id IS NULL AND room_id = t2.id)
             </if>
         </if>
         <if test="dto.roomName != null">
@@ -358,12 +358,16 @@
         <if test="dto.floorNumber != null">
             and t2.floor_number = #{dto.floorNumber}
         </if>
-        <if test="dto.classId != null">
-            AND t2.id IN (
-            SELECT DISTINCT c1.room_id FROM room_bed c1
-            INNER JOIN base_student_school_roll c2 ON c1.student_user_id = c2.user_id
-            WHERE c2.class_id = #{dto.classId}
-            )
+        <if test="dto.isTeacher != null">
+            <if test="dto.classId != null">
+                AND (t2.id IN (
+                SELECT DISTINCT c1.room_id FROM room_bed c1
+                INNER JOIN base_student_school_roll c2 ON c1.student_user_id = c2.user_id
+                WHERE c2.class_id = #{dto.classId}
+                ) or
+                t2.bed_count != (SELECT COUNT(*) FROM room_bed WHERE delete_mark = 0 AND student_user_id IS not NULL AND room_id = t2.id)
+                )
+            </if>
         </if>
         <if test="dto.buildId != null">
             and t3.id = #{dto.buildId}
@@ -425,4 +429,26 @@
         WHERE t1.delete_mark = 0 AND t1.delete_mark = 0
         AND t2.student_user_id = #{id}
     </select>
+
+    <select id="getTeacherRoomList" parameterType="com.xjrsoft.module.room.dto.AdjustBedPageDto" resultType="com.xjrsoft.module.room.vo.TeacherRoomListVo">
+        SELECT DISTINCT t2.id,t3.name as build_name,t2.room_name FROM room_bed t1
+        LEFT JOIN room t2 ON t1.room_id = t2.id
+        LEFT JOIN base_office_build t3 ON t2.office_build_id = t3.id
+        LEFT JOIN xjr_user t4 ON t1.student_user_id = t4.id
+        LEFT JOIN xjr_dictionary_detail t5 ON t2.gender = t5.code AND t5.item_id = 2023000000000000004
+        LEFT JOIN base_student_school_roll t7 ON t4.id = t7.user_id
+        LEFT JOIN base_class t8 ON t7.class_id = t8.id
+        LEFT JOIN base_grade t9 ON t7.grade_id = t9.id
+        LEFT JOIN xjr_user t10 ON t8.teacher_id = t10.id
+        WHERE t1.delete_mark = 0 AND t2.delete_mark = 0
+        <if test="dto.classId != null">
+            AND (t2.id IN (
+                SELECT DISTINCT c1.room_id FROM room_bed c1
+                INNER JOIN base_student_school_roll c2 ON c1.student_user_id = c2.user_id
+                WHERE c2.class_id = #{dto.classId}
+            ) OR
+                t2.bed_count != (SELECT COUNT(*) FROM room_bed WHERE delete_mark = 0 AND student_user_id IS not NULL AND room_id = t2.id)
+            )
+        </if>
+    </select>
 </mapper>

+ 10 - 8
src/main/resources/mapper/student/BaseStudentAssessmentInspectionMapper.xml

@@ -20,7 +20,7 @@
         LEFT JOIN xjr_user t5 ON t.assessment_user_id = t5.id
         LEFT JOIN xjr_dictionary_detail t6 ON t6.code= t.score_type
         LEFT JOIN base_class t7 ON t7.id = CAST(t.class_ids AS SIGNED)
-        WHERE  t.delete_mark = 0 AND t.delete_mark = 0  AND t2.delete_mark = 0
+        WHERE  t.delete_mark = 0 AND t.delete_mark = 0  AND t2.delete_mark = 0 and t.enabled_mark = 1
         <if test="dto.projectIds != null">
             and t.base_student_assessment_category_id = #{dto.projectIds}
         </if>
@@ -59,7 +59,7 @@
         left join xjr_user t5 on t.assessment_user_id=t5.id
         left join xjr_dictionary_detail t6 on t6.code=t.score_type
         left join xjr_user t7 on t.create_user_id=t7.id
-        where t.id = #{id} and t.delete_mark = 0 and t1.delete_mark = 0 and t2.delete_mark = 0
+        where t.id = #{id} and t.delete_mark = 0 and t1.delete_mark = 0 and t2.delete_mark = 0 and t.enabled_mark = 1
     </select>
 
     <select id="getMobilePage" parameterType="com.xjrsoft.module.student.dto.BaseStudentAssessmentInspectionMobilePageDto" resultType="com.xjrsoft.module.student.vo.BaseStudentAssessmentInspectionMobilePageVo">
@@ -80,7 +80,7 @@
         LEFT JOIN base_student_assessment_item t6 ON (t6.id = t1.base_student_assessment_item_id)
         LEFT JOIN xjr_dictionary_detail t4 ON t4.code=t1.score_type
         LEFT JOIN base_class t5 ON t5.id=t.class_id
-        WHERE t1.delete_mark = 0 and t.class_id in
+        WHERE t1.delete_mark = 0 and t1.enabled_mark = 1 and t.class_id in
         <foreach item="classId" index="index" collection="dto.classIds" open="(" close=")" separator=",">
             #{classId}
         </foreach>
@@ -100,7 +100,8 @@
 
     <select id="getMobileInfo" resultType="com.xjrsoft.module.student.vo.BaseStudentAssessmentInspectionMobileVo">
         select t.id,t.class_id,t.base_student_assessment_inspection_id,t1.score,t5.name as assessment_class_name,t2.name as assessment_category_name,t3.name as assessment_project_name,t1.assessment_date,t1.reason,
-        t6.name as assessment_user_name,t7.name as create_user_name,t1.create_date,t1.file_id,t1.score_type,t4.name as score_type_cn,t1.assessment_type,t8.name as assessment_item_name
+        t6.name as assessment_user_name,t7.name as create_user_name,t1.create_date,t1.file_id,t1.score_type,t4.name as score_type_cn,t1.assessment_type,
+        t8.name as assessment_item_name,t9.name as modify_user_name,t1.modify_date
         from base_student_assessment_class_relation t
         left join base_student_assessment_inspection t1 on t1.id=t.base_student_assessment_inspection_id
         left join base_student_assessment_category t2 on (t2.id = t1.base_student_assessment_category_id)
@@ -108,8 +109,9 @@
         left join base_student_assessment_item t8 on (t8.id = t1.base_student_assessment_item_id)
         left join xjr_dictionary_detail t4 on t4.code=t1.score_type
         left join base_class t5 on t5.id=t.class_id
-        left join xjr_user t6 on t1.assessment_user_id=t6.id
-        left join xjr_user t7 on t1.create_user_id=t7.id
+        left join xjr_user t6 on t1.assessment_user_id = t6.id
+        left join xjr_user t7 on t1.create_user_id = t7.id
+        left join xjr_user t9 on t1.modify_user_id = t9.id
         where t.id = #{id};
     </select>
 
@@ -232,7 +234,7 @@
         SUM(t.score * (LENGTH(personal_student_user_ids) - LENGTH(REPLACE(personal_student_user_ids, ',', '')) + 1)) AS sumScore
         from base_student_assessment_inspection t
         inner join base_student_assessment_category t1 on t1.id = t.base_student_assessment_category_id
-        where t.delete_mark = 0
+        where t.delete_mark = 0 and t.enabled_mark = 1
         <if test="dto.classIdList != null and !dto.classIdList.isEmpty()">
             and t.class_ids in
             <foreach item="classId" index="index" collection="dto.classIdList" open="(" close=")" separator=",">
@@ -264,7 +266,7 @@
         from base_student_assessment_class_relation t
                  left join base_student_assessment_inspection t1 on t1.id = t.base_student_assessment_inspection_id
                  left join base_student_assessment_category t2 on t2.id = t1.base_student_assessment_category_id
-        where t2.code = 'convention_manage'
+        where t2.code = 'convention_manage' and t1.enabled_mark = 1
           and t.class_id in
         <foreach item="classId" index="index" collection="dto.classIdList" open="(" close=")" separator=",">
             #{classId}