diff --git a/web/src/main/java/com/ibeetl/jlw/service/StudentHandsOnTaskReportService.java b/web/src/main/java/com/ibeetl/jlw/service/StudentHandsOnTaskReportService.java index cf2814a1..53b910eb 100644 --- a/web/src/main/java/com/ibeetl/jlw/service/StudentHandsOnTaskReportService.java +++ b/web/src/main/java/com/ibeetl/jlw/service/StudentHandsOnTaskReportService.java @@ -106,7 +106,7 @@ public class StudentHandsOnTaskReportService extends CoreBaseService<StudentHand return JsonResult.fail(""); } Student student = studentService.getByUserId(coreUser.getId()); - studentHandsOnTaskReportQuery.setStudentId(student.getId()); + studentHandsOnTaskReportQuery.setStudentId(student.getStudentId()); String msg = ""; StudentHandsOnTaskReport studentHandsOnTaskReport = studentHandsOnTaskReportQuery.pojo(); @@ -115,12 +115,12 @@ public class StudentHandsOnTaskReportService extends CoreBaseService<StudentHand return JsonResult.success(); } StudentHandsOnTaskReport studentHandsOnTaskReport1 = this.sqlManager.lambdaQuery(StudentHandsOnTaskReport.class) - .andEq(StudentHandsOnTaskReport::getHandsOnTaskId, handsOnTaskId).singleSimple(); + .andEq(StudentHandsOnTaskReport::getHandsOnTaskId, handsOnTaskId).andEq(StudentHandsOnTaskReport::getStudentId, student.getStudentId()).singleSimple(); if (studentHandsOnTaskReport1 != null) { BigDecimal reportScore = studentHandsOnTaskReportQuery.getReportScore(); TeacherOpenCourseHandsOnSimulationTasks single = tasksService.createLambdaQuery() .andEq(TeacherOpenCourseHandsOnSimulationTasks::getTaskId, studentHandsOnTaskReport.getHandsOnTaskId()).single(); - if (single != null) { + if (single != null && reportScore != null) { try{ String taskScore = single.getTaskScore(); int i = NumberUtil.parseInt(taskScore);