Questions tagged [django-custom-user]

Tag for questions related to custom User model functionality introduced in Django 1.6

268 questions
0
votes
1 answer

Identify the custom user model in REST_FRAMEWORK settings Django

I'm new in Django rest_framework. I'm using a custom user model and djoser as my authentication system. I want to use my custom user model in the djoser register view and I don't know how to identify that in the rest_framework…
0
votes
1 answer

How do I create Groups for custom users in Django?

I created a Custom User Model by basically copying and pasting the full example given in the Django Docs. But in the docs, they unregistered groups. But in my project I will need groups because I'll have different uper types. So how can I still have…
Imran Rahman
  • 126
  • 5
0
votes
3 answers

Django Allauth Confirmation/verification email not sent after signing up

I am using a Custom user model and so far I have been able to hook it into the allauth package extending the "SignupForm". Everything seems to work fine because I sign up and the information about the new account is in the DB (user table and…
0
votes
2 answers

How to register a normal user in django from front end using custom user model?

# Custom User Model Code from django.db import models from django.contrib.auth.models import ( BaseUserManager, AbstractBaseUser ) class MyUserManager(BaseUserManager): def create_user(self, email, favorite_color, password=None): …
0
votes
0 answers

Django user registration with phone and password

i am creating custom user model in django using abstract base user class, i want to create user with only two fields "phone and password " and name being the optional field , which i have set in my models .py that blank =true. i have created a rest…
0
votes
1 answer

How to properly use custom user model in django, with custom templates instead of forms.py

Can any one please tell me how to use Custom User model in django, so that user can register from front end. Or is there any way of creating new table for storing users and use the authentication of user model with that custom model. # Custom User…
0
votes
1 answer

Django Blog comment author reference

I built a small Django Blog application with a comment section. Users are required to login before making a post or comment. I want to return the full name of my CustomUser in both the Blog posts and comments in my templates. After a Blog post, the…
0
votes
1 answer

Django:What is best way to import my Custom-User in views.py?

Actually i have created my own custom-user (MyUser) in models.py from django.db import models from django.contrib.auth.models import AbstractUser class MyUser(AbstractUser): country=models.CharField(max_length=20) settings.py AUTH_USER_MODEL =…
Maninder Singh
  • 425
  • 6
  • 14
0
votes
1 answer

Django:Problems related creating custom user

I'm trying to creating a custom user in django with AbstractUser class. code of models.py where i defined my custom_user. from django.db import models from django.contrib.auth.models import AbstractUser class MyUser(AbstractUser): …
0
votes
1 answer

How to add more features to user permission in django?

I am new to django. I want to edit default user auth_permissions. More precisely I want to add an integer field in addition to "label", "code" features to distinct permission types (like strong, moderate and etc.). So far I could not find anything…
0
votes
1 answer

how to extend AbstractBaseUser with OneToOneFeild in django

I created AbstractBaseUser model and a BaseManager. the model.py is given below GENDER_CHOICES = (('M', 'Male'),('F', 'Female')) class AccountManager(BaseUserManager): def…
0
votes
2 answers

Email forms do not match in Django Custom-User registration

I'm setting up a custom-user registration form to create an account on my Django project. I feel I'm missing something very simple that keeps me from registering for some reason. My registration form demands 4 fields to be filled before a new user…
chenard612
  • 101
  • 2
  • 15
0
votes
1 answer

Manager isn't available; 'auth.User' has been swapped for 'users.CustomUser'

I am new to Django and I am trying to implement custom user authentication for my website. When I try to create a new user for the signup view, I get the error 'Manager isn't available; 'auth.User' has been swapped for 'users.CustomUser'. Creation…
0
votes
1 answer

Why am I receiving IntegrityError (1062, "Duplicate entry '' for key 'username'")?

I am receiving the following error (1062, "Duplicate entry '' for key 'username'") even though I haven't provided a username field at all. I am trying to save the updated info of the user in its existing Account table. Can you please help me…
Suraj Ingle
  • 372
  • 4
  • 18
0
votes
1 answer

How to overcome a ImportError?

In my project I want to realize a custom user model which is included in my users app and included to my settings, that has an entry for a project that is currently worked on. So my user model should look like this from django.db import models from…
g0rill4z
  • 3
  • 2