I guess my understanding in django models are too shallow and I couldn't come up with a solution even with searching for in the internet. Here is the problem:
I have a MAC Address model that holds mac addresses. Also I have many models that is related to this MAC Address model like PCs, Access Points, Swtiches etc. Since all these models can have multiple network interfaces (ex. A Laptop can have LAN and WLAN interfaces that has different MAC Addresses or a Server can have multiple LAN interfaces) I decided to make a seperate model for MAC Addresses. But I don't really need to see which mac address is related to which asset. So is there a way to make bidirectional one-to-many relationship in django?
class MACAddress(models.Model):
addr = models.CharField(_('MAC Address'), max_length=17)
class AccessPoint(models.Model):
#...
# This property must be in a form of list or array.
mac_addresses = models.OneToManyField(MACAddress)
Something like that is possible? I saw some Many-to-one relationship examples but all of them shows just how to get related model data. (ex. In a User, Contact model relationship, examples shows how to get User model from Contact model. Which I need the other way around)