Multi column sorting issue
Multi column sorting issue
Hi all
So I am having an issue with multi-column sorting. I have a table of resources and I want to sort first by the resource type (alphabetically) and then by the distance (closest first). The resource type column is getting sorted but the distance is not. I modeled my code after the example and can't seem to find anything wrong. This is on a salesforce platform by the way.
Here is the code:
[code]
$(".tablesorterJob").dataTable( {
"bSort": true,
"aaSorting": [[1,'asc'], [5,'asc']],
"sScrollY": "200px",
"sScrollX": "100%",
"bAutoWidth": true,
"aoColumnDefs": [
{ "sWidth": "30px", "aTargets": [ 0 ]},
{ "sType": "string-case", "aTargets": [ 5 ]}
],
"bPaginate": true,
"bJQueryUI": true,
"iDisplayLength": 10,
"bLengthChange": false
} );
[/code]
Could this be an issue with the different types of data that I am trying to sort?
Resource type is column 1 with type string and distance is column 5 of type number.
Thanks in advance
Nick
So I am having an issue with multi-column sorting. I have a table of resources and I want to sort first by the resource type (alphabetically) and then by the distance (closest first). The resource type column is getting sorted but the distance is not. I modeled my code after the example and can't seem to find anything wrong. This is on a salesforce platform by the way.
Here is the code:
[code]
$(".tablesorterJob").dataTable( {
"bSort": true,
"aaSorting": [[1,'asc'], [5,'asc']],
"sScrollY": "200px",
"sScrollX": "100%",
"bAutoWidth": true,
"aoColumnDefs": [
{ "sWidth": "30px", "aTargets": [ 0 ]},
{ "sType": "string-case", "aTargets": [ 5 ]}
],
"bPaginate": true,
"bJQueryUI": true,
"iDisplayLength": 10,
"bLengthChange": false
} );
[/code]
Could this be an issue with the different types of data that I am trying to sort?
Resource type is column 1 with type string and distance is column 5 of type number.
Thanks in advance
Nick
This discussion has been closed.
Replies
Beyond that we would need a test case showing the problem.
Allan
Allan