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

Fixing resetting of page=0 to 1 #467

Merged
merged 1 commit into from
May 23, 2013
Merged

Fixing resetting of page=0 to 1 #467

merged 1 commit into from
May 23, 2013

Conversation

OlegKi
Copy link
Contributor

@OlegKi OlegKi commented May 23, 2013

Hello Tony,

after writing the answer on stackoverflow I analysed the code of jqGrid where page, lastpage and records are used and especially where page will be read from JSON or XML. The current jqGrid code ignore numeric 0 input value and additionally reset page value 0 to 1 before starting or reloading (in populate).

I suggest to fix the code by usage of existing intNum function which do exactly what one needs. Additional advantage will be conversion of page, lastpage and records directly to number. The parameters will be used in many places of the code in compare operation (like < or ===) and usage numbers simplify the logic. Moreover one will fix additionally wrong input values of page, lastpage and records directly to default values.

Best regards
Oleg

tonytomov added a commit that referenced this pull request May 23, 2013
Fixing resetting of page=0 to 1
@tonytomov tonytomov merged commit db4b24d into tonytomov:master May 23, 2013
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.

None yet

2 participants