소스 검색

auto update script executed

Toby Chui 1 년 전
부모
커밋
bbcfa49046
1개의 변경된 파일3개의 추가작업 그리고 2개의 파일을 삭제
  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;