Make DefaultReviewer aware of LocalSites.

Review Request #2040 — Created Jan. 15, 2011 and submitted

Information

Review Board

Reviewers

Make DefaultReviewer aware of LocalSites.

DefaultReviewer wasn't tied to a LocalSite, making it impossible to see
which ones exist when not bound to a Repository or Group. It now stores the
LocalSite, and the DefaultReviewerForm performs validation to ensure that
the repositories, users and groups selected match the LocalSite in order to
prevent people or code from linking to objects on other LocalSites.
Unit tests pass.
david
  1. Just one comment.
  2. reviewboard/reviews/forms.py (Diff revision 1)
     
     
    It's more efficient to do this:
    
    if not user.local_site.filter(pk=local_sitepk).exists():
  3.