How would I remove an object from a many-to-many relationship without deleting the object itself?
Example:
I have models of Moods and Interest .
Mood many-many-many models.ManyToManyField(Interest) interests (these are models.ManyToManyField(Interest) ).
I am creating an instance of Moods called my_mood . In my_moods interests my_moods I have my_interest , i.e.
>>> my_mood.interests.all() [my_interest, ...]
How can I remove my_interest from my_mood without deleting any model instance? In other words, how to remove a link without affecting related models?
django many-to-many
Nayish Jun 13 2018-11-11T00: 00Z
source share