Fixed FELIX-2245 /Log Plugin - level sorting should be by level/
https://issues.apache.org/jira/browse/FELIX-2245

git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@933957 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/webconsole/src/main/resources/res/ui/logs.js b/webconsole/src/main/resources/res/ui/logs.js
index 2d6f00f..acfdcec 100644
--- a/webconsole/src/main/resources/res/ui/logs.js
+++ b/webconsole/src/main/resources/res/ui/logs.js
@@ -55,7 +55,7 @@
 		case 4: level = i18n.debug; break;
 	}
     parent.appendChild( td( null, null, [ text( printDate(dataEntry.received) ) ] ) );
-    parent.appendChild( td( null, null, [ text( level ) ] ) );    
+    parent.appendChild( td( null, { lvl:dataEntry.raw_level }, [ text( level ) ] ) );    
     parent.appendChild( td( null, null, [ text( wordWrap(message) ) ] ) );
     parent.appendChild( td( null, null, [ text( wordWrap(service) ) ] ) );
     parent.appendChild( td( null, null, [ text( exception ) ] ) );
@@ -82,6 +82,14 @@
     	    renderData(data);
     	}, "json");
     });
+		// init tablesorte
+	$('#plugin_table').tablesorter({
+		textExtraction: function(node) {
+			var _ = $(node);
+			return _.attr('lvl') ? _.attr('lvl') : _.text();
+		}
+	});
+	
 	logsElem  = $("#logs");
     logs2Elem = $("#logs2");
 	tableElem = $("#plugin_table");
diff --git a/webconsole/src/main/resources/templates/logs.html b/webconsole/src/main/resources/templates/logs.html
index 17aba1a..f58995f 100644
--- a/webconsole/src/main/resources/templates/logs.html
+++ b/webconsole/src/main/resources/templates/logs.html
@@ -32,7 +32,7 @@
 </form>
 
 <div id="logs2">
-<table id="plugin_table" class="tablesorter nicetable">
+<table id="plugin_table" class="tablesorter nicetable noauto">
 	<thead>
 		<tr>
 			<th class="col_Received">${log.received}</th>