Make sure that radio button questions validate correctly and allow only one choice.
authorLennard de Rijk <ljvderijk@gmail.com>
Sat, 04 Jul 2009 14:29:13 +0200
changeset 2530 d7a0ab3f1965
parent 2529 3f2484621f1c
child 2531 855ee76c16a2
Make sure that radio button questions validate correctly and allow only one choice. Reviewed by: Lennard de Rijk
app/soc/views/helper/surveys.py
--- a/app/soc/views/helper/surveys.py	Sat Jul 04 14:22:02 2009 +0200
+++ b/app/soc/views/helper/surveys.py	Sat Jul 04 14:29:13 2009 +0200
@@ -681,10 +681,9 @@
     super(PickManyField, self).__init__(*args, **kwargs)
 
 
-class PickQuantField(forms.MultipleChoiceField):
-  """Stub for customizing the multiple choice field.
+class PickQuantField(forms.ChoiceField):
+  """Stub for customizing the choice field.
   """
-  #TODO(james): Ensure that more than one quant cannot be selected
 
   def __init__(self, *args, **kwargs):
     super(PickQuantField, self).__init__(*args, **kwargs)