Skip to content
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

DataTable: PageLinks uses prop pageCount instead of totalPages #6647

Closed
MBelniak opened this issue May 22, 2024 · 2 comments · Fixed by #6649, leoo1992/GeradorQRCode#40 or mtech-31-quemistry/quemistry_client_web#3
Assignees
Labels
Type: Bug Issue contains a defect related to a specific component.
Milestone

Comments

@MBelniak
Copy link
Contributor

MBelniak commented May 22, 2024

Describe the bug

In https://github.com/primefaces/primereact/blob/master/components/lib/paginator/PageLinks.js#L76
there is
totalPages: props.pageCount,
instead of
totalPages: props.totalPages,

which issues a problem when using paginator template - the options.totalPages is always undefined.
See https://github.com/primefaces/primereact/blob/master/components/lib/paginator/Paginator.js#L205C79-L205C89 - there is totalPages prop, not pageCount.

Reproducer

No response

PrimeReact version

10.6.5

React version

18.x

Language

TypeScript

Build / Runtime

Create React App (CRA)

Browser(s)

No response

Steps to reproduce the behavior

No response

Expected behavior

No response

@MBelniak MBelniak added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label May 22, 2024
@MBelniak
Copy link
Contributor Author

I will submit a PR this week.

melloware added a commit to melloware/primereact that referenced this issue May 22, 2024
@melloware melloware added Type: Bug Issue contains a defect related to a specific component. and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels May 22, 2024
@melloware melloware self-assigned this May 22, 2024
@melloware melloware added this to the 10.7.0 milestone May 22, 2024
@melloware
Copy link
Member

Thanks @MBelniak i submitted a PR! Sorry I missed that one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a defect related to a specific component.
Projects
None yet
2 participants