Ignore:
Timestamp:
May 15, 2010, 9:59:33 PM (15 years ago)
Author:
Alex Dehnert <adehnert@…>
Branches:
master, fysm-4-1, iframe, space-access, stable, stage, test-hooks
Children:
c27da9e
Parents:
f921734
git-author:
Alex Dehnert <adehnert@…> (05/15/10 21:59:33)
git-committer:
Alex Dehnert <adehnert@…> (05/15/10 21:59:33)
Message:

Oops, make groups actually selectable.

I think I hate Python's semantics for giving formal parameters values, but
maybe I'm just confused.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • asadb/forms/views.py

    rf921734 r2f7114b  
    2525class SelectGroupForm(Form):
    2626    group = ModelChoiceField(queryset=groups.models.Group.objects.all())
    27     def __init__(self, queryset=None, *args, **kwargs):
     27    def __init__(self, *args, **kwargs):
     28        queryset = None
     29        if 'queryset' in kwargs:
     30            queryset = kwargs['queryset']
     31            del kwargs['queryset']
    2832        super(SelectGroupForm, self).__init__(*args, **kwargs)
    2933        if queryset is not None:
Note: See TracChangeset for help on using the changeset viewer.