Django Registration and Authentication
Posted on Jun 29th, 2020
You’ve now seen how to handle data in a Django application with basic operations in these categories:
- Create - when we add a new model instance to the database
- Read - when we query the database to look up existing data
- Update - when we query the database to find existing data so we can change it
- Destroy - when we query the database to find data that we want to delete
At the heart of many web applications you’ll find variations on this theme, so we’ll continue to practice it.
Today we’ll add in another essential part of web applications: user registration and login.
Django Music project review
- What was one AHA 💡 moment you had?
- What did you spend the most time ⏲️ on?
- What is something that you’d like to understand better 🤔?
Project: Freeshelf
This is a 3-day assignment that you’ll work on all week. It is due on Thursday, July 2.
Resources
- Momentum Django project template
- django-registration-redux
- Python dependency management overview - good read to understand pip and poetry better
- Django docs: Authentication in Web Requests ->
django-registation-redux
handles some of this for us (giving us the login and logout urls, for instance) but it’s helpful to see other ways you can use the authenticated user.