Last modified: 2011-10-11 07:59:05 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T30775, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 28775 - Regression in tablesorting (jquery.tablesorter.js)
Regression in tablesorting (jquery.tablesorter.js)
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
JavaScript (Other open bugs)
1.18.x
All All
: Normal normal (vote)
: ---
Assigned To: DieBuche
:
Depends on:
Blocks: 31601
  Show dependency treegraph
 
Reported: 2011-05-02 00:36 UTC by Owltom
Modified: 2011-10-11 07:59 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Owltom 2011-05-02 00:36:50 UTC
Starting with -r86088 MW uses a "completely rewritten table sorting script" (/resources/jquery/jquery.tablesorter.js)

This doesn't behave like before, when using a date format like dd.mm.yyyy (quite common in german).

Example:

{| class="sortable"
|-
! Date
|-
|11.11.2011
|-
|01.11.2011
|-
|02.10.2011
|-
|03.08.2011
|-
|09.11.2011
|}

used to work in MW before, but isn't sorted correct now. It results in

01.11.2011 
02.10.2011 
03.08.2011 
09.11.2011 
11.11.2011

For backwards compatibility this should be fixed. Sorry for my poor english ;)
Comment 1 DieBuche 2011-05-02 11:32:06 UTC
Fixed in r87243
Comment 2 Brion Vibber 2011-06-07 22:44:45 UTC
We should add test cases for this sort of regression; should be possible to do these with the qunit system.

See under tests/qunit/jquery & the info at http://www.mediawiki.org/wiki/Manual:JavaScript_unit_testing

Basic test structure should go something like this:
* create an HTML table with known structure
* apply the table sorter setup on it
* trigger the table sort for a particular column
* iterate over the table to confirm it sorted correctly
** report success/errors
* remove table & return
Comment 3 Brion Vibber 2011-06-22 22:25:21 UTC
Test cases for this bug added in r90619.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links