鲲鹏 пре 4 година
родитељ
комит
26583799db
4 измењених фајлова са 16 додато и 5 уклоњено
  1. +1
    -1
      src/main/java/com/taauav/app/controller/InspectQuestionController.java
  2. +1
    -1
      src/main/java/com/taauav/app/mapper/InspectQuestionMapper.java
  3. +1
    -1
      src/main/java/com/taauav/app/service/IInspectQuestionService.java
  4. +13
    -2
      src/main/java/com/taauav/app/service/impl/InspectQuestionServiceImpl.java

+ 1
- 1
src/main/java/com/taauav/app/controller/InspectQuestionController.java Прегледај датотеку

@@ -38,7 +38,7 @@ public class InspectQuestionController extends ApiBaseController {
*/
@PostMapping("/getQuestionList")
public Response getQuestionList(@RequestBody InspectQuestionQuery inspectQuestionDto) {
return response.success(inspectQuestionService.getQuestionList(inspectQuestionDto));
return inspectQuestionService.getQuestionList(inspectQuestionDto);
}

/**

+ 1
- 1
src/main/java/com/taauav/app/mapper/InspectQuestionMapper.java Прегледај датотеку

@@ -29,7 +29,7 @@ public interface InspectQuestionMapper extends BaseMapper<TauvInspectQuestion> {
* @param param 参数
* @return
*/
List<InspectQuestionListVo> getQuestionList(IPage<TauvInspectQuestion> page, @RequestParam("param") InspectQuestionQuery param);
IPage<InspectQuestionListVo> getQuestionList(IPage<TauvInspectQuestion> page, @RequestParam("param") InspectQuestionQuery param);

/**
* 获取问题详情

+ 1
- 1
src/main/java/com/taauav/app/service/IInspectQuestionService.java Прегледај датотеку

@@ -28,7 +28,7 @@ public interface IInspectQuestionService extends IService<TauvInspectQuestion> {
* @param inspectQuestionDto 参数
* @return
*/
List<InspectQuestionListVo> getQuestionList(InspectQuestionQuery inspectQuestionDto);
Response getQuestionList(InspectQuestionQuery inspectQuestionDto);

/**
* 获取问题详情

+ 13
- 2
src/main/java/com/taauav/app/service/impl/InspectQuestionServiceImpl.java Прегледај датотеку

@@ -75,9 +75,20 @@ public class InspectQuestionServiceImpl extends ServiceImpl<InspectQuestionMappe
* @return
*/
@Override
public List<InspectQuestionListVo> getQuestionList(InspectQuestionQuery inspectQuestionDto) {
public Response getQuestionList(InspectQuestionQuery inspectQuestionDto) {
IPage<TauvInspectQuestion> page = new Page<>(inspectQuestionDto.getPage(), inspectQuestionDto.getPageSize());
return inspectQuestionMapper.getQuestionList(page, inspectQuestionDto);
// 获取分页数据
IPage<InspectQuestionListVo> data = inspectQuestionMapper.getQuestionList(page, inspectQuestionDto);

// 返回结果
Map<String, Object> result = new HashMap<>();
result.put("total", data.getTotal());
result.put("size", data.getSize());
result.put("current", data.getCurrent());
result.put("pages", data.getPages());
result.put("records", data.getRecords());

return response.success(result);
}

/**

Loading…
Откажи
Сачувај