我有三个模型:
class Model_1(models.Model):
...
class Model_2(models.Model):
m1 = models.ManyToManyField(Model_1,...
...
class Model_3(models.Model):
m2 = models.ManyToManyField(Model_2,...
...
我得到Model_1的对象:
object = Model_1.objects.get(id=my_id)
如何从对象中获取相关的 Model_3?