feedback/forms.py
author nishanth
Tue, 29 Jun 2010 16:12:29 +0530
changeset 103 ee9261c5ba18
parent 94 5de0009c0d71
permissions -rwxr-xr-x
the list_attendees page looks better now

from django import forms

from ws_app.feedback.models import Feedback

class FeedbackForm(forms.ModelForm):
    """ A form to collect the feedback.
    """

    class Meta:
        model = Feedback
        exclude = [ 'event', 'day']

    def clean_comments(self):
        comments = self.cleaned_data['comments']
        return comments.strip()