From b192bb76d0dccccc0749c982d57c3f88945c8484 Mon Sep 17 00:00:00 2001 From: Adam Young Date: Fri, 6 Aug 2010 15:09:29 -0400 Subject: Remove search field on group button Hide the search bar when showing the groups listed for a user, and resotre it when doing other searches. The enroll button is added only on the groups page, and removed along with anything else in the searchButtons div when a new search is started. --- install/static/user.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'install/static/user.js') diff --git a/install/static/user.js b/install/static/user.js index f91fc01b..53a84359 100644 --- a/install/static/user.js +++ b/install/static/user.js @@ -66,7 +66,7 @@ function renderUserLinks(current, cell){ }).appendTo(cell); $("",{ - href: "#tab=user&facet=details&pkey="+current.uid, + href: "#?tab=user&facet=group&pkey="+current.uid, click:setupUserGroupMembership, html: "[G]" }).appendTo(cell); @@ -243,16 +243,14 @@ function populateUserEnrollments(userData){ function setupUserGroupMembership(){ - $("#searchButtons").html(""); - + showSearch(); + $("#filter").css("display","none"); $("",{ type: 'button', value: 'enroll', click: setupUserGroupEnrollmentSearch }).appendTo("#searchButtons"); - - showSearch(); var columnHeaders = document.createElement("tr"); for (var i =0 ; i != groupMembershipColumns.length ;i++){ var th = document.createElement("th"); -- cgit