Explorar el Código

fix deleteExamStudentsByStudentIds

deason hace 1 año
padre
commit
545e2001ae

+ 4 - 4
examcloud-core-examwork-service/src/main/java/cn/com/qmth/examcloud/core/examwork/service/impl/ExamStudentServiceImpl.java

@@ -81,16 +81,16 @@ public class ExamStudentServiceImpl implements ExamStudentService {
      * 是否开考
      *
      * @param examId
-     * @param StudentId
+     * @param studentId
      * @param courseId
      * @return
      * @author WANGWEI
      */
-    private boolean isStarted(Long examId, Long StudentId, Long courseId) {
+    private boolean isStarted(Long examId, Long studentId, Long courseId) {
         CheckExamIsStartedReq checkExamIsStartedReq = new CheckExamIsStartedReq();
         checkExamIsStartedReq.setExamId(examId);
         checkExamIsStartedReq.setCourseId(courseId);
-        checkExamIsStartedReq.setStudentId(StudentId);
+        checkExamIsStartedReq.setStudentId(studentId);
         CheckExamIsStartedResp checkExamIsStartedResp = examRecordCloudService
                 .checkExamIsStarted(checkExamIsStartedReq);
         return checkExamIsStartedResp.getIsStarted();
@@ -112,7 +112,7 @@ public class ExamStudentServiceImpl implements ExamStudentService {
 
         for (ExamStudentEntity examStudent : examStudents) {
             // 网考判断
-            if (isStarted(examStudent.getExamId(), null, null)) {
+            if (isStarted(examStudent.getExamId(), examStudent.getStudentId(), examStudent.getCourseId())) {
                 throw new StatusException("150112", examStudent.getName() + "已开始考试,不能删除");
             }