(bug 36991) Fix jquery.tablesorter date sorting
authorBrad Jorsch <anomie.wikipedia@gmail.com>
Sun, 20 May 2012 18:10:09 +0000 (14:10 -0400)
committerTimo Tijhof <ttijhof@wikimedia.org>
Tue, 3 Jul 2012 17:05:01 +0000 (19:05 +0200)
commit35169448068e979000669b1a22a4e9dda25f943a
tree787094aa46629982f8451913817c35b66b96518a
parent1fc2bb9b0ecab78b26a600ad36139d30493f480a
(bug 36991) Fix jquery.tablesorter date sorting

jquery.tablesorter should extract date sort format from date string
instead of global config. Dates like "April 1 2012" and "1 April 2012" now sort correctly regardless of the content language's
DefaultDateFormat setting (exposed as wgDefaultDateFormat in
mw.config).

Previously jquery.tablesorter sorted dates like "1 Apr 2012" (DMY) or
"Apr 1 2012" (MDY) incorrectly. It just converted it to "1 4 2012"
and "4 1 2012", respectively, and then assumes MDY or DMY order based
on the global wiki configuration.

This patch fixes that.

Change-Id: I8061b1a7892633e34be4d4a0273a4dd5045fd2ee
RELEASE-NOTES-1.20
resources/jquery/jquery.tablesorter.js
tests/qunit/suites/resources/jquery/jquery.tablesorter.test.js