diff options
author | Dan McGee <dan@archlinux.org> | 2010-03-06 16:20:35 +0100 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2010-05-17 17:38:44 +0200 |
commit | 8116500afca190d6d87292ec08a9dff18a1bb261 (patch) | |
tree | 8f814fb90a5347c26b96c93a254e6f51ec196683 | |
parent | c7e8686f191e5a8b0e814055835df9c71f1521a9 (diff) | |
download | archweb-8116500afca190d6d87292ec08a9dff18a1bb261.tar.gz archweb-8116500afca190d6d87292ec08a9dff18a1bb261.tar.xz |
Make group membership use Django groups
Rather than our home-baked roles field, which is free text so we really
shouldn't be checking against anyway. It also prevents people from being
both a developer and a TU.
Signed-off-by: Dan McGee <dan@archlinux.org>
-rw-r--r-- | public/views.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/public/views.py b/public/views.py index 912801f..eaa5734 100644 --- a/public/views.py +++ b/public/views.py @@ -21,10 +21,10 @@ def index(request): def userlist(request, type='Developers'): users = User.objects.order_by('username') if type == 'Developers': - users = users.filter(is_active=True).exclude(userprofile_user__roles="Trusted User") + users = users.filter(is_active=True, groups__name="Developers") msg = "This is a list of the current Arch Linux Developers. They maintain the [core] and [extra] package repositories in addition to doing any other developer duties." elif type == 'Trusted Users': - users = users.filter(is_active=True, userprofile_user__roles="Trusted User") + users = users.filter(is_active=True, groups__name="Trusted Users") msg = "Here are all your friendly Arch Linux Trusted Users who are in charge of the [community] repository." elif type == 'Fellows': users = users.filter(is_active=False) |