Cleaned Data Different Access?
In a Form subclass, why do we have to use
self.cleaned_date['fieldname'] in the clean_fieldname() method and
self.cleaned_data.get("fieldname") in the clean() method for the form
overall? In the clean_fieldname() method, we're looking up the
cleaned python object / value in the cleaned_data dictionary of the
form. In the form's clean() method, it looks like we're pulling the
value from, as the documentation puts it, the final cleaned_data
attribute? Why the difference? At some point, we're no longer
getting a dictionary for cleaned data?
--
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