Monday, January 31, 2011

Django Admin select boxes

Hi all, I am hoping that someone might be able to point me in the right
direction for the following problem. I have been searching for a few days now
and haven't been able to find a way to accomplish this. I have found some
solutions that are close, but only work on editing an entry, not on add.
I have models for the following:
Each have a foreign key to the model above it.
Country
Prov/State
City
Region
Community
Is there a way in the Django admin to filter the values in the select boxes
based on the selection in the previous select box? eg: I select Canada in the
country select box, then in the Prov/State select box I am only presented with
the Provinces. Once that is selected, the City select box only presents cities
within the Province selected. etc...
Is this possible?

--
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.

No comments:

Post a Comment