Django Rest Framework API #21 / Building Custom User Model

  Рет қаралды 15,040

Code Environment

Code Environment

3 жыл бұрын

How to build a custom user model in django rest framework.
Managing user registrations.
Handling super user registration.
Using username , email and password to register a new user.
🎧 Music : • Study music | Programm...
Music Channel : @tuningthecode
Source Code : github.com/CodeEnvironment/dj...
Django Rest Framework API #4/ Django Rest Auth Installation and Testing.
• Django Rest Framework ...
Django Rest Framework API #7 / Authentications, Permissions With Decorators:
• Django Rest Framework ...
Django Rest Framework API #5 / Rest-Auth Registration and Login:
• Django Rest Framework ...

Пікірлер: 45
@nquanta1548
@nquanta1548 4 ай бұрын
Thank you for this wonderful series it is beginner friendly 🎊🔥👍
@NandWebDev
@NandWebDev 3 жыл бұрын
I m the 1st person waiting for your Djangorestframework videos... Upload different concepts in django... Waiting for more videos
@codeenvironment
@codeenvironment 3 жыл бұрын
Thank you, I’m so happy to know that 👍🏻
@pabelandino
@pabelandino 2 жыл бұрын
Thanks, All that I need is here.
@maddynewera
@maddynewera 3 жыл бұрын
you nailed it bro...awesome
@codeenvironment
@codeenvironment 3 жыл бұрын
Thank you 😊
@NandWebDev
@NandWebDev 3 жыл бұрын
Thank you...
@yarik83men51
@yarik83men51 3 жыл бұрын
Super
@jacobidoko3924
@jacobidoko3924 2 жыл бұрын
This channel is sooo underrated....How do you have just over a thousand subscribers? Remember this comment when you hit a 100,000 subs)
@codeenvironment
@codeenvironment 2 жыл бұрын
Thank you So much Jacob for the awesome support, I will definitely remember your comment 👌🏻🙂.
@miteshchakma
@miteshchakma 3 жыл бұрын
Very nice one . can you please make a tutorial on how to upload multiple files using drf ? will be much helpful . Thanks
@ketankulkarni427
@ketankulkarni427 3 жыл бұрын
Awesome video ! Very helpful tutorial. Can you please explain why we have used serializer for Register and ModelSerializer for UserDetails ?
@alihusham1560
@alihusham1560 3 жыл бұрын
I did all that work just for creating an avatar field in the User Model
@shahriarshovo3382
@shahriarshovo3382 2 жыл бұрын
Thank you so much but i have a question. how can a user register without registration view ? because you just created super user . but how to register for a normal user ? where is the view and url?
@stevesteve619
@stevesteve619 3 жыл бұрын
Thanks for the video it’s very helpful, looking forward for more. Please make a video for ManyToMany relationship.
@codeenvironment
@codeenvironment 3 жыл бұрын
Thank you, ManyToMany video is coming soon.
@pacisjules1391
@pacisjules1391 2 жыл бұрын
For real you save me!
@codeenvironment
@codeenvironment 2 жыл бұрын
I’m glad I could help 🙂👍🏻
@arkashvijayakumar4181
@arkashvijayakumar4181 2 жыл бұрын
Sorry I am a little confused. What exactly is the point of the registration serializer, and where should it be called/implemented. If you could link any documentation/videos to clear my confusion it would be a big help. Thanks
@codeenvironment
@codeenvironment 2 жыл бұрын
Mainly to validate the data before at the first level after receiving it from the client
@mohammadsarvi8648
@mohammadsarvi8648 2 жыл бұрын
can i create a custom model based this classes (AbstractBaseUser, BaseUserManager)?
@alihusham1560
@alihusham1560 3 жыл бұрын
Now how to make a views for this?
@rtrvj4467
@rtrvj4467 3 жыл бұрын
It's raising an error during makemigrations.....Application Labels aren't unique duplicates...
@preetiranjansahoo9904
@preetiranjansahoo9904 Жыл бұрын
i am getting this error while doing make migrations. Could you please help me out ? SystemCheckError: System check identified some issues: ERRORS: users.User.owner: (fields.E301) Field defines a relation with the model 'auth.User', which has been swapped out. HINT: Update the relation to point at 'settings.AUTH_USER_MODEL'.
@codeenvironment
@codeenvironment Жыл бұрын
Hello, did you set the AUTH_USER_MODEL in your settings.py file to the new user model you created?
@preetiranjansahoo9904
@preetiranjansahoo9904 Жыл бұрын
@@codeenvironment yes I have added AUTH_USER_MODEL="users.User" in settings.py
@codeenvironment
@codeenvironment Жыл бұрын
You can email me your code to have a look on the “owner” table and relation
@davitgrigoryan6041
@davitgrigoryan6041 2 жыл бұрын
How can I use django rest-auth and allauth with a this Custom User model?
@codeenvironment
@codeenvironment 2 жыл бұрын
Django-rest-auth uses allauth for all its functionalities
@davitgrigoryan6041
@davitgrigoryan6041 2 жыл бұрын
that is, django rest-auth and allauth model no longer works in this case ????????????????????????
@alihusham1560
@alihusham1560 3 жыл бұрын
It shows me 🔴 ERROR: AttributeError: 'Account' object has no attribute 'has_perm'
@codeenvironment
@codeenvironment 3 жыл бұрын
Please email me the code and I’ll try to help you
@alihusham1560
@alihusham1560 3 жыл бұрын
@@codeenvironment thank you, but in fact I sloved it
@codeenvironment
@codeenvironment 3 жыл бұрын
@@alihusham1560 awesome, well done
@orlandog1979
@orlandog1979 3 жыл бұрын
Hello .. Why don't you use the password field in the class User?.....
@codeenvironment
@codeenvironment 3 жыл бұрын
Cause we don’t store the password as plain text in the database. The password gets hashed by Django then gets stored.
@user-mf4ft2gi6l
@user-mf4ft2gi6l 2 жыл бұрын
django.db.utils.OperationalError: no such table: userapp_user ((( Help please
@codeenvironment
@codeenvironment 2 жыл бұрын
Have you run the migrations?
@user-mf4ft2gi6l
@user-mf4ft2gi6l 2 жыл бұрын
@@codeenvironment yes
@user-mf4ft2gi6l
@user-mf4ft2gi6l 2 жыл бұрын
@@codeenvironment django.db.migrations.exceptions.InconsistentMigrationHistory: Migration admin.0001_initial is applied before its dependency userapp.0001_initial on database 'default'.
@codeenvironment
@codeenvironment 2 жыл бұрын
Try deleting the migrations folder the run makemigrations then migrate. If that doesn’t fix the issue you can email me and I’ll assist you further
@dalydaly3576
@dalydaly3576 3 жыл бұрын
please I need help
@codeenvironment
@codeenvironment 3 жыл бұрын
Hello there, what do you need help with?
@ibrahimadiallo5033
@ibrahimadiallo5033 3 жыл бұрын
On voit pas le views
@codeenvironment
@codeenvironment 3 жыл бұрын
We didn’t need to use views for this case
Django Rest Framework API #22 / Many To Many Relationship , Nested Data
31:20
Django API Authentication using JWT Tokens
37:06
Scalable Scripts
Рет қаралды 171 М.
Жайдарман | Туған күн 2024 | Алматы
2:22:55
Jaidarman OFFICIAL / JCI
Рет қаралды 1,7 МЛН
That's how money comes into our family
00:14
Mamasoboliha
Рет қаралды 8 МЛН
Я нашел кто меня пранкует!
00:51
Аришнев
Рет қаралды 3,9 МЛН
Custom Django User Model // DJANGO Tutorial
1:04:40
CodingEntrepreneurs
Рет қаралды 155 М.
Learn Django - Build a Custom User Model with Extended Fields
39:42
Django Rest Framework API #30 / Improve API Response Using Hyperlinks
28:38
A simple guide to chaos theory - BBC World Service
5:10
BBC World Service
Рет қаралды 86 М.
Django REST Framework Oversimplified
9:43
Dennis Ivy
Рет қаралды 304 М.
Why didn't the Angular team just use RxJS instead of Signals?
8:15
Joshua Morony
Рет қаралды 88 М.
Dependency Injection, The Best Pattern
13:16
CodeAesthetic
Рет қаралды 760 М.