Skip to content

Fix partial pagination which no longer returns the "hydra:next" property #4015

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Feb 8, 2021

Conversation

meyerbaptiste
Copy link
Member

@meyerbaptiste meyerbaptiste commented Feb 2, 2021

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tickets fixes #3967 (comment)
License MIT
Doc PR n/a

@jeremyteyssedre confused $pageTotalItems with the total number of items in the collection. $pageTotalItems is the number of items in the current page. As a reminder, with the partial pagination we cannot determine if it is the last page. Because of this, we will always have the hydra:next property, even on the last page. It is an "assumed bug".

cc @clementtalleu

@meyerbaptiste meyerbaptiste force-pushed the fix_partial_pagination branch 3 times, most recently from 9ff295c to 382957a Compare February 2, 2021 18:00
@soyuka soyuka added this to the 2.6.2 milestone Feb 2, 2021
@soyuka soyuka modified the milestones: 2.6.2, 2.6.3 Feb 6, 2021
@meyerbaptiste meyerbaptiste force-pushed the fix_partial_pagination branch from 382957a to 725e66a Compare February 8, 2021 09:28
@soyuka soyuka merged commit a5196ae into api-platform:2.6 Feb 8, 2021
@soyuka
Copy link
Member

soyuka commented Feb 8, 2021

thanks @meyerbaptiste !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants