title: django models - conditionally set blank=True
body: <p>I am trying to build an app, where user can customize forms. The Following example contains classes for creating Fields (<code>QuestionField</code>, <code>AnswerField</code>) which is used by the admin and the <code>BoolAnswer</code> which is filled by the user: This Way an admin can create a Form with questions and possible answers.</p>
  
  <p>According to django documentation, <code>blank=True</code> is related to evaluation. The problem is that it is set on the class level rather than on object level.</p>
  
  <p>How can I set <code>blank=True</code> depending on the related model so that I do not have to reimplement an own validator? (see pseudo code in <code>BoolAnswer</code>)</p>
  
  <p>My <code>models.py</code>:</p>
  
  <pre><code>class QuestionField(models.Model):
      question = models.TextField(max_length=200)
      models.ForeignKey(Sheet)
  
  
  class BoolAnswerField(AnswerField):
      question = models.ForeignKey(models.Model)
      if_true_field = models.TextField(max_length=100, null=True)
  
  
  class BoolAnswer(models.Model):
      bool_answer_field = models.ForeignKey(BoolAnswerField)
      result = models.BooleanField()
      if_true = models.TextField(max_length=100, null=True,
  
                                 blank=True if self.bool_answer_field.if_true_field)
  </code></pre>
  
  <p>** Short explanation **:
  If the Answer to a <code>BoolAnswerField</code> question is True, <code>if_true</code> field should explain, why</p>