I've found the solution, initially I was looking in wrong direction.
All I needed to do is to use ``Model.clean()`` method and then call
``Model.full_clean()`` in ``save()``:
from django.contrib.auth.models import User
class CustomUser(User)
def clean(self):
""" Clean username field t
You can probably use a form to do most of what you want, with the caveat
that as long as your restrictions are more restrictive than any db
constraints that auth.User puts in there are.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To view t
I use proxy model class inherited from `django.contrib.models.User`
and I want to apply custom validator to `username` field.
Is threre a way to do this without monkeypatching, as I cannot
override fields in parent class?
--
You received this message because you are subscribed to the Google Grou
3 matches
Mail list logo