fix: Check for Pageable.unpaged when requesting pages.
This commit is contained in:
committed by
Michael Simons
parent
97d645398c
commit
a232264d7a
@@ -242,10 +242,14 @@ public final class QueryFragmentsAndParameters {
|
||||
Pageable pageable,
|
||||
QueryFragments queryFragments
|
||||
) {
|
||||
if (pageable.isPaged()) {
|
||||
queryFragments.setSkip(pageable.getOffset());
|
||||
queryFragments.setLimit(pageable.getPageSize());
|
||||
}
|
||||
Sort pageableSort = pageable.getSort();
|
||||
queryFragments.setSkip(pageable.getOffset());
|
||||
queryFragments.setLimit(pageable.getPageSize());
|
||||
queryFragments.setOrderBy(CypherAdapterUtils.toSortItems(entityMetaData, pageableSort));
|
||||
if (pageableSort.isSorted()) {
|
||||
queryFragments.setOrderBy(CypherAdapterUtils.toSortItems(entityMetaData, pageableSort));
|
||||
}
|
||||
}
|
||||
|
||||
static QueryFragmentsAndParameters forExample(Neo4jMappingContext mappingContext, Example<?> example,
|
||||
|
||||
Reference in New Issue
Block a user