6 User management
This chapter covers
- Writing multiuser websites
- Storing user data
- Restricting views to logged-in users
- Preforming authorization in views
- Doing password resets
This chapter introduces you to the features of Django that enable multiuser websites. You’ll learn how user authentication and authorization works, along with the ability to store data linked to a user’s account.
6.1 Multiuser websites
By adding Django Admin functionality to RiffMates, you have already turned it into a multiuser site. At the moment, though, it is rather simplistic: you have administrators who use the Django Admin tools and everybody else. What if you want musicians to be able to edit their own profiles, create bands, and invite people to bands? The primary idea behind RiffMates is to create a space for classified ads, where bands can seek musicians and musicians can seek bands. You could manage all this through email, having the musicians send a note to your admins, but that is a lot of work for your admins. Instead, you want your musicians and others to be able to serve themselves.