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

Can't sort desc when using pagination #184

Open
nguyen-brian opened this issue Dec 6, 2013 · 16 comments
Open

Can't sort desc when using pagination #184

nguyen-brian opened this issue Dec 6, 2013 · 16 comments
Labels

Comments

@nguyen-brian
Copy link

I'm using 1.0, and my table has pagination. I set up sort on one of my column headers, and it works when I click the column the first time. The second time I click on the header, it does not switch to "desc" sort but rather it stays sorted "asc".

After some investigation I found that the click handler that invokes sorting is being bound twice -- once for my initial List instantiation and once when the Pagination plugin instantiates a List. As a result, the click handler actually fires twice every time I click on the column header, and the "asc" sort keeps overriding the "desc" sort.

Not sure if this issue belongs on the Pagination project or this project, but I'm happy to copy this over to the other project if that's more appropriate.

@sunaj
Copy link

sunaj commented Dec 20, 2013

I'm seeing this problem as well - a fix would be greatly appreciated. Also I see that the Sort functionality is part broken (try sorting on "Description") on: http://sindresorhus.com/bower-components/ - presumably same issue.

@javve
Copy link
Owner

javve commented Dec 21, 2013

It seems like there is some general problems with the sorting, I'll fix it as soon as I get back from my computer-less-vacation!

@sunaj
Copy link

sunaj commented Dec 21, 2013

Sounds good, enjoy your vacation!

On Sat, Dec 21, 2013 at 11:18 AM, Jonny Strömberg
notifications@github.comwrote:

It seems like there is some general problems with the sorting, I'll fix it
as soon as I get back from my computer-less-vacation!


Reply to this email directly or view it on GitHubhttps://github.com//issues/184#issuecomment-31061355
.

@seb-vial
Copy link

Any news on that issue ?

@ccario83
Copy link

Also having this issue. Really like the library, though!

@javve
Copy link
Owner

javve commented Feb 3, 2014

This should be fixed now! Download v1.1.0.

Sorry for the delay. I found some more fishy stuff associated with the sort/pagination.

@javve javve closed this as completed Feb 3, 2014
@javve
Copy link
Owner

javve commented Feb 3, 2014

Oh, remember to visit the changelog -> http://listjs.com/overview/changelog

@ccario83
Copy link

ccario83 commented Mar 3, 2014

Still seem to be having this issue (sort only works once when also using pagination):

http://jsfiddle.net/zpBZY/

Sorry if I'm doing something obviously wrong.

@sunaj
Copy link

sunaj commented Mar 4, 2014

@lucidv01d, don't think you're doing anything wrong. I ended up building
custom clean solution and removing listjs from my project. Epiphany came
after I realized that server-side sort and search is the only viable long
term solution for the data load I'll be dealing with in my app (it is very
easy to underestimate this, see the how many of the listjs examples are
already lagging badly from doing too much frontend rendering)

On Mon, Mar 3, 2014 at 9:38 PM, lucidv01d notifications@github.com wrote:

Still seem to be having this issue (sort only works once when also using
pagination):

http://jsfiddle.net/zpBZY/

Sorry if I'm doing something obviously wrong.

Reply to this email directly or view it on GitHubhttps://github.com//issues/184#issuecomment-36563042
.

@timracer
Copy link

Hi, I'm a newbie in js, I want to use Listjs but with pagination, and I can't connect my own pagination... Could you help me please. I'm glad to use your pagination, but it's without css styles, without "go to first", "prev", "active", "next", "go to last" links. Can you add it to your pagination and highlight active page number via css styles? Or tell me how can I connect this (https://github.com/wesnolte/Pajinate/wiki) pagination via "plugin [ ]" or etc. I'm interest in "Style First/Next and Last/Next" named pagination on this demo page (http://dl.dropboxusercontent.com/u/4151695/html/pajinate/examples/example1.html)
Thank you!

@Tumas
Copy link

Tumas commented May 30, 2014

Issue still exists. I'm using list.js version 1.1.1, list.pagination.js 0.1.1

@helenatxu
Copy link

Hi! This issue shouldn't be closed because is not solved.
I'm using list.js version 1.1.1, list.pagination.js 0.1.1 too. Could you please solve it ASAP?

@daleamann
Copy link

Same issue here as well, pagination isn't working with sorting so I am using a different pagination, but that one isn't working with the sorting either.

@javve javve reopened this Feb 5, 2015
@alexcroox
Copy link

Same here sort doesn't work with the pagination plugin

@yashilanka
Copy link

me too not working.. list.js 1.1.1 and pagination 0.1.1

@javve javve added the Bug label Feb 26, 2016
@tarekbazine
Copy link

plz check this issue i think it's related to this

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