﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
13789	related manager does not limit correctly on a proxy model	Shaun Cutts	nobody	"If I have a proxy of a model, the related manager does not correctly limit related items.

E.g.

{{{
class Profile( models.Model ):

 # ...

class Location( models.Model ):
    home_of = models.ForeignKey( Profile, related_name= 'locations' )

class ProxyProfile( Profile ):
    class Meta:
        proxy = True

}}}
Now if I have a particular Profile p with one location, its related manager
will give me the correct number of objects, but not when accessed via the proxy:

{{{
>>> Location.objects.count()
1000
>>> p = Profile.objects.get( pk = 1234 )
>>> p.locations.count()
1
>>> pp = ProxyProfile.objects.get( pk = 1234 )
>>> pp.locations.count()
1000
}}}   "		closed	Database layer (models, ORM)	1.2		invalid		shaun@…	Unreviewed	0	0	0	0	0	0
