|
@@ -21,7 +21,9 @@ import com.google.gson.Gson;
|
|
|
import com.qmth.themis.business.annotation.ApiJsonObject;
|
|
|
import com.qmth.themis.business.annotation.ApiJsonProperty;
|
|
|
import com.qmth.themis.business.base.BasePage;
|
|
|
+import com.qmth.themis.business.config.SystemConfig;
|
|
|
import com.qmth.themis.business.dto.cache.TEStudentCacheDto;
|
|
|
+import com.qmth.themis.business.dto.response.TEExamStudentDto;
|
|
|
import com.qmth.themis.business.dto.response.TEStudentDto;
|
|
|
import com.qmth.themis.business.dto.response.TEStudentExamRecordDto;
|
|
|
import com.qmth.themis.business.entity.TBUser;
|
|
@@ -58,12 +60,23 @@ public class TEStudentController {
|
|
|
|
|
|
@Resource
|
|
|
RedisUtil redisUtil;
|
|
|
+
|
|
|
+ @Resource
|
|
|
+ SystemConfig systemConfig;
|
|
|
|
|
|
@ApiOperation(value = "学生查询接口")
|
|
|
@RequestMapping(value = "/query", method = RequestMethod.POST)
|
|
|
@ApiResponses({@ApiResponse(code = 200, message = "考生信息", response = TEStudentDto.class)})
|
|
|
public Result query(@ApiParam(value = "证件号", required = false) @RequestParam(required = false) String identity, @ApiParam(value = "姓名", required = false) @RequestParam(required = false) String name, @ApiParam(value = "是否启用", required = false) @RequestParam(required = false) Integer enable, @ApiParam(value = "分页页码", required = true) @RequestParam int pageNumber, @ApiParam(value = "分页数", required = true) @RequestParam int pageSize) {
|
|
|
IPage<TEStudentDto> teExamStudentIPage = teStudentService.studentQuery(new Page<>(pageNumber, pageSize), identity, name, enable);
|
|
|
+ if(teExamStudentIPage.getRecords()!=null&&teExamStudentIPage.getRecords().size()>0) {
|
|
|
+ for(TEStudentDto dto:teExamStudentIPage.getRecords()) {
|
|
|
+ if(StringUtils.isNotBlank(dto.getBasePhotoPath())) {
|
|
|
+ dto.setBasePhotoPath(systemConfig.getProperty("aliyun.oss.url") + "/" +dto.getBasePhotoPath());
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
BasePage basePage = new BasePage(teExamStudentIPage.getRecords(), teExamStudentIPage.getCurrent(), teExamStudentIPage.getSize(), teExamStudentIPage.getTotal());
|
|
|
return ResultUtil.ok(basePage);
|
|
|
}
|