第一种:ManyToMany自动创建(需要掌握)
第二种:纯手动创建(了解即可)
class Book(models,Model):
name = ...
class Author(models,Model):
name = ...
class Book2Author(models,Model):
book = ...
author=...
第三种:半自动创建(需要掌握)
class Book(models,Model):
name = ...
authors = (through,through_fields=('book','author'))
class Author(models,Model):
name = ...
class Book2Author(models,Model):
book = ...
author=...