Interesting yeah, why not create a "new" user model inheriting from
AbstractBaseUser, and have it _not_ be a proxy model? It should have pretty
much the same effect. You may need to say class Meta: db_table =
'auth_user'.
--
You received this message because you are subscribed to the Google Gr
Hi Andrew,
My custom model looks like this:
from django.contrib.auth.models import User
class MyUser(User):
class Meta:
proxy = True
def my_custom_method(self):
return "Something"
This is a proxy class and it's only scope is to extend the User model with
a method. And h
Hi Izabella,
Could you provide your custom user model declaration?
According the the documentation, you should be inheriting from
`AbstractBaseUser`.
https://docs.djangoproject.com/en/1.7/topics/auth/customizing/#substituting-a-custom-user-model
https://docs.djangoproject.com/en/1.7/topics/auth
t;
>> Could you, please, help me to find the right way to create proxy to User
>> model in Django 1.7?
>>
>> In 'myapp.models.py' I have a MyUser class which should inherit from the
>> user model specified in settings.AUTH_USER_MODEL:
>>
>> If
On Friday, 12 September 2014 19:54:53 UTC+1, Izabella Gál wrote:
>
> Hi!
>
> Could you, please, help me to find the right way to create proxy to User
> model in Django 1.7?
>
> In 'myapp.models.py' I have a MyUser class which should inherit from
Hi!
Could you, please, help me to find the right way to create proxy to User
model in Django 1.7?
In 'myapp.models.py' I have a MyUser class which should inherit from the
user model specified in settings.AUTH_USER_MODEL:
If I am using the get_user_model() method, I r
6 matches
Mail list logo