taskapp/forms/task.py
changeset 25 c0e4fc8b8b5b
parent 22 36d3173ab7f9
child 50 d40e86f958f7
--- a/taskapp/forms/task.py	Thu Feb 04 23:13:03 2010 +0530
+++ b/taskapp/forms/task.py	Thu Feb 04 23:15:37 2010 +0530
@@ -19,3 +19,11 @@
     class Meta:
         model = Claim
         fields = ['message']
+
+def AssignTaskForm(choices, instance=None):
+    """ return a form object with appropriate choices """
+    
+    class myform(forms.Form):
+        user = forms.ChoiceField(choices=choices, required=True)
+    form = myform()
+    return form