Index: openacs-4/packages/bug-tracker/tcl/bug-tracker-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/bug-tracker/tcl/bug-tracker-procs.tcl,v diff -u -r1.11 -r1.12 --- openacs-4/packages/bug-tracker/tcl/bug-tracker-procs.tcl 13 Sep 2002 10:55:53 -0000 1.11 +++ openacs-4/packages/bug-tracker/tcl/bug-tracker-procs.tcl 15 Sep 2002 20:49:44 -0000 1.12 @@ -526,28 +526,33 @@ ad_proc users_get_options { -package_id - -include_unassigned:boolean } { if { ![info exists package_id] } { set package_id [ad_conn package_id] } + set user_id [ad_conn user_id] + # This picks out users who are already assigned to some bug in this set sql { - select distinct - u.first_names || ' ' || u.last_name as name, - u.user_id - from bt_bugs b, cc_users u - where b.project_id = :package_id - and u.user_id = b.assignee + select distinct q.* + from ( + select u.first_names || ' ' || u.last_name as name, u.user_id + from bt_bugs b, cc_users u + where b.project_id = :package_id + and u.user_id = b.assignee + union + select u.first_names || ' ' || u.last_name as name, u.user_id + from cc_users u + where u.user_id = :user_id + ) q order by name } set users_list [db_list_of_lists users $sql] - if { $include_unassigned_p } { - set users_list [concat { { "Unassigned" "" } } $users_list] - } + set users_list [concat { { "Unassigned" "" } } $users_list] + lappend users_list { "Search..." ":search:"} return $users_list } Index: openacs-4/packages/bug-tracker/www/bug.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/bug-tracker/www/bug.tcl,v diff -u -r1.11 -r1.12 --- openacs-4/packages/bug-tracker/www/bug.tcl 13 Sep 2002 10:55:54 -0000 1.11 +++ openacs-4/packages/bug-tracker/www/bug.tcl 15 Sep 2002 20:49:45 -0000 1.12 @@ -221,11 +221,18 @@ } element create bug assignee \ - -datatype user \ - -widget [ad_decode [info exists field_editable_p(assignee)] 1 user inform] \ - -label "Assigned to" \ - -options [bug_tracker::users_get_options -include_unassigned] \ - -optional + -widget [ad_decode [info exists field_editable_p(assignee)] 1 search inform] \ + -datatype search \ + -result_datatype integer \ + -label {Assigned to} \ + -options [bug_tracker::users_get_options] \ + -optional \ + -search_query { + select distinct u.first_names || ' ' || u.last_name as name, u.user_id + from cc_users u + where upper(coalesce(u.first_names || ' ', '') || coalesce(u.last_name || ' ', '') || u.email || ' ' || coalesce(u.screen_name, '')) like upper('%'||:value||'%') + order by name +} element create bug fix_for_version \ -datatype text \