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 receive the
'django.core.exceptions.AppRegistryNotReady: Models aren't loaded yet.'
exception
class MyUser(get_user_model()):
class Meta:
proxy = True
def my_method(self):
return 'hello'
And if I replace the get_user_model() method with
settings.AUTH_USER_MODEL, I receive another exception: TypeError: Error
when calling the metaclass bases
str() takes at most 1 argument (3 given)
In settings.py I have: AUTH_USER_MODEL = 'auth.User'
Thanks in advance!
Izabella