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

Server Side search pagination #142

Closed
cubasepp opened this issue Jun 9, 2015 · 9 comments
Closed

Server Side search pagination #142

cubasepp opened this issue Jun 9, 2015 · 9 comments
Assignees
Labels
Milestone

Comments

@cubasepp
Copy link

cubasepp commented Jun 9, 2015

Hi,

for example.
If you stay on page 5 and search for something and the result has only 2 pages you get an empty response from the server. Because the ngTasty doesn't reset the page attribute after the filter function was called. ( // AngularJs $watch callbacks if ($attrs.bindFilters) { .. })

Maybe you have to reset the page attribute so you get a result.

http://zizzamia.com/ng-tasty/directive/table-server-side/complete you can see it on your demo.

go on page 4 and search for something on page 1 but your page attribute stays on 4 so you see no result.

@ranjithdharmaraj
Copy link

Yes, I have the same issue..I see from the past issues that this was reported earlier but closed as fixed.
Ex: http://zizzamia.com/ng-tasty/directive/table-server-side/complete. Go to page 3 and then enter "wicked" in Filter by name text field.
It does not bring up the one record that exists

@Zizzamia Zizzamia self-assigned this Jun 13, 2015
@luigima
Copy link

luigima commented Jun 23, 2015

Don' t know why #98 should be fixed, I have the same issue with version "0.5.4 - 2015-05-04".

Maybe we should add a "bind-pagination" attribute to the ngTasty directive? We could reset the page manually then.

@Zizzamia
Copy link
Owner

Please update ng-tasty to the version 0.5.5 and let me know if the error it still present. ThankYou

@luigima
Copy link

luigima commented Jun 23, 2015

No, same issue with 0.5.5..

@Zizzamia
Copy link
Owner

Ou ok! I will fix this for the version 0.5.6

@Zizzamia Zizzamia added this to the Version 0.5.6 milestone Jun 23, 2015
@cubasepp
Copy link
Author

You have to reset the page attribute at the URL.
"table.json?sort-by=name&sort-order=dsc&page=3&count=5&name=Wick"

The result have only 1 page but we display Page 3... ;)

Thx Zizzamia

@Zizzamia
Copy link
Owner

Just release the version 0.5.6

@thesilverbadger
Copy link

0.5.6 has fixed the issue with the page not resetting on a new search, however the pagination buttons (5, 25, 50, 100 and 1-5 etc) no longer page through the resultset or change the number of returned results when clicked. They only take effect when the search is subsequently manually performed.

Do you want me to raise a new issue for this?

@Zizzamia
Copy link
Owner

@thesilverbadger yes please, looks a serious to fix a soon as possible.
Can you open a new issue by showing the code that you are using and tell me the action you doing.
Will make my work faster.
#ThankYou

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants