Setting a preferred item of a many-to-one in Django
- by Mike DeSimone
I'm trying to create a Django model that handles the following:
An Item can have several Names.
One of the Names for an Item is its primary Name, i.e. the Name displayed given an Item.
(The model names were changed to protect the innocent.)
The models.py I've got looks like:
class Item(models.Model):
primaryName =…