I have an ajax form which updates the status field of a table's status
column dynamically. I send the table name, and the Id to be replaced to the
ajax processor, but when I try to call
what = model_name.objects.get(Id=id_number)
django barks at me like this;
Traceback:
File "/usr/lib/pymodules/python2.6/django/core/handlers/base.py" in get_response
92. response = callback(request, *callback_args,
**callback_kwargs)
File "/home/www/django/adm/ajax/views.py" in statusUpdate
15. what = model_name.objects.get(Id=id_number)
Exception Type: AttributeError at /adm/ajax/statusUpdate/
Exception Value: 'unicode' object has no attribute 'objects'
How can I use a unicode string as a model instance?
--
Omer Barlas
omer.bar...@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-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en.