Professional Documents
Culture Documents
CST 336 Final Project
CST 336 Final Project
Description: Our project created a Candy Store website, where customers can shop for their
favorite candy bars. Users can shop for candy bars and other selection criteria and can put
them in their shopping cart and checkout. Administrators are able to add, update, and delete
records. Reports are available for the administrator to run.
Mockup:
● Home page: Allows users to see available items, they click on a cart icon to put items in
their cart. They can change the list of items they are viewing based on the bars having
nuts or not. If a user reloads their cart is preserved in the database.
● Cart: shows the images of the items in the cart, price, quantity, line item total and overall
total in the cart.
● Admin login page: requests and validates admin email address and password (use:
email = admin@p5.com password = secret to login)
● Admin page: update existing items, add items, delete items, and get reports.
Database Schema:
● p_bars: contains the item data name, wrapper color, nuts (yes/no), type of nut, size of
the bar in ounces, and price. Images are referenced by the bar_id where the image
names are all bar_id.jpg.
● p_cart : tracks the data on the items that have been placed in the cart by the user.
● p_inventory: tracks the inventory levels of the items
● p_authentication: is used for managing the administrator usernames and passwords.
Screenshots:
Navbar is uniform across all pages. Focus changes when navigating to different pages.
Clicking Pentagration Candy Company takes you to the homepage.
After logging out you are taken to the homepage.
There are three cart icons: Cart empty, cart full, out of stock
Cart empty and cart full can be toggled, out of stock cannot be toggled.
Filter buttons Users can change the items shown on the homepage by
clicking on the buttons.
The cart buttons continue to work when clicked in each filtered view and
update the cart.
Cart displays contents with
picture, price, quantity, and line
item total. Cart Total is also
displayed with data provided by
the p_cart table in the database.
Admin table is pre-populated with data from the database. Values can be changed and will
take effect with the update item button. Items can also be deleted.
Add item lower on the admin page items can be added to the database.
Documentation must include Title, Description, Mockup, Database Schema and Screenshots -20pts
(documentation meets requirements)
(if
Project must use at least four database tables
(p_bars, p_cart, p_authentication, p_inventory) missing any)
Feature requirements:
There is a "user" section in which users can search and filter data using at least three fields 10pts
(Yes, the user can filter selection by clicking on buttons which query three different fields p_bars.nut,
p_bar.wrap_color, p_inventory.qty_instock)
Users can see all items in their cart (Total cost is also displayed) 10pts
(Yes, by going to the cart view the user can see their items and the total)
Administrators can update content of at least one table (using pre-populated data in the form) 10pts
(Yes, after logging in the administrator is given the ability to modify the pre-populated data for existing items,
update / delete buttons update the database also)
Administrators can generate at least three reports, which use aggregate functions (e.g., average price of all 10pts
products in the table)
(Yes, the administrator can get average price, average calories, and a table of results for the color of the candy
wrappers)
Project uses at least two AJAX calls with their corresponding Web APIs. 10pts
As part of your submission, please explain where the AJAX calls are.
(Yes, there are numerous Ajax calls initiated in the functions.js file inside the public/js folder)
Project has a nice and consistent design (preferably, use Bootstrap) 10pts
(Yes, we used a bootstrap template and made modifications for our purpose on the main page, we also used
another bootstrap template for the admin login page.)