Common - many fixes (#15395)
This commit is contained in:
@@ -14,12 +14,16 @@ export const getPageInfo = (
|
||||
limit: number,
|
||||
isForwardPagination: boolean,
|
||||
): CommonPageInfo => {
|
||||
const { hasNextPage, hasPreviousPage } = getPaginationInfo(
|
||||
const { hasNextPage, hasPreviousPage, hasMoreRecords } = getPaginationInfo(
|
||||
records,
|
||||
limit,
|
||||
isForwardPagination,
|
||||
);
|
||||
|
||||
if (hasMoreRecords) {
|
||||
records.pop();
|
||||
}
|
||||
|
||||
const startCursor =
|
||||
records.length > 0 ? encodeCursor(records[0], orderBy) : null;
|
||||
const endCursor =
|
||||
|
||||
Reference in New Issue
Block a user