Skip to content

返回的对象是空,是什么原因 #222

Open
@gcg888

Description

@gcg888

生成的controller,返回对象都是空,是什么原因。

{
"STATUS": "1",
-"ITEMS": {
-"records": [
{ },
{ },
{ },
{ },
{ },
{ },
{ },
{ },
{ },
{ }
],
"total": 36,
"size": 10,
"current": 1,
"pages": 4
},
"BUSINESSSTATUS": "",
"MESSAGE": "查询成功"
}
其实service是取到值的

@GetMapping
@ApiOperation(value = "获取全部",notes = "返回分页过后的数据",httpMethod = "GET")
@ApiImplicitParams({
@ApiImplicitParam(name = "page",value = "查询页码", paramType = "query",dataType = "Integer",defaultValue = "1"),
@ApiImplicitParam(name = "pageSize",value = "每页数据量", paramType = "query",dataType = "Integer",defaultValue = "10")
})
public Map<CodeMsgEnum, Object> list(@ApiIgnore @RequestParam Map<String, Object> params) {
Page coursePage = new Query<>(params);
QueryWrapper wrapper = new QueryWrapper<>();
IPage courseIPage = courseMapper.selectPage(coursePage,wrapper);
return MessageResultUtils.getResults(courseIPage, CodeMsgEnum.SEARCH_SUCCESS);
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions