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

fix(openchallenges): change paginator variable to dynamic rendering #2426

Merged
merged 4 commits into from
Jan 17, 2024

Conversation

rrchai
Copy link
Contributor

@rrchai rrchai commented Jan 16, 2024

As we added a new condition to not the paginator element if no data found, the variable of paginator is undefined initially as it is static, which caused the error ^.

Changelogs

  • Change the paginator to dynamic, so its value will be set after the content is fully initialized
  • Use PrimeNG built-in property alwaysShow=false to hide the paginator when there is only one page
  • Update page index on paginator UI once the pageNumber of param in a pasted url presents
  • Disable the pageSize changes from the pasted url

@rrchai rrchai self-assigned this Jan 16, 2024
@rrchai
Copy link
Contributor Author

rrchai commented Jan 16, 2024

Noticed two new bugs a new bug related to the search pages:

  • Copy & paste the pagination in url does not reflect the page number changes on the paginator UI. For example, entering http://localhost:4200/challenge?pageNumber=6 should show page number 7, but it stays page number 1.

  • There are some "Upcoming" challenges in the result, but selecting "Upcoming" status filter shows no results not reproduced today after the changes

@rrchai rrchai marked this pull request as ready for review January 17, 2024 16:11
@tschaffter tschaffter merged commit cfa1cbd into Sage-Bionetworks:main Jan 17, 2024
8 checks passed
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.

[Bug] search bar on search pages failed
2 participants