Re: Widget.SortableTable: secondary sort always desc?

2 views
Skip to first unread message

alexander dosher

unread,
Jul 29, 2007, 11:40:25 PM7/29/07
to jsan-a...@googlegroups.com
Sorry, got distracted by something shiny & wandered away for awhile

> I'm the author, and patches are welcome ;)
>
> Seriously, the secondary sort should follow the rules for defaulting:
>
> * If a direction is explicitly specified for that column, use it. *
> Otherwise look at the type and use the default for that type (aka, dates
> descending, everything else ascending). * If we can't figure out the type,
> use ascending.
>
> So if the secondary column sort bits aren't working like that, there's a
> bug.


Here's a fairly simple example that demonstrates what i'm seeing:

http://home.pacbell.net/alyx/test/tabletest.html

It's entirely likely that i've bollixed up the columnSpecs object or
something, but if not, this might be an issue.

TIA,

--alex.


Dave Rolsky

unread,
Jul 30, 2007, 5:35:11 PM7/30/07
to jsan-a...@googlegroups.com
On Sun, 29 Jul 2007, alexander dosher wrote:

> Here's a fairly simple example that demonstrates what i'm seeing:
>
> http://home.pacbell.net/alyx/test/tabletest.html
>
> It's entirely likely that i've bollixed up the columnSpecs object or
> something, but if not, this might be an issue.

It _is_ sorting on the secondary column, but it's sorting it in the same
direction as the primary sort column, which is often going to come out
looking weird, as in your example.

I think the fix is to respect the defaultDir parameter for the secondary
sort column and do the right thing, which should be _too_ hard.


-dave

/*===================================================
VegGuide.Org www.BookIRead.com
Your guide to all that's veg. My book blog
===================================================*/

alyx

unread,
Jul 30, 2007, 5:53:36 PM7/30/07
to JSAN Authors
> ... which should be _too_ hard.

oh dear. no fix, then? ;-)

Dave Rolsky

unread,
Jul 30, 2007, 6:05:21 PM7/30/07
to JSAN Authors
On Mon, 30 Jul 2007, alyx wrote:

>
>> ... which should be _too_ hard.
>
> oh dear. no fix, then? ;-)

Err, s/should/shouldn't/

I already have a fix, and it should be on JSAN shortly.

Reply all
Reply to author
Forward
0 new messages