Friday, January 25, 2013

Model and ModelForm validation

Hi everybody.

I am reading this [0] and can't perfectly understand what this line means:

"Note that full_clean() will not be called automatically when you call
your model's save() method, nor as a result of ModelForm validation.
You'll need to call it manually when you want to run one-step model
validation for your own manually created models."

Specifically, I am referring to "nor as a result of ModelForm
validation". Does it mean full_clean() is not called during ModelForm
validation? I was pretty sure it is... Am I wrong? Am I misunderstanding
that English line (I am not a native speaker)?

Cheers, Fabio.

[0]
https://docs.djangoproject.com/en/1.4/ref/models/instances/#django.db.models.Model.full_clean

--
Fabio Natali

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

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate