Wednesday, May 2, 2012

app_label of model exception

hello everybody,

i get a exception when i use an model which create form
database(http://djangodays.com/2008/07/07/tip-create-modelspy-from-existing-database/)

exception:
IndexError at /users
list index out of range

code:
kwargs = {"app_label": model_module.__name__.split('.')[-2]}

someone says i shoud setup the app_label,
but i don't know can i setup the app_label.


thank you!

--
-----------------------------------
致礼

何方 cnhefang@gmail.com

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