Hello,
I am trying not to repeat myself, but without model inheritance, I am
struggling a bit.
For example, I have a series of models that model various things.
They all have the following fields
date_added
date_modified
name
def __str__(self):
return self.name
Beyond that, they are different to each other, but have various
relationships. I thought model inheritance was working, so I created
a base class that had these fields, then all my remaining models
inherited from the base class. The database fields were created
correctly, and adding works - but beyond that I cannot read the data
using the api.
Is there a better way to define common fields for models? Compositing
perhaps? :)
Thanks,
Paul
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---