-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Start the server and open the browser at localhost:8000. Try to login with the credentials of the superuser. It will not work. Find out why the login does not work and fix it.
✓ The reason login wasn't working was because the login form doesn't have {% csrf_token %} which is very essential in every django forms
Now that you are logged in, you will see the profile update screen. As you will see when trying to update your user, there are two problems:
The form does not work The information on the screen is not properly updated to the new data Please fix these two issues.
Now have a look at the user model. There is a field which is called occupation. We want the user to be able to update this field as well. Add the field to the form and make sure everything works as expected.
✓ The reason the update form doesn't work was because the hx-swaps in the form is pointing into non-existent element ID and the multiswap is pointing into outerHTML so i changed it into innerHTML, Then it was dynamically rendered and I ensure the occupation is being updated by checking django's built-in admin panel
Now it is time to develop a whole new feature. We want to enable the user to invite other users to the web application.
Your todo:
Create a modal which opens on click of an Ìnvite button on the profile page. Let the user enter the email and click submit Create an invitation model using the ORM where you store all invitations After submitting the invite, send an email to the invited user. (Use the normal django console backend for that, which just prints the email content to the terminal. It is already setup in the setttings.) Think about a concept on how to finish this feature and discuss it with the interviewer Out of scope:
Sending the email Building the "Accept Invitation" view and logic
✓ What would i recommend for additional feature in this area is an Automated follow-up emails and an Automated thank you if the recipient replies or clicked the link. If i were given the task for this additional feature i would integrate it with LLM