瀏覽代碼

fixbug同步考生数据缺失

xiatian 1 月之前
父節點
當前提交
4c0a053eeb

+ 0 - 1
examcloud-core-examwork-api-provider/src/main/java/cn/com/qmth/examcloud/core/examwork/api/controller/ExamStudentController.java

@@ -515,7 +515,6 @@ public class ExamStudentController extends ControllerSupport {
         }
 
         ExamStudentInfo savedExamStudent = examStudentService.saveExamStudent(info);
-        examStudentService.syncExamStudent(savedExamStudent);
 
         ExamStudentDomain ret = new ExamStudentDomain();
         ret.setId(savedExamStudent.getId());

+ 0 - 3
examcloud-core-examwork-api-provider/src/main/java/cn/com/qmth/examcloud/core/examwork/api/provider/ExamStudentCloudServiceProvider.java

@@ -107,7 +107,6 @@ public class ExamStudentCloudServiceProvider extends ControllerSupport implement
 
     @ApiOperation(value = "保存考生")
     @PostMapping("saveExamStudent")
-    @Transactional
     @Override
     public SaveExamStudentResp saveExamStudent(@RequestBody SaveExamStudentReq req) {
         trim(req);
@@ -189,7 +188,6 @@ public class ExamStudentCloudServiceProvider extends ControllerSupport implement
 
     @ApiOperation(value = "复制考生")
     @PostMapping("copyExamStudents")
-    @Transactional
     @Override
     public CopyExamStudentsResp copyExamStudents(@RequestBody CopyExamStudentsReq req) {
 
@@ -533,7 +531,6 @@ public class ExamStudentCloudServiceProvider extends ControllerSupport implement
 
     @ApiOperation(value = "重置考生")
     @PostMapping("resetExamStudent")
-    @Transactional
     @Override
     public ResetExamStudentResp resetExamStudent(@RequestBody ResetExamStudentReq req) {
 

+ 2 - 0
examcloud-core-examwork-service/src/main/java/cn/com/qmth/examcloud/core/examwork/service/ExamStudentService.java

@@ -30,4 +30,6 @@ public interface ExamStudentService {
 
     void syncExamStudent(ExamStudentInfo saved);
 
+    ExamStudentInfo saveExamStudentData(ExamStudentInfo examStudentInfo);
+
 }

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

@@ -243,6 +243,13 @@ public class ExamStudentServiceImpl implements ExamStudentService {
         }
     }
 
+    @Override
+    public ExamStudentInfo saveExamStudent(ExamStudentInfo examStudentInfo) {
+        ExamStudentInfo savedExamStudent = examStudentService.saveExamStudentData(examStudentInfo);
+        examStudentService.syncExamStudent(savedExamStudent);
+        return savedExamStudent;
+    }
+
     /*
      * 实现
      *
@@ -254,7 +261,7 @@ public class ExamStudentServiceImpl implements ExamStudentService {
      */
     @Transactional
     @Override
-    public ExamStudentInfo saveExamStudent(ExamStudentInfo examStudentInfo) {
+    public ExamStudentInfo saveExamStudentData(ExamStudentInfo examStudentInfo) {
         String paperType = examStudentInfo.getPaperType();
         String studentCode = examStudentInfo.getStudentCode();