|
@@ -1,10 +1,10 @@
|
|
package cn.com.qmth.scancentral.controller.admin;
|
|
package cn.com.qmth.scancentral.controller.admin;
|
|
|
|
|
|
|
|
+import java.util.List;
|
|
|
|
+
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
-import org.springframework.web.bind.annotation.RequestMethod;
|
|
|
|
-import org.springframework.web.bind.annotation.RequestParam;
|
|
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
+import org.springframework.validation.annotation.Validated;
|
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import com.qmth.boot.api.annotation.Aac;
|
|
import com.qmth.boot.api.annotation.Aac;
|
|
import com.qmth.boot.api.constant.ApiConstant;
|
|
import com.qmth.boot.api.constant.ApiConstant;
|
|
@@ -12,6 +12,10 @@ import com.qmth.boot.api.constant.ApiConstant;
|
|
import cn.com.qmth.scancentral.bean.User;
|
|
import cn.com.qmth.scancentral.bean.User;
|
|
import cn.com.qmth.scancentral.controller.BaseController;
|
|
import cn.com.qmth.scancentral.controller.BaseController;
|
|
import cn.com.qmth.scancentral.service.ExamService;
|
|
import cn.com.qmth.scancentral.service.ExamService;
|
|
|
|
+import cn.com.qmth.scancentral.service.StudentService;
|
|
|
|
+import cn.com.qmth.scancentral.vo.answerquery.AnswerQueryVo;
|
|
|
|
+import cn.com.qmth.scancentral.vo.assginedcheck.AssginedTaskResult;
|
|
|
|
+import cn.com.qmth.scancentral.vo.assginedcheck.AssignedTaskSaveVo;
|
|
import cn.com.qmth.scancentral.vo.auditor.AuditorOverview;
|
|
import cn.com.qmth.scancentral.vo.auditor.AuditorOverview;
|
|
import io.swagger.annotations.Api;
|
|
import io.swagger.annotations.Api;
|
|
import io.swagger.annotations.ApiOperation;
|
|
import io.swagger.annotations.ApiOperation;
|
|
@@ -25,6 +29,9 @@ public class AuditorController extends BaseController {
|
|
@Autowired
|
|
@Autowired
|
|
private ExamService examService;
|
|
private ExamService examService;
|
|
|
|
|
|
|
|
+ @Autowired
|
|
|
|
+ private StudentService studentService;
|
|
|
|
+
|
|
@ApiOperation(value = "考试概览数据")
|
|
@ApiOperation(value = "考试概览数据")
|
|
@RequestMapping(value = "/exam/overview", method = RequestMethod.POST)
|
|
@RequestMapping(value = "/exam/overview", method = RequestMethod.POST)
|
|
public AuditorOverview overview(@RequestParam Long examId) {
|
|
public AuditorOverview overview(@RequestParam Long examId) {
|
|
@@ -32,4 +39,33 @@ public class AuditorController extends BaseController {
|
|
return examService.getAuditorOverview(examId, user);
|
|
return examService.getAuditorOverview(examId, user);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ @ApiOperation(value = "审核员任务获取")
|
|
|
|
+ @RequestMapping(value = "/check/assigned/task/get", method = RequestMethod.POST)
|
|
|
|
+ public AnswerQueryVo get(@RequestParam Long examId) {
|
|
|
|
+ User user = getAccessUser();
|
|
|
|
+ return studentService.getAssignedCheckTask(examId, user.getAccount());
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @ApiOperation(value = "审核员任务历史")
|
|
|
|
+ @RequestMapping(value = "/check/assigned/task/history", method = RequestMethod.POST)
|
|
|
|
+ public List<AnswerQueryVo> history(@RequestParam Long id, @RequestParam Long pageSize) {
|
|
|
|
+ User user = getAccessUser();
|
|
|
|
+ return studentService.getAssignedCheckTaskHistory(id, pageSize, user);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @ApiOperation(value = "审核员任务提交")
|
|
|
|
+ @RequestMapping(value = "/check/assigned/task/save", method = RequestMethod.POST)
|
|
|
|
+ public AssignedTaskSaveVo submit(@Validated @RequestBody AssginedTaskResult result) {
|
|
|
|
+ User user = getAccessUser();
|
|
|
|
+ return studentService.submitAssignedCheckTask(result, user);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @ApiOperation(value = "审核员任务释放")
|
|
|
|
+ @PostMapping("/check/assigned/task/release")
|
|
|
|
+ public Object release(@RequestParam Long examId) {
|
|
|
|
+ User user = getAccessUser();
|
|
|
|
+ studentService.releaseAssignedCheckTaskByUser(examId, user.getAccount());
|
|
|
|
+ return success(true);
|
|
|
|
+ }
|
|
|
|
+
|
|
}
|
|
}
|