I'm moving my poorly designed SQLite database to the Peewee ORM and having troubles finding a nice way for the following scenario.
I have a DVD table to hold all information about the release itself and tw tables describing a DVD status. Both these tables have specific details for their status. Code example:
class DVD(BaseModel):
title = TextField()
# More info like this
class Sold(BaseModel):
date = DateField()
buyer = TextField()
class Onloan(BaseModel):
loaned = DateField()
back = DateField()
person = TextField()
How would I properly link only one status table to the DVD object so I can access the status data through DVD.status for example?