How to make recursive ManyToManyField relationships that have extra fields symmetrical in Django?

前端 未结 5 754
后悔当初
后悔当初 2020-12-18 07:53
class Food_Tag(models.Model):
    name = models.CharField(max_length=200)
    related_tags = models.ManyToManyField(\'self\', blank=True, symmetrical=False, through=         


        
5条回答
  •  盖世英雄少女心
    2020-12-18 08:32

    I found this approach made by Charles Leifer which seems to be a good approach to overcome this Django limitation.

提交回复
热议问题