Hi, I have the following (pseudocode) models.py:
class Attachment: file = FileField(upload_to=...) type = CharField(max_length=2, choices=ABSTRACT_CHOICES) lang = CharField(max_length=2, choices=LANG_CHOICES) # some other fields, too... class Meta: abstract = True class FooAttachment(Attachment): foo = models.ForeignKey(Foo) # I want to change the type choices=ABSTRACT_CHOICES here class BarAttachment(Attachment): bar = models.ForeignKey(Bar) # and here So, my question is: Is this possible (without too much hackery). It is not a big problem if I need to define the whole field again for every concrete subclass of Attachment, but it would be nicer if there is something similar to form's 'self.fields["type"].choices = BAR_CHOICES'. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---