You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 17, 2019. It is now read-only.
If you just change the sort slightly then you can handle numerical values in order rather than the sort by text. This was a real problem for me for someone so thought I would share it with you.
sortOptCallback: function(a, b) {
if( a == b) return 0;
var anum = parseInt(a.val,10);
var bnum = parseInt(b.val,10);
if( isNaN(anum) || isNaN(bnum)) {
return a.text.toLowerCase() > b.text.toLowerCase() ? 1 : -1;
}
return anum > bnum ? 1 : -1;
},