ting.yin 7 rokov pred
rodič
commit
cc24d14488

+ 11 - 0
exam-work-api/src/main/java/cn/com/qmth/examcloud/service/examwork/api/ExamApi.java

@@ -26,6 +26,7 @@ import cn.com.qmth.examcloud.common.uac.entity.AccessUser;
 import cn.com.qmth.examcloud.common.util.ErrorMsg;
 import cn.com.qmth.examcloud.service.examwork.dao.ExamRepo;
 import cn.com.qmth.examcloud.service.examwork.entity.Exam;
+import cn.com.qmth.examcloud.service.examwork.entity.ExamStudent;
 import cn.com.qmth.examcloud.service.examwork.service.ExamService;
 import cn.com.qmth.examcloud.service.examwork.service.ExamStudentService;
 
@@ -179,4 +180,14 @@ public class ExamApi {
         examStudentService.updateExamStudentInfo(examStuId);
         return new ResponseEntity(HttpStatus.OK);
     }
+    
+    @ApiOperation(value = "网考更新考务信息", notes = "网考更新考务信息")
+    @PutMapping("/exam/updateExamStudent")
+    public ResponseEntity updateExamStudent(@RequestParam Long examId,@RequestParam Long examStuId) {
+        examRepo.canNotDel(examId);
+        ExamStudent examStudent = examStudentRepo.findOne(examStuId);
+	    examStudent.setFinished(true);
+	    examStudentRepo.save(examStudent);
+        return new ResponseEntity(HttpStatus.OK);
+    }
 }