|
@@ -43,6 +43,18 @@ public class PaperResultController {
|
|
|
return paperResultService.parseResult(commit, paper);
|
|
|
}
|
|
|
|
|
|
+ @GetMapping("/rebuildByPid")
|
|
|
+ @ApiOperation("根据试卷Id重新生成报告结果")
|
|
|
+ public Result rebuildByPid(Long pid) {
|
|
|
+ List<PaperCommit> commits = paperCommitRepo.findByPid(pid);
|
|
|
+ logger.info("rebuild paper result,size={}", commits.size());
|
|
|
+ for (PaperCommit commit:commits){
|
|
|
+ rebuild(commit.getId());
|
|
|
+ }
|
|
|
+ return Result.ok("rebuild success");
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
@GetMapping("/rebuildByPidAndUid")
|
|
|
@ApiOperation("重新生成报告结果,方便测试")
|
|
|
public Result rebuild(Long pid, Long uid) {
|