diff options
author | nishanth | 2010-02-25 16:17:56 +0530 |
---|---|---|
committer | nishanth | 2010-02-25 16:17:56 +0530 |
commit | 40adcbfc4a6eb40feb37a35db88ea2ed8a7845a7 (patch) | |
tree | 6229e90f1661361d2ce947ba58bb7802abbd0bea /taskapp/forms | |
parent | a3cda26f529a0994c7086e76d718c4aecc8ecc0b (diff) | |
download | pytask-40adcbfc4a6eb40feb37a35db88ea2ed8a7845a7.tar.gz pytask-40adcbfc4a6eb40feb37a35db88ea2ed8a7845a7.tar.bz2 pytask-40adcbfc4a6eb40feb37a35db88ea2ed8a7845a7.zip |
added capability to remove an assigned user.
Diffstat (limited to 'taskapp/forms')
-rw-r--r-- | taskapp/forms/task.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/taskapp/forms/task.py b/taskapp/forms/task.py index 721110f..24749e0 100644 --- a/taskapp/forms/task.py +++ b/taskapp/forms/task.py @@ -48,3 +48,11 @@ def AssignCreditForm(choices, instance=None): user = forms.ChoiceField(choices=choices, required=True) points = forms.IntegerField(min_value=0,required=True) return myForm(instance) if instance else myForm() + +def RemoveUserForm(choices, instance=None): + + class myForm(forms.Form): + user = forms.ChoiceField(choices=choices, required=True) + reason = forms.CharField(min_length=1, required=True) + return myForm(instance) if instance else myForm() + |