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 "Order table previous/next pagination buttons" bug #2885 #2904

Merged
merged 3 commits into from
Sep 20, 2017

Conversation

efalayi
Copy link
Contributor

@efalayi efalayi commented Sep 20, 2017

Resolves #2885
Previous/Next pagination button do not work

canNext and canPrevious are boolean values that control the click function of these pagination buttons. From previous implementation, they were negated.

if (!canPrevious) {
  return this.changePage(page - 1);
}

if (!canNext) {
  return this.changePage(page - 1);
}
Fix
  • Remove negation from canNext and canPrevious
if (canPrevious) {
  return this.changePage(page - 1);
}

if (canNext) {
  return this.changePage(page - 1);
}
Test
Have 5+ orders
Set number of rows to 5
Click on the active Next button to navigate to the next page
Observe that change in items/list displayed

Copy link
Contributor

@kieha kieha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍🏽

Copy link
Collaborator

@brent-hoover brent-hoover left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested. Verified fixed. I love a good two byte fix.

@brent-hoover brent-hoover merged commit a2ff998 into marketplace Sep 20, 2017
@brent-hoover brent-hoover deleted the esther-fix-issue-2885 branch September 20, 2017 23:06
@spencern spencern mentioned this pull request Oct 11, 2017
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.

3 participants