|
@@ -13,10 +13,7 @@ import io.swagger.annotations.ApiOperation;
|
|
|
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.security.access.prepost.PreAuthorize;
|
|
import org.springframework.security.access.prepost.PreAuthorize;
|
|
|
-import org.springframework.web.bind.annotation.PostMapping;
|
|
|
|
|
-import org.springframework.web.bind.annotation.RequestBody;
|
|
|
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
|
|
import java.util.List;
|
|
import java.util.List;
|
|
|
import java.util.Objects;
|
|
import java.util.Objects;
|
|
@@ -54,7 +51,7 @@ public class StudentCompetitionController extends BaseController {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "新增参赛作品")
|
|
@ApiOperation(value = "新增参赛作品")
|
|
|
- @PostMapping("/checkIsUpload")
|
|
|
|
|
|
|
+ @GetMapping("/checkIsUpload")
|
|
|
public HttpResponseResult<StudentCompetition> checkIsUpload(){
|
|
public HttpResponseResult<StudentCompetition> checkIsUpload(){
|
|
|
SysUser sysUser = sysUserFeignService.queryUserInfo();
|
|
SysUser sysUser = sysUserFeignService.queryUserInfo();
|
|
|
if (sysUser == null) {
|
|
if (sysUser == null) {
|
|
@@ -64,13 +61,13 @@ public class StudentCompetitionController extends BaseController {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取获奖名单")
|
|
@ApiOperation(value = "获取获奖名单")
|
|
|
- @PostMapping("/getWinnerList")
|
|
|
|
|
|
|
+ @GetMapping("/getWinnerList")
|
|
|
public HttpResponseResult<List<StudentCompetitionRankingDto>> getWinnerList(){
|
|
public HttpResponseResult<List<StudentCompetitionRankingDto>> getWinnerList(){
|
|
|
return succeed(studentCompetitionService.getWinnerList());
|
|
return succeed(studentCompetitionService.getWinnerList());
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@ApiOperation(value = "获取指定参赛作品详情")
|
|
@ApiOperation(value = "获取指定参赛作品详情")
|
|
|
- @PostMapping("/get")
|
|
|
|
|
|
|
+ @GetMapping("/get")
|
|
|
public HttpResponseResult<StudentCompetition> get(Long competitionId){
|
|
public HttpResponseResult<StudentCompetition> get(Long competitionId){
|
|
|
StudentCompetition studentCompetition = studentCompetitionService.get(competitionId);
|
|
StudentCompetition studentCompetition = studentCompetitionService.get(competitionId);
|
|
|
if(Objects.isNull(studentCompetition)||!studentCompetition.isShow()){
|
|
if(Objects.isNull(studentCompetition)||!studentCompetition.isShow()){
|