Systers, an AnitaB.org community
Add Password Confirmation functionality to Registration process (Mentorship - Backend)
Prerequisites:
Complete the task given here of setting up the mentorship-backend repository locally.
Outline of the task:
- On POST/register, add a functionality for password confirmation
- Add a new input field for entering 'Confirm Password'
- Check if 'Password' and 'Confirm Password' are the same
- If YES, perform SUCCESSFUL registration
- If NO, return a new exception
Steps:
- Make the following changes locally (steps 2-4).
- In the register_user_api_model, add a new field for 'Confirm Password'. Models are available under this folder.
- In the 'messages.py', add a new ERROR message with key as 'PASSWORD_CONFIRMATION_MISMATCH' and value as ' The 2 password fields do not match. '
- In the Data Access Object(DAO) layer for User functionalities, add a condition to match the passwords under the 'create_user' function to create the User, otherwise, throw the ERROR message made above. DAOs are available under this folder
- Commit your changes using our Commit message Style Guide.
- Submit a Pull Request, against
gci-dev
branch, using the template against the listed issue. - Submit a swagger screenshot of successful registration [#Screenshot 1] and a screenshot of unsuccessful registration because of passwords not being matched [#Screenshot 2].
Work Submission:
Submit a link to Pull Request (PR) created with the changes as listed in the GitHub issue, and the 2 screenshots
Resources:
- If you need help or get lost, post a response to our Participant Questions in our #gci stream.
Task tags
Students who completed this task
_daksha_, asawesome07