Index: openacs-4/packages/dotlrn/tcl/community-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/tcl/community-procs.tcl,v diff -u -r1.143 -r1.144 --- openacs-4/packages/dotlrn/tcl/community-procs.tcl 5 Jun 2002 18:16:55 -0000 1.143 +++ openacs-4/packages/dotlrn/tcl/community-procs.tcl 7 Jun 2002 04:47:38 -0000 1.144 @@ -643,8 +643,18 @@ {-rel_type dotlrn_member_rel} community_id } { - Returns the list of users with a membership_id, a user_id, first name, last name, email, and role + Returns the list of users with a membership_id, a user_id, first name, + last name, email, and role } { + return [util_memoize "dotlrn_community::list_users_not_cached -rel_type $rel_type -community_id $community_id"] + } + + ad_proc -private list_users_not_cached { + {-rel_type:required} + {-community_id:required} + } { + Memoizing helper + } { return [db_list_of_ns_sets select_users {}] } @@ -716,6 +726,8 @@ -user_id $user_id \ -member_state $member_state } + + util_memoize_flush "dotlrn_community::list_users_not_cached -rel_type $rel_type -community_id $community_id" } ad_proc -public add_user_to_community { @@ -831,6 +843,9 @@ # Remove it relation_remove $rel_id + + # flush the list_users cache + util_memoize_flush "dotlrn_community::list_users_not_cached -rel_type $rel_type -community_id $community_id" } } Index: openacs-4/packages/dotlrn/tcl/community-procs.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/tcl/community-procs.xql,v diff -u -r1.69 -r1.70 --- openacs-4/packages/dotlrn/tcl/community-procs.xql 3 Jun 2002 21:16:28 -0000 1.69 +++ openacs-4/packages/dotlrn/tcl/community-procs.xql 7 Jun 2002 04:47:38 -0000 1.70 @@ -125,7 +125,7 @@ - + select dotlrn_member_rels_approved.rel_id, dotlrn_member_rels_approved.rel_type, Index: openacs-4/packages/dotlrn/www/admin/users-oracle.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/admin/Attic/users-oracle.xql,v diff -u -r1.11 -r1.12 --- openacs-4/packages/dotlrn/www/admin/users-oracle.xql 7 Jun 2002 03:19:55 -0000 1.11 +++ openacs-4/packages/dotlrn/www/admin/users-oracle.xql 7 Jun 2002 04:47:38 -0000 1.12 @@ -14,7 +14,7 @@ select count(*) from ( select acs_rels.object_id_two from acs_rels - where acs_rels.object_id_one = acs.magic_object_id('registered_users') + where acs_rels.object_id_one = (select acs.magic_object_id('registered_users') from dual) MINUS select acs_rels.object_id_two from acs_rels, dotlrn_user_types @@ -29,7 +29,7 @@ from persons, acs_rels, membership_rels - where acs_rels.object_id_one = acs.magic_object_id('registered_users') + where acs_rels.object_id_one = (select acs.magic_object_id('registered_users') from dual) and acs_rels.object_id_two = persons.person_id and acs_rels.rel_id = membership_rels.rel_id and membership_rels.member_state = 'banned'