mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
REPO-2117: Deleted nodes pagination returns incorrect properties
- fix paging call (in API impl) & add a sanity test (to JUnit test suite) git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@137827 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -118,6 +118,9 @@ public class DeletedNodesImpl implements DeletedNodes
|
||||
|
||||
// Query the DB
|
||||
PagingResults<NodeRef> result = nodeArchiveService.listArchivedNodes(queryBuilder);
|
||||
|
||||
Integer totalItems = result.getTotalResultCount().getFirst();
|
||||
|
||||
List<Node> nodesFound = new ArrayList<Node>(result.getPage().size());
|
||||
Map mapUserInfo = new HashMap<>();
|
||||
for (NodeRef nRef:result.getPage())
|
||||
@@ -126,7 +129,8 @@ public class DeletedNodesImpl implements DeletedNodes
|
||||
mapArchiveInfo(foundNode,mapUserInfo);
|
||||
nodesFound.add(foundNode);
|
||||
}
|
||||
return CollectionWithPagingInfo.asPaged(parameters.getPaging(), nodesFound);
|
||||
|
||||
return CollectionWithPagingInfo.asPaged(parameters.getPaging(), nodesFound, result.hasMoreItems(), (totalItems == null ? null : totalItems.intValue()));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Reference in New Issue
Block a user