Re: submit form as superuser vs regular user

2017-09-21 Thread Melvyn Sopacua
It doesn't reach form_valid because the form is not valid. It reaches `form_invalid`. You can inspect things there for debugging. But the error is probably with your authentication backed, since request.user is not filled in. The obvious being that your superuser exists in `auth_user` and other use

Re: submit form as superuser vs regular user

2017-09-19 Thread Avraham Serour
not sure if related, but the docs suggest to inherit from AbstractUser, not User https://docs.djangoproject.com/en/1.11/topics/auth/customizing/ On Mon, Sep 18, 2017 at 12:58 PM, Danae Vogiatzi wrote: > In my django app I have a Myuser(User) class. It inherits the User class. > When a new user

submit form as superuser vs regular user

2017-09-18 Thread Danae Vogiatzi
In my django app I have a Myuser(User) class. It inherits the User class. When a new user is created the Myuser table is poplulated. myusers.py class Myuser(User): address = models.CharField(max_length=40) pobox = models.CharField(max_length=40) models.py class Someclass(models.Mode