tarstarkes / Icarus

Grande Ronde Model Watershed - Site Rebuild
0 stars 0 forks source link

USER_LOGIN - Use email instead of username for site login #32

Closed tarstarkes closed 7 years ago

tarstarkes commented 7 years ago

With so many sites using email instead of username for login, this is a desirable feature. It should be relatively easy to lookup the username by querying the database for a specific email; however, I will have to make the email field unique; otherwise, if one user tries to make a second account when they already have one, an error would occur, also if two emails existed in the database for one account; how would we know which email the user meant when they went to login?

tarstarkes commented 7 years ago

User emails are now unique. The admin should in theory still be able to manually create a user with the same email address so do keep this in mind. Additionally the functionality to login by email address is now a reality from the login page; although users will still have to create a username to satisfy django's login by username criteria.