Browse Source

auto update script executed

Toby Chui 1 year ago
parent
commit
bbcfa49046
1 changed files with 3 additions and 2 deletions
  1. 3 2
      web/script/tablesort.js

+ 3 - 2
web/script/tablesort.js

@@ -107,8 +107,9 @@
 		asc: 'sorted ascending',
 		desc: 'sorted descending',
 		compare: function(a, b) {
-			if (Number.isInteger(a) && Number.isInteger(b)){
-				return a-b;
+			if (!isNaN(parseInt(a.trim())) && !isNaN(parseInt(b.trim())) ){
+				a = parseInt(a);
+				b = parseInt(b);
 			}
 			if (a > b) {
 				return 1;