|
@@ -50,11 +50,14 @@ public class GetScoreDataServiceProvider extends ControllerSupport implements Ge
|
|
|
@PostMapping("/getScoreData")
|
|
|
@Override
|
|
|
public OuterGetScoreDataResp getScoreData(@RequestBody OuterGetScoreDataReq req) {
|
|
|
+ if(req.getRootOrgId() == null){
|
|
|
+ throw new StatusException("EX-1000001", "rootOrgId不能为空");
|
|
|
+ }
|
|
|
if (!getSecurityRootOrgId().equals(req.getRootOrgId())) {
|
|
|
- throw new StatusException("EX-1000001", "rootOrgId is wrong");
|
|
|
+ throw new StatusException("EX-1000002", "rootOrgId错误");
|
|
|
}
|
|
|
if (req.getExamRecordDataId()==null) {
|
|
|
- throw new StatusException("EX-1000002", "examRecordDataId is null");
|
|
|
+ throw new StatusException("EX-1000003", "examRecordDataId不能为空");
|
|
|
}
|
|
|
GetScoreDataReq getScoreDataReq = new GetScoreDataReq();
|
|
|
getScoreDataReq.setExamRecordDataId(req.getExamRecordDataId());
|
|
@@ -84,20 +87,23 @@ public class GetScoreDataServiceProvider extends ControllerSupport implements Ge
|
|
|
@PostMapping("/queryScoreData")
|
|
|
@Override
|
|
|
public OuterQueryScoreDataResp queryScoreData(@RequestBody OuterQueryScoreDataReq req) {
|
|
|
+ if(req.getRootOrgId() == null){
|
|
|
+ throw new StatusException("EX-1000001", "rootOrgId不能为空");
|
|
|
+ }
|
|
|
if (!getSecurityRootOrgId().equals(req.getRootOrgId())) {
|
|
|
- throw new StatusException("EX-1000001", "rootOrgId is wrong");
|
|
|
+ throw new StatusException("EX-1000002", "rootOrgId错误");
|
|
|
}
|
|
|
if(StringUtils.isBlank(req.getExamName())){
|
|
|
- throw new StatusException("EX-1000005", "考试名称不能为空");
|
|
|
+ throw new StatusException("EX-1000003", "考试名称不能为空");
|
|
|
}
|
|
|
if(StringUtils.isBlank(req.getCourseCode())){
|
|
|
- throw new StatusException("EX-1000005", "课程code不能为空");
|
|
|
+ throw new StatusException("EX-1000004", "课程code不能为空");
|
|
|
}
|
|
|
if(req.getRootOrgId() == null){
|
|
|
throw new StatusException("EX-1000005", "rootOrgId不能为空");
|
|
|
}
|
|
|
if(StringUtils.isBlank(req.getIdentityNumber()) && StringUtils.isBlank(req.getStudentCode())){
|
|
|
- throw new StatusException("EX-1000005", "身份证号和学号不能都为空");
|
|
|
+ throw new StatusException("EX-1000006", "身份证号和学号不能都为空");
|
|
|
}
|
|
|
QueryScoreDataReq queryScoreDataReq = new QueryScoreDataReq();
|
|
|
queryScoreDataReq.setCourseCode(req.getCourseCode());
|