Skip to content

Fix onTableLength assigning currentPerPage as string #33

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 1 commit into from
May 28, 2018

Conversation

SafAlhaji
Copy link
Contributor

When changing the number of rows per page, the currentPerPage property gets assigned to a string, and not a number. This results in not viewing all rows when choosing "All", as the identity (triple equality, w/e) operator in the following line will return false:

paginatedRows = paginatedRows.slice((this.currentPage - 1) * this.currentPerPage, this.currentPerPage === -1 ? paginatedRows.length + 1 : this.currentPage * this.currentPerPage);

@thepill thepill merged commit a624010 into MicroDroid:master May 28, 2018
@thepill
Copy link
Collaborator

thepill commented May 28, 2018

thanks @SafAlhaji

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