From 4649d4a1ce7a83087fe460a43a659e4df62ee9f5 Mon Sep 17 00:00:00 2001 From: Andrew Williams Date: Wed, 22 Dec 2010 22:20:12 +0000 Subject: [PATCH] Attempt to fix the search form problem --- sso/forms.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sso/forms.py b/sso/forms.py index c31e80a..1e6ba3b 100644 --- a/sso/forms.py +++ b/sso/forms.py @@ -117,10 +117,13 @@ class UserLookupForm(forms.Form): def __init__(self, *args, **kwargs): super(UserLookupForm, self).__init__(*args, **kwargs) + choices = [ (1, "Auth Username"), + (2, "Character"), + (4, "Email Address"), ] if installed('reddit'): - self.choices.append((3, "Reddit ID")) + choices.append((3, "Reddit ID")) - self.fields['type'] = forms.ChoiceField(label=u'Search type', choices=self.choices) + self.fields['type'] = forms.ChoiceField(label=u'Search type', choices=choices) self.fields['username'] = forms.CharField(label = u'User ID', max_length=64) class APIPasswordForm(forms.Form):