Tag clouds: Hiding "uncategorized" category if no uncategorized tags exist
[prawokultury.git] / questions / forms.py
index 3a80db1..77ea6e7 100755 (executable)
@@ -2,7 +2,13 @@ from django.forms import ModelForm
 from .models import Question
 
 class QuestionForm(ModelForm):
+    required_css_class = 'required'
+
     class Meta:
         model = Question
         fields = ['email', 'question']
-        # TODO: honeypot!
+
+    def save(self, *args, **kwargs):
+        instance = super(QuestionForm, self).save(*args, **kwargs)
+        instance.ack_author()
+        return instance