|
|
@ -29,16 +29,16 @@ public class ScoreController { |
|
|
|
@ApiOperation(value = "评委获取评分项",notes = "") |
|
|
|
@ApiImplicitParams({ |
|
|
|
@ApiImplicitParam(name = "roleId", value = "评委id", required = true, paramType = "path"), |
|
|
|
@ApiImplicitParam(name = "playerId", value = "参赛项目id", required = true, paramType = "path"), |
|
|
|
@ApiImplicitParam(name = "taskId", value = "参赛项目id", required = true, paramType = "path"), |
|
|
|
}) |
|
|
|
@RequestMapping(value = "/score", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
|
public JsonResponse<List<ScoreVo.ScoreInfo>> getScoreLog(HttpServletRequest request, |
|
|
|
@RequestParam Long roleId, |
|
|
|
@RequestParam(required = true) Long playerId) throws Exception { |
|
|
|
@RequestParam(required = true) Long taskId) throws Exception { |
|
|
|
//获取userId
|
|
|
|
Long userId = userService.getUserIdByToken(request); |
|
|
|
|
|
|
|
List<ScoreVo.ScoreInfo> scoreInfoList = scoreService.getScoreLog(userId,playerId); |
|
|
|
List<ScoreVo.ScoreInfo> scoreInfoList = scoreService.getScoreLog(userId,taskId); |
|
|
|
return JsonResponse.newInstance().ok(scoreInfoList); |
|
|
|
} |
|
|
|
|
|
|
@ -77,11 +77,11 @@ public class ScoreController { |
|
|
|
@RequestMapping(value = "/scores", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
|
public JsonResponse<List<ScoreVo.AdminScore>> adminScore(HttpServletRequest request, |
|
|
|
@RequestParam(required = true) Long roleId, |
|
|
|
@RequestParam(required = true) Long playerId) throws Exception { |
|
|
|
@RequestParam(required = true) Long taskId) throws Exception { |
|
|
|
//获取userId
|
|
|
|
Long userId = userService.getUserIdByToken(request); |
|
|
|
|
|
|
|
List<ScoreVo.AdminScore> adminScoreList = scoreService.adminScore(userId,roleId,playerId); |
|
|
|
List<ScoreVo.AdminScore> adminScoreList = scoreService.adminScore(userId,roleId,taskId); |
|
|
|
return JsonResponse.newInstance().ok(adminScoreList); |
|
|
|
} |
|
|
|
|
|
|
@ -90,28 +90,28 @@ public class ScoreController { |
|
|
|
@ApiOperation(value = "退回单个评委的评分",notes = "") |
|
|
|
@ApiImplicitParams({ |
|
|
|
@ApiImplicitParam(name = "roleId", value = "评委id", required = true, paramType = "path"), |
|
|
|
@ApiImplicitParam(name = "playerId", value = "参赛项目id", required = true, paramType = "path"), |
|
|
|
@ApiImplicitParam(name = "taskId", value = "taskId", required = true, paramType = "path"), |
|
|
|
}) |
|
|
|
@RequestMapping(value = "/back", method = RequestMethod.DELETE, produces = {"application/json;charset=UTF-8"}) |
|
|
|
public JsonResponse backScore(@RequestParam(required = true) Long roleId, |
|
|
|
@RequestParam(required = true) Long playerId) throws Exception { |
|
|
|
scoreService.backScore(roleId,playerId); |
|
|
|
@RequestParam(required = true) Long taskId) throws Exception { |
|
|
|
scoreService.backScore(roleId,taskId); |
|
|
|
return JsonResponse.newInstance().ok(); |
|
|
|
} |
|
|
|
|
|
|
|
@ApiOperation(value = "退回所有评委的评分",notes = "") |
|
|
|
@ApiImplicitParams({ |
|
|
|
@ApiImplicitParam(name = "playerId", value = "参赛项目id", required = true, paramType = "path"), |
|
|
|
@ApiImplicitParam(name = "taskId", value = "任务id", required = true, paramType = "path"), |
|
|
|
}) |
|
|
|
@RequestMapping(value = "/backAll", method = RequestMethod.DELETE, produces = {"application/json;charset=UTF-8"}) |
|
|
|
public JsonResponse backScoreAll(@RequestParam(required = true) Long playerId) throws Exception { |
|
|
|
scoreService.backScoreAll(playerId); |
|
|
|
public JsonResponse backScoreAll(@RequestParam(required = true) Long taskId) throws Exception { |
|
|
|
scoreService.backScoreAll(taskId); |
|
|
|
return JsonResponse.newInstance().ok(); |
|
|
|
} |
|
|
|
|
|
|
|
@ApiOperation(value = "查看项目排名及详细分数",notes = "") |
|
|
|
@ApiOperation(value = "查看排名及详细分数",notes = "") |
|
|
|
@ApiImplicitParams({ |
|
|
|
@ApiImplicitParam(name = "projectId", value = "项目组id", required = true, paramType = "path"), |
|
|
|
@ApiImplicitParam(name = "projectId", value = "", required = true, paramType = "path"), |
|
|
|
}) |
|
|
|
@RequestMapping(value = "/ranking", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
|
public JsonResponse<List<ScoreVo.RankingScore>> getRankingScore(HttpServletRequest request, |
|
|
@ -128,8 +128,8 @@ public class ScoreController { |
|
|
|
}) |
|
|
|
@RequestMapping(value = "/show", method = RequestMethod.GET, produces = {"application/json;charset=UTF-8"}) |
|
|
|
public JsonResponse showScore(HttpServletRequest request, |
|
|
|
@RequestParam(required = true)Long projectId,Long playerId) throws Exception { |
|
|
|
scoreService.showScore(projectId,playerId); |
|
|
|
@RequestParam(required = true)Long projectId,Long taskId) throws Exception { |
|
|
|
scoreService.showScore(projectId,taskId); |
|
|
|
return JsonResponse.newInstance().ok(); |
|
|
|
} |
|
|
|
|
|
|
|