Symmetrical many-to-many in Django admin screen -
i have symmetrical many-to-many relationship in django
class person(models.model): id = models.charfield(max_length=32, primary_key=true) first_name = models.charfield(max_length=32) last_name = models.charfield(max_length=32) connections = models.manytomanyfield('self', blank=true) how see connections (i.e. myappname_person_connections) table in admin screen (not inline own table)?
e.g. in admin.py
admin.site.register(person) admin.site.register(???) # register connections? thanks
the m2m table mapped model person.connections.through, use
admin.site.register(person.connections.through)
Comments
Post a Comment