wangwei 6 vuotta sitten
vanhempi
commit
f108bce61d

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

@@ -6,6 +6,7 @@ import cn.com.qmth.examcloud.core.examwork.service.impl.ExamCourseService;
 
 
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.data.domain.Page;
 import org.springframework.data.domain.Page;
+import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.*;
 import org.springframework.web.bind.annotation.*;
 
 
 import java.util.List;
 import java.util.List;
@@ -13,6 +14,7 @@ import java.util.List;
 /**
 /**
  * Created by yuanpan on 2017/4/12.
  * Created by yuanpan on 2017/4/12.
  */
  */
+@Transactional
 @RestController
 @RestController
 @RequestMapping("${$rmp.ctr.examwork}/exam_course")
 @RequestMapping("${$rmp.ctr.examwork}/exam_course")
 public class ExamCourseController {
 public class ExamCourseController {

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

@@ -7,6 +7,7 @@ import org.springframework.data.domain.Page;
 import org.springframework.data.domain.PageRequest;
 import org.springframework.data.domain.PageRequest;
 import org.springframework.http.HttpStatus;
 import org.springframework.http.HttpStatus;
 import org.springframework.http.ResponseEntity;
 import org.springframework.http.ResponseEntity;
+import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.ModelAttribute;
 import org.springframework.web.bind.annotation.ModelAttribute;
 import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.PathVariable;
@@ -24,6 +25,7 @@ import io.swagger.annotations.ApiOperation;
 /**
 /**
  * 考试服务API Created by songyue on 17/1/13.
  * 考试服务API Created by songyue on 17/1/13.
  */
  */
+@Transactional
 @RestController
 @RestController
 @RequestMapping("${$rmp.ctr.examwork}/examOrgTime")
 @RequestMapping("${$rmp.ctr.examwork}/examOrgTime")
 public class ExamOrgTimeController {
 public class ExamOrgTimeController {

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

@@ -5,6 +5,7 @@ import cn.com.qmth.examcloud.core.examwork.dao.bean.ExamPaperTypeDTO;
 import cn.com.qmth.examcloud.core.examwork.dao.entity.ExamStudent;
 import cn.com.qmth.examcloud.core.examwork.dao.entity.ExamStudent;
 import io.swagger.annotations.ApiOperation;
 import io.swagger.annotations.ApiOperation;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestParam;
 import org.springframework.web.bind.annotation.RequestParam;
@@ -15,6 +16,7 @@ import java.util.List;
 /**
 /**
  * Created by yuanpan on 2017/4/12.
  * Created by yuanpan on 2017/4/12.
  */
  */
+@Transactional
 @RestController
 @RestController
 @RequestMapping("${$rmp.ctr.examwork}/exam_paper_type")
 @RequestMapping("${$rmp.ctr.examwork}/exam_paper_type")
 public class ExamPaperTypController {
 public class ExamPaperTypController {

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

@@ -7,12 +7,14 @@ import io.swagger.annotations.ApiOperation;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.data.domain.PageRequest;
 import org.springframework.data.domain.PageRequest;
 import org.springframework.http.ResponseEntity;
 import org.springframework.http.ResponseEntity;
+import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.*;
 import org.springframework.web.bind.annotation.*;
 
 
 /**
 /**
  * 考试分数服务API
  * 考试分数服务API
  * Created by songyue on 17/1/13.
  * Created by songyue on 17/1/13.
  */
  */
+@Transactional
 @RestController
 @RestController
 @RequestMapping("${$rmp.ctr.examwork}")
 @RequestMapping("${$rmp.ctr.examwork}")
 public class ExamScoreController {
 public class ExamScoreController {

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

@@ -49,6 +49,7 @@ import io.swagger.annotations.ApiOperation;
 /**
 /**
  * 考生服务API Created by songyue on 17/1/13.
  * 考生服务API Created by songyue on 17/1/13.
  */
  */
+@Transactional
 @RestController
 @RestController
 @RequestMapping("${$rmp.ctr.examwork}/exam_student")
 @RequestMapping("${$rmp.ctr.examwork}/exam_student")
 public class ExamStudentController extends ControllerSupport {
 public class ExamStudentController extends ControllerSupport {

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

@@ -2,6 +2,7 @@ package cn.com.qmth.examcloud.core.examwork.api.provider;
 
 
 import org.apache.commons.lang3.StringUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
@@ -34,6 +35,7 @@ import io.swagger.annotations.ApiOperation;
  * @company QMTH
  * @company QMTH
  * @description ExamProvider.java
  * @description ExamProvider.java
  */
  */
+@Transactional
 @RestController
 @RestController
 @RequestMapping("${$rmp.cloud.examwork}" + "exam")
 @RequestMapping("${$rmp.cloud.examwork}" + "exam")
 public class ExamCloudServiceProvider extends ControllerSupport implements ExamCloudService {
 public class ExamCloudServiceProvider extends ControllerSupport implements ExamCloudService {

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

@@ -1,8 +1,7 @@
 package cn.com.qmth.examcloud.core.examwork.api.provider;
 package cn.com.qmth.examcloud.core.examwork.api.provider;
 
 
-import javax.transaction.Transactional;
-
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestMapping;