Consider the following models
in models.py:
class Volunteer(models.Model):
account = models.OneToOneField(
UserAccount,
on_delete=models.CASCADE,
related_name= "volunteer",
primary_key=True)
request_offers = models.ManyToManyField('Request', related_name="volunteers", blank = True)
volunteer_communities = models.ManyToManyField('Community', related_name="volunteers", blank = True)
class Request(models.Model):
req_type = models.ForeignKey('RequestTypes', related_name="requests", on_delete = models.CASCADE, blank = False, null = False)
A volunteer can have many request_offers(type of request).
In the implicit appname_volunteer_request (many-to-many) table, I want another field called date besides the default fields -- id, request_id and volunteer_id.
Is there a way to add an additional field on the implicit table without creating a through table?
Thanks! :)