-
Notifications
You must be signed in to change notification settings - Fork 266
Open
Milestone
Description
Is it possible add auto patch of unique_together:
# geo/models.py
class Location(models.Model):
# ...
class Meta:
# ...
unique_together = (('parent', 'name', ), )
# translation.py
class LocationTranslationOptions(TranslationOptions):
fields = ('name', 'body',)
translator.register(Location, LocationTranslationOptions)
Location._meta.unique_together += tuple(
(('parent', i) for i in get_translation_fields('name'))
)
Metadata
Metadata
Assignees
Labels
No labels