Allow percentage sorting
authorJamie Cameron <jcameron@webmin.com>
Thu, 30 Apr 2009 05:46:42 +0000 (05:46 +0000)
committerJamie Cameron <jcameron@webmin.com>
Thu, 30 Apr 2009 05:46:42 +0000 (05:46 +0000)
blue-theme/unauthenticated/sorttable.js

index 9a6476b..5014a68 100644 (file)
@@ -79,7 +79,7 @@ function ts_resortTable(lnk,clid) {
     if (itm.match(/^[\d\.]+\s*(bytes|b|kb|tb|gb|mb)$/i)) sortfn = ts_sort_filesize;
     // Special cases for our mailbox lists
     if (itm.match(/^(Empty|Unlimited)$/)) sortfn = ts_sort_filesize;
-    if (itm.match(/^[\d\.]+$/)) sortfn = ts_sort_numeric;
+    if (itm.match(/^[\d\.]+%?$/)) sortfn = ts_sort_numeric;
     SORT_COLUMN_INDEX = column;
     var firstRow = new Array();
     var newRows = new Array();