Click here to watch a screencast where I present the design and functionality of my e-commerce website.
I plan to have my shopping cart be on a separate page that the user can view and edit to their liking (adding or removing quantities). I thought that it would be nice to have a side bar shopping cart, so that users can just edit their quantities and shopping cart without being directed to another page, but I’m not confident about accomplishing this. If I feel that I have the time, I might challenge myself with making the shopping cart a side bar feature. I have a purchase button on the products display page at the moment, but I will probably change this to something like “add to cart.” If the user selects valid quantities and is logged in, they will be sent to the shopping cart page. On the shopping cart page, there would be a “complete purchase” button and a “continue shopping” button. The “complete purchase” button would redirect the user to the invoice page where they can view what they purchased.
I will use sessions to manage my shopping cart by storing cart information, such as the products selected and the selected quantities for each product in the session. I plan to have an array of product objects that each hold information about the specific product. An example of what this would look like is: request.session['soda']=[{"name":"Mitsuya Cider", "price": 2, "qty_purchased":2}];
In Assignment 2, I prevented unauthorized access to the invoice by checking whether or not the user’s email was in the query URL. I can also do this with cookies (like in the Lab 14 Cookies and Sessions Lab) by using an if statement to check if the cookies has the user’s username. If it exists, then the user will proceed to the invoice, and if not, they will be directed to the login page. In this assignment, I will also have to log out a user after a period of inactivity for security purposes.
Upon a successful login, I plan to provide personalization in my UI by changing the login tab on the nav bar to display the user’s username. The user can click on this tab to log themselves out. I also have a user-personalized thank you message on the invoice page that addresses the user by their username. I plan to implement these personalization ideas through accessing my cookie and session data.
I am not working with a partner.
With the Assignment 3 Extra Credit opportunity, I will be forced to list all of the tasks for this assignment in advance, which will help me stay organized and visualize what exactly I need to do. I did this midway of doing Assignment 2, which helped with my progress, so I hope that my journey to finishing Assignment 3 will be smoother than it was for Assignment 2.