From 15eacfd446bc3ecb7e121d67e9770b367465fc86 Mon Sep 17 00:00:00 2001 From: Sam Nicholls Date: Mon, 21 Jan 2013 00:28:11 +0000 Subject: [PATCH] User column sorts only multi-sorts by [Active,A-z] --- views/users/users.jade | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/views/users/users.jade b/views/users/users.jade index 35b2dca..4ef3022 100644 --- a/views/users/users.jade +++ b/views/users/users.jade @@ -23,7 +23,9 @@ block content $('.data').dataTable({ "aoColumnDefs": [ - { "sType": "forcenum", "aTargets": [ 1, 2, 3, 4, 5 ] } + { "aDataSort": [ 1, 0 ], "asSorting": [ "asc" ], "aTargets": [ 0 ] }, + { "bVisible": false, "aTargets": [ 1 ] }, + { "sType": "forcenum", "aTargets": [ 2, 3, 4, 5, 6 ] } ], "bPaginate": false, "bLengthChange": false, @@ -32,7 +34,6 @@ block content "sInfoEmpty": "No users", "sInfoFiltered": "filtered (_MAX_ total)" }, - "aaSorting": [], // Disable initial sort }); }); @@ -44,6 +45,7 @@ block content thead tr th Users + th th Lines th Words th Lincent @@ -63,6 +65,14 @@ block content span.label.label-important Inactive else span.label Offline + td + if nick.online + if nick.active + -1 + else + 0 + else + 1 td #{nick.fields.lines.data} td