de.
>
> Does that make sense?
>
> On Nov 9, 2:39 pm, refreegrata wrote:
>
> > ok, thanks for the answer, but I want use the clean method in a model,
> > not in a form. For that in the clean method I throw a ValidationError,
> > but the error message isn't asso
ut a model doesn't work like that as it would only
be manipulated directly in python code.
Does that make sense?
On Nov 9, 2:39 pm, refreegrata wrote:
> ok, thanks for the answer, but I want use the clean method in a model,
> not in a form. For that in the clean method I throw a Valid
ok, thanks for the answer, but I want use the clean method in a model,
not in a form. For that in the clean method I throw a ValidationError,
but the error message isn't associated to the field form of the
modelform.
On 8 nov, 19:17, cootetom wrote:
> If you want to associate an er
shows how to associate a error with a specific field
in a form class.
On Nov 8, 8:40 pm, refreegrata wrote:
> Hello list. I want to use the clean method in a model.
> --
> class myModel(models.Model):
> fields
>
>
Hello list. I want to use the clean method in a model.
--
class myModel(models.Model):
fields
def clean(self):
raise ValidationError('The Error.')
---
Thats works fine. M
5 matches
Mail list logo