carljm/django-model-utils — Issue #7: No select_related possible with InheritanceManager
Author: thibault
Created: 2011-12-14 10:42:09+00:00
State: open

Since the InheritanceQuerySet uses `select_related` to join children objects, all previous `select_related` calls will be discarded. Exemple:

class Product(models.Model):
objects = InheritanceManager()
client = models.ForeignKey('clients.Client')
price = models.PositiveIntegerField()

class Shirt(Product):
color = …

class Pants(Product):
…

products = Product.objects.all().select_related('client').select_subclasses() #client table will not be joined