← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] lp:~jcsackett/launchpad/personpicker-advanced-search into lp:launchpad

 

j.c.sackett has proposed merging lp:~jcsackett/launchpad/personpicker-advanced-search into lp:launchpad.

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~jcsackett/launchpad/personpicker-advanced-search/+merge/71613

Summary
=======
This is a really simple branch to update the advanced bug search form so that its person related search fields use the personpicker popup.

Pre-implementation notes
========================
Spoke with Curtis Hovey.

Implementation details 
======================
Within the form declaration, this branch adds custom_widget directives for the person based fields (e.g. assignee, bug_supervisor, bug_reporter). The custom_widget directives force the form to use the PersonPickerWidget, which includes the improvements to the personpicker we've done in earlier branches.

Tests
=====
bin/test -vvct test_bugtask

QA
==
On an advanced bug search page, with the personpicker enhancments feature flag enabled, confirm the fields show the personpicker. This is most easily confirmed by seeing that the pickers show the "Pick me" link.


= Launchpad lint =

Checking for conflicts and issues in changed files.

Linting changed files:
  lib/lp/bugs/browser/bugtask.py
-- 
https://code.launchpad.net/~jcsackett/launchpad/personpicker-advanced-search/+merge/71613
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~jcsackett/launchpad/personpicker-advanced-search into lp:launchpad.
=== modified file 'lib/lp/bugs/browser/bugtask.py'
--- lib/lp/bugs/browser/bugtask.py	2011-08-12 04:10:40 +0000
+++ lib/lp/bugs/browser/bugtask.py	2011-08-15 22:29:26 +0000
@@ -183,6 +183,7 @@
     )
 from lp.app.widgets.itemswidgets import LabeledMultiCheckBoxWidget
 from lp.app.widgets.launchpadtarget import LaunchpadTargetWidget
+from lp.app.widgets.popup import PersonPickerWidget
 from lp.app.widgets.project import ProjectScopeWidget
 from lp.bugs.browser.bug import (
     BugContextMenu,
@@ -2219,6 +2220,11 @@
     custom_widget('tag', BugTagsWidget)
     custom_widget('tags_combinator', RadioWidget)
     custom_widget('component', LabeledMultiCheckBoxWidget)
+    custom_widget('assignee', PersonPickerWidget)
+    custom_widget('bug_reporter', PersonPickerWidget)
+    custom_widget('bug_commenter', PersonPickerWidget)
+    custom_widget('bug_supervisor', PersonPickerWidget)
+    custom_widget('subscriber', PersonPickerWidget)
 
     @cachedproperty
     def bug_tracking_usage(self):