feat(uapbd): 添加默认分页参数

- 当 pageInfo 为空时,添加默认的分页参数
- 设置默认的 pageIndex 为 0,pageSize 为 10
This commit is contained in:
maolei 2025-05-13 11:27:26 +08:00
parent 2130d2dbf7
commit 6b2a1ccb0e
1 changed files with 7 additions and 1 deletions

View File

@ -40,6 +40,12 @@ public class QuerySync extends AbstractNCCRestResource {
JSONObject pageInfo = (JSONObject) JSONObject.toJSON(apiUfinterface.getPageInfo());
data.remove("type"); // 移除类型参数因为它仅用于路由,向下传递会影响查询
if (pageInfo == null) {
pageInfo = new JSONObject();
pageInfo.put("pageIndex", "0");
pageInfo.put("pageSize", "10");
}// 默认分页
// 获取额外条件
String extraCondition = null;
if (data.containsKey("extraCondition")) {