|
@@ -10,6 +10,7 @@ import com.qmth.themis.business.dto.response.TEStudentDto;
|
|
import com.qmth.themis.business.dto.response.TEStudentExamRecordDto;
|
|
import com.qmth.themis.business.dto.response.TEStudentExamRecordDto;
|
|
import com.qmth.themis.business.entity.TBUser;
|
|
import com.qmth.themis.business.entity.TBUser;
|
|
import com.qmth.themis.business.entity.TEStudent;
|
|
import com.qmth.themis.business.entity.TEStudent;
|
|
|
|
+import com.qmth.themis.business.entity.TOeExamRecord;
|
|
import com.qmth.themis.business.service.TEStudentService;
|
|
import com.qmth.themis.business.service.TEStudentService;
|
|
import com.qmth.themis.business.util.JacksonUtil;
|
|
import com.qmth.themis.business.util.JacksonUtil;
|
|
import com.qmth.themis.business.util.ServletUtil;
|
|
import com.qmth.themis.business.util.ServletUtil;
|
|
@@ -107,13 +108,13 @@ public class TEStudentController {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiOperation(value = "学生考试记录查询接口")
|
|
@ApiOperation(value = "学生考试记录查询接口")
|
|
- @RequestMapping(value = "/studentExamRecordQuery", method = RequestMethod.POST)
|
|
|
|
- @ApiResponses({@ApiResponse(code = 200, message = "考生信息", response = TEStudentExamRecordDto.class)})
|
|
|
|
- public Result studentExamRecordQuery(@ApiParam(value = "学生id", required = true) @RequestParam Long id, @ApiParam(value = "批次名称", required = false) @RequestParam(required = false) String name, @ApiParam(value = "分页页码", required = true) @RequestParam int pageNumber, @ApiParam(value = "分页数", required = true) @RequestParam int pageSize) {
|
|
|
|
- if (Objects.isNull(id) || Objects.equals(id, "")) {
|
|
|
|
|
|
+ @RequestMapping(value = "/exam_record/query", method = RequestMethod.POST)
|
|
|
|
+ @ApiResponses({@ApiResponse(code = 200, message = "学生考试记录信息", response = TOeExamRecord.class)})
|
|
|
|
+ public Result examRecordQuery(@ApiParam(value = "学生ID", required = true) @RequestParam Long studentId, @ApiParam(value = "考试id", required = false) @RequestParam(required = false) Long examId, @ApiParam(value = "分页页码", required = true) @RequestParam int pageNumber, @ApiParam(value = "分页数", required = true) @RequestParam int pageSize) {
|
|
|
|
+ if (Objects.isNull(studentId) || Objects.equals(studentId, "")) {
|
|
throw new BusinessException(ExceptionResultEnum.STUDENT_ID_IS_NULL);
|
|
throw new BusinessException(ExceptionResultEnum.STUDENT_ID_IS_NULL);
|
|
}
|
|
}
|
|
- IPage<TEStudentExamRecordDto> teStudentExamRecordDtoIPage = teStudentService.studentExamRecordQuery(new Page<>(pageNumber, pageSize), id, name);
|
|
|
|
|
|
+ IPage<TEStudentExamRecordDto> teStudentExamRecordDtoIPage = teStudentService.studentExamRecordQuery(new Page<>(pageNumber, pageSize), studentId, examId);
|
|
BasePage basePage = new BasePage(teStudentExamRecordDtoIPage.getRecords(), teStudentExamRecordDtoIPage.getCurrent(), teStudentExamRecordDtoIPage.getSize(), teStudentExamRecordDtoIPage.getTotal());
|
|
BasePage basePage = new BasePage(teStudentExamRecordDtoIPage.getRecords(), teStudentExamRecordDtoIPage.getCurrent(), teStudentExamRecordDtoIPage.getSize(), teStudentExamRecordDtoIPage.getTotal());
|
|
Map map = new HashMap<>();
|
|
Map map = new HashMap<>();
|
|
map.put(SystemConstant.RECORDS, basePage);
|
|
map.put(SystemConstant.RECORDS, basePage);
|