From bf66bb1009c7e70b8c27999695f58b90b4196f6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adolfo=20G=C3=B3mez?= Date: Tue, 18 Mar 2014 00:52:51 +0000 Subject: [PATCH] Fixed authenticators details tab change bug --- .../uds/static/adm/js/gui-d-authenticators.coffee | 9 ++++++--- server/src/uds/templates/uds/admin/index.html | 12 ++++++------ 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/server/src/uds/static/adm/js/gui-d-authenticators.coffee b/server/src/uds/static/adm/js/gui-d-authenticators.coffee index 65653aa4f..7dd39a03d 100644 --- a/server/src/uds/static/adm/js/gui-d-authenticators.coffee +++ b/server/src/uds/static/adm/js/gui-d-authenticators.coffee @@ -17,8 +17,8 @@ gui.authenticators.link = (event) -> $tbl = $(detailLogTable).dataTable() $tbl.fnClearTable() $tbl.fnDestroy() - $("#user-log-placeholder").empty() detailLogTable = undefined + $("#users-log-placeholder").empty() return @@ -26,13 +26,14 @@ gui.authenticators.link = (event) -> # Memory saver :-) prevTables = [] clearDetails = -> + clearDetailLog() + $.each prevTables, (undefined_, tbl) -> $tbl = $(tbl).dataTable() $tbl.fnClearTable() $tbl.fnDestroy() return - clearDetailLog() $("#users-placeholder").empty() $("#groups-placeholder").empty() $("#logs-placeholder").empty() @@ -260,6 +261,7 @@ gui.authenticators.link = (event) -> container: "users-placeholder" rowSelect: "single" onRowSelect: (uselected) -> + gui.doLog 'User row selected ', uselected gui.tools.blockUI() uId = uselected[0].id clearDetailLog() @@ -284,7 +286,8 @@ gui.authenticators.link = (event) -> return onRefresh: -> - $("#users-log-placeholder").empty() # Remove logs on detail refresh + gui.doLog "Refreshing" + clearDetailLog() return onEdit: (value, event, table, refreshFnc) -> diff --git a/server/src/uds/templates/uds/admin/index.html b/server/src/uds/templates/uds/admin/index.html index c9799861e..ceb3cb4c7 100644 --- a/server/src/uds/templates/uds/admin/index.html +++ b/server/src/uds/templates/uds/admin/index.html @@ -44,12 +44,9 @@ - - - + + {% compress js %} - +