-
Notifications
You must be signed in to change notification settings - Fork 754
Closed
Description
Hello!
Following scenario: I have a table with columns A, B, C, and D. All the columns excepting the C are sortable. The Default sorting is: D [DESC], A [ASC] . Working fine. But now I want to add a further column (D) to the sorting (SCHIFT + click on the column's head).
Expected behavior: The primary and the secondary sorting remain as they are. A tertiary sorting (by D) is added. The table is sorted by three columns.
Observed behavior: The primary and the secondary sorting get reset. The table is now sorted only by the column D.
My code:
$(function () {
$("#content .table").tablesorter({
textExtraction: function (node, table, cellIndex) {
n = $(node);
return n.attr('data-normalized') || n.text();
},
headers: {
2: {
sorter: false
}
},
cancelSelection: true,
sortList: [
[3,1], [0,0]
],
widgets : ['columns'],
widgetOptions : {
columns : ['primary', 'secondary', 'tertiary'],
columns_thead : true,
columns_tfoot : true
}
});
});
For me it seems to be a bug, but maybe it's just about configuration?..
Best regards,
Ilya