Re: ManyToManyField select only results that match
kleurogen = models.ManyToManyField(Keuzes, blank=True, null=True)
kleurhaar = models.ManyToManyField(Keuzes, blank=True, null=True)
django.core.management.base.CommandError: One or more models did not validate:
profielen.profielen: Accessor for m2m field 'kleurogen' clashes with related m2m field 'Keuzes.profielen_set'. Add a related_name argument to the definition for 'kleurogen'.
profielen.profielen: Accessor for m2m field 'kleurhaar' clashes with related m2m field 'Keuzes.profielen_set'. Add a related_name argument to the definition for 'kleurhaar'.
and when i do this is shows all the results again instead of the selected
kleurogen = models.ManyToManyField(Keuzes, related_name='keuzes_kleurogen', blank=True, null=True)
kleurhaar = models.ManyToManyField(Keuzes, related_name='keuzes_kleurhaar', blank=True, null=True)
what am i doing wrong?
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home