I would like to have through table for ManyToManyField mapped with Tortoise model (not just table name). It is useful for adding additional columns to such relation.
Additional context
https://docs.djangoproject.com/en/3.0/ref/models/fields/#django.db.models.ManyToManyField.through
+1
+1
I think the major problem is that the through table is been created in the generate_schema() by the M2M relation and the generate_schema() is failling.
@andrzejpiasecki Did you get any work around the make it work ?
This is a feature I wanted to add for a long while. And it's not much work. I'll add it to the 0.17 project as tentative, and will get to it soon.
Hmm, I will have to trim 0.17 features to make it realistic.
My team also encountered this issue: we were planning to have an id with a function as its default, but it's not possible as the ManyToManyField cannot use a Model as its through.
It would be perfect if we can have this feature implemented :)
Most helpful comment
My team also encountered this issue: we were planning to have an
idwith a function as its default, but it's not possible as theManyToManyFieldcannot use a Model as itsthrough.It would be perfect if we can have this feature implemented :)