Wednesday, March 7, 2012

Why on_delete attribute is not available on GenericForeignKey?

The django docs says:
Unlike ForeignKey, GenericForeignKey does not accept an on_delete
argument to customize this behavior; if desired, you can avoid the
cascade-deletion simply by not using GenericRelation, and alternate
behavior can be provided via the pre_delete signal.

Does anyone knows why? I mean, is it for some conceptual/technical
reason that makes it impractical to implement or is it because nobody
put efforts to make it happen? Or maybe GFK are not so well integrated
with the ORM and as soon as they become integrated, then this feature
will come for free?

Thanks!
--
Marc

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate