后台考试提交失败功能修改,注:要在setting配置里把项目设置成utf-8统一编码
This commit is contained in:
parent
6cdfc36e75
commit
66fa1e70ca
|
|
@ -3,6 +3,7 @@ package com.bonus.common.exam.vo;
|
|||
import com.bonus.common.core.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
|
|
@ -12,7 +13,13 @@ import java.util.List;
|
|||
* @version:1.0
|
||||
*/
|
||||
@Data
|
||||
public class AppLearningTaskVo {
|
||||
public class AppLearningTaskVo implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
public AppLearningTaskVo() {
|
||||
}
|
||||
|
||||
private String id;
|
||||
private String userId;
|
||||
private String userName;
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ import com.bonus.common.exam.vo.AppLearningTaskVo;
|
|||
import com.bonus.common.exam.vo.ViewTestQuestionVo;
|
||||
import com.bonus.common.log.annotation.SysLog;
|
||||
import com.bonus.common.log.enums.OperaType;
|
||||
import com.bonus.common.security.annotation.InnerAuth;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
|
|
@ -121,9 +122,9 @@ public class AutoPracticeController extends BaseController {
|
|||
* @param dto 参数
|
||||
* @return AjaxResult
|
||||
*/
|
||||
@PostMapping("/submitAnswer")
|
||||
@PostMapping(value ="/submitAnswer", consumes = "application/json;charset=UTF-8")
|
||||
@SysLog(title = "我的考试", businessType = OperaType.INSERT, logType = 0, module = "我的考试--结束考试")
|
||||
public AjaxResult submitAnswer(@RequestBody AppLearningTaskVo dto) {
|
||||
public AjaxResult submitAnswer( @RequestBody AppLearningTaskVo dto) {
|
||||
try {
|
||||
return service.submitAnswer(dto);
|
||||
} catch (Exception e) {
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ import com.bonus.common.exam.vo.ViewTestQuestionVo;
|
|||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.cloud.openfeign.SpringQueryMap;
|
||||
import org.springframework.http.MediaType;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
|
|
@ -75,8 +76,8 @@ public interface AutoPracticeService {
|
|||
* @return AjaxResult
|
||||
*/
|
||||
@ApiOperation(value = "结束考试")
|
||||
@PostMapping(value = "/autoPractice/submitAnswer")
|
||||
String webSubmitAnswer(@RequestBody AppLearningTaskVo dto);
|
||||
@PostMapping(value = "/autoPractice/submitAnswer", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE)
|
||||
AjaxResult webSubmitAnswer(@RequestBody AppLearningTaskVo dto);
|
||||
|
||||
/**
|
||||
* 培训签到
|
||||
|
|
|
|||
|
|
@ -82,8 +82,8 @@ public class AutoPracticeServiceImpl implements AutoPracticeService {
|
|||
* @return AjaxResult
|
||||
*/
|
||||
@Override
|
||||
public String webSubmitAnswer(AppLearningTaskVo dto) {
|
||||
return "";
|
||||
public AjaxResult webSubmitAnswer(AppLearningTaskVo dto) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in New Issue