fix(接口测试): 修复场景分页排序的缺陷

This commit is contained in:
song-tianyang 2024-04-17 00:24:10 +08:00 committed by 刘瑞斌
parent ec3cc8b8c0
commit 73425897df
1 changed files with 1 additions and 1 deletions

View File

@ -58,7 +58,7 @@ public class ApiScenarioController {
@CheckOwner(resourceId = "#request.getProjectId()", resourceType = "project")
public Pager<List<ApiScenarioDTO>> getPage(@Validated @RequestBody ApiScenarioPageRequest request) {
Page<Object> page = PageHelper.startPage(request.getCurrent(), request.getPageSize(),
StringUtils.isNotBlank(request.getSortString()) ? request.getSortString() : "pos desc");
StringUtils.isNotBlank(request.getSortString("id")) ? request.getSortString("id") : "pos desc, id desc");
return PageUtils.setPageInfo(page, apiScenarioService.getScenarioPage(request));
}