django model inherit custom manager -


i cannot make django model inherit custom manager parent class. have done following:

class baseclassmanager(models.manager):     """manager baseclass"""  class baseclass(models.model):     """     baseclass subclass     introspection shows class has manager of type baseclassmanager      """     objects = baseclassmanager()  class subclass(baseclass):     """     subclass     introspection shows class has manager of type models.manager     want have baseclassmanager manager     """ 

i can imagine has how metaclass builds model. have way make subclass inherit baseclass's manager? dit seems if inheritance of managers desirable feature.

your assistance appreciated.

the inheritance problem solved placing

class meta:     abstract = true 

in base class.


Comments

Popular posts from this blog

Add email recipient to all new Trac tickets -

400 Bad Request on Apache/PHP AddHandler wrapper -

php - Change action and image src url's with jQuery -