Index: openacs-4/packages/contacts/www/index.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/contacts/www/index.tcl,v diff -u -r1.22 -r1.23 --- openacs-4/packages/contacts/www/index.tcl 5 Apr 2006 22:11:10 -0000 1.22 +++ openacs-4/packages/contacts/www/index.tcl 1 May 2006 19:54:52 -0000 1.23 @@ -65,16 +65,17 @@ set contacts_total_count "$contacts_total_count" } +if { [exists_and_not_null search_id] } { + contact::search::log -search_id $search_id +} set public_searches [lang::util::localize_list_of_lists -list [db_list_of_lists public_searches {}]] set search_options [concat [list [list [_ contacts.All_Contacts] ""]] $public_searches] set searchcount 1 db_foreach my_recent_searches {} { lappend search_options [list "${searchcount}) ${recent_title}" ${recent_search_id}] incr searchcount } - if { [exists_and_not_null search_id] } { - contact::search::log -search_id $search_id set search_in_list_p 0 foreach search_option $search_options { if { [lindex $search_option 1] eq $search_id } { Index: openacs-4/packages/contacts/www/index.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/contacts/www/index.xql,v diff -u -r1.7 -r1.8 --- openacs-4/packages/contacts/www/index.xql 12 Oct 2005 18:51:54 -0000 1.7 +++ openacs-4/packages/contacts/www/index.xql 1 May 2006 19:54:52 -0000 1.8 @@ -15,15 +15,16 @@ - select cs.title as recent_title, + select ao.title as recent_title, cs.search_id as recent_search_id - from contact_searches cs, contact_search_log csl + from contact_searches cs, contact_search_log csl, acs_objects ao where csl.user_id = :user_id and cs.search_id = csl.search_id - and cs.title is not null + and cs.search_id = ao.object_id + and ao.title is not null and cs.owner_id != :package_id and not cs.deleted_p - order by last_search desc + order by csl.last_search desc limit 10