Ticket #9638: app_label.patch
File app_label.patch, 663 bytes (added by , 16 years ago) |
---|
-
db/models/fields/related.py
92 92 sup.contribute_to_class(cls, name) 93 93 94 94 if not cls._meta.abstract and self.rel.related_name: 95 self.rel.related_name = self.rel.related_name % {'class': cls.__name__.lower()} 95 self.rel.related_name = self.rel.related_name % { 96 'class': cls.__name__.lower(), 97 'app_label': cls._meta.app_label.lower(), 98 } 96 99 97 100 other = self.rel.to 98 101 if isinstance(other, basestring):