Difference between revisions of "Grocery Guru"

From ESE205 Wiki
Jump to navigation Jump to search
(images)
Line 91: Line 91:
  
 
== Final App Layout ==
 
== Final App Layout ==
 
 
<gallery>
 
<gallery>
[[File:unnamed.png|385.5px|201px|thumb|Home Screen: the opening page of the app]]
+
File:unnamed.png|Home Screen: the opening page of the app
[[File:cartdelete.png|385.3px|201px|thumb|Shopping list: display all items currently in your cart, as well as the option to add / delete items]]
+
File:cartdelete.png|Shopping list: display all items currently in your cart, as well as the option to add / delete items
[[File:notification.png|385.3px|201px|thumb|Notification of the item not in stock]]
+
File:notification.png|Notification: tell you when your item is not in stock
[[File:Groc8.png|385.3px|201px|thumb|Barcode Scanner: alerts the user when a barcode has been detected]]
+
File.Groc8|Barcode Scanner: alerts the user when a barcode has been detected
[[File:updatestock.png|385.3px|201px|thumb|Stock Update: a slider can be adjusted in order to update the amount of items left in stock]]
+
File:updatestock.png|Stock Update: a slider can be adjusted in order to update the amount of items left in stock
[[File:search.png|385.3px|201px|thumb|Manual Search: allows the user to type the name of an item to add it to their list and / or see how many are left in stock]]
+
File:search.png|Manual Search: allows the user to type the name of an item to add it to their list and / or see how many are left in stock
</gallery>
 
 
 
<gallery>
 
File:unnamed.png
 
File:cart delete.png
 
 
</gallery>
 
</gallery>
  

Revision as of 14:52, 1 May 2017

Members

  • Maggie Archer,
  • Anna Cossio,
  • Amelia Delzell,
  • Andrew O'Sullivan (TA)

Overview

As a WashU student living on the South 40, there is no more convenient one-stop shopping location than Paws & Go. This small grocery is a time-saver during slow hours, a money-saver in comparison to most campus dining, and carries countless options for those with dietary restrictions. Unfortunately, a frequent problem for many shoppers is the inconsistency of Paws & Go's inventory.

Many students desire a speedy shopping experience, hope to save meal points by purchasing ingredients to cook their own food, or depend on gluten-free and Kosher products on a daily basis. However, on account of Paws & Go routinely running out of even their most popular products for days or even weeks at a time, the needs of WashU students are not able to be satisfied.

We aim to eliminate these inefficient practices with our project by creating an iPhone app that allows the user to edit both a personal and public shopping list.

Personal: Each individual user has the option to utilize a barcode scanner that will scan a product and add it to their grocery list. They can add and delete items to their list, as well as save a particular product to a “Favorites” list so that it is easily accessible during their next shopping trip. One of the app’s functions will display all of the barcodes that were scanned during a particular trip, which can then be scanned quickly and efficiently at the check-out. The user will also have access to an estimated total price for their basket.

Public: As the user scans their item to their shopping list, it will be added to a full catalog of products that have been scanned on that particular day. Therefore, other customers can check the list to determine if the product they desire to purchase is available.

Objectives

  1. Manually create a database of UPC numbers for Paws & Go Market
  2. Create an intuitive mobile application in iOS using Xcode that allows a user to scan items as they pick them up at Paws & Go and generates a single-view page of barcodes for the items the user will purchase
  3. Program a barcode scanner that can identify a grocery item based off of the UPC number, and add it to the list
  4. In addition to the app's scanning capabilities, create a program that allows the user to manually input their grocery item. It will do this by identifying key words or the first few letters of items typed
  5. Apply an algorithm that adds the individual costs of each item on the user's list and displays the list's total cost when prompted
  6. Produce a list of grab-and-go items that have been purchased that day, based on purchased items that users scan into the app
  7. Demo our project by scanning a random order of supplied items into the app so that it can add the items and their barcodes to the checkout list, provide a total cost of the user's list, and update the available grab-and-go items bought that day
  8. Create a user interface for the app that displays the grocery list itemized by barcode and has an "add" menu that allows the user to add an item by navigating to a screen displaying a search bar for manual keyword search or to a camera which will scan barcodes
  9. The app will also have a "today's grab-and-go items" screen that will display those items

Challenges

  1. Learn how to create a mobile app for an iPhone
  2. Learn how to code in Swift using the Xcode app developer
  3. Learn how to code a barcode scanner into the mobile iOS app in Swift
  4. Learn how to generate a barcode from a string in Swift
  5. Find data for and create a database that efficiently stores product locations and UPC's
  6. Learn how to set up a secure, public IP address so that users can update the list of items available
  7. Learn how to navigate and use Amazon RDS for storing database of product data
  8. Create a self-explanatory and easy-to-use application interface
  9. Create a program that recognizes keywords so that it is not necessary for the user to input the exact product

Gantt Chart

GroceryGuruGanttChart.jpg

Budget

  1. Device with iOS (previously owned) - $0.00
  2. Xcode 8.2.1 - $0.00 https://itunes.apple.com/us/app/xcode/id497799835?ls=1&mt=12
  3. Paws & Go Gluten Free Peanut Butter & Jelly - $3.25
  4. Paws & Go Hummus & Pretzels - $2.60
  5. Paws & Go House-made Potato Chips - $2.25
  6. Prairie Farms 2% Reduced Fat Milk - $1.89
  7. Lays Oven Baked Barbecue Chips - $4.29
  8. Amazon RDS through Amazon Free Tier - $0.00 https://aws.amazon.com/free/
  9. Bluehost Web Hosting $2.98 for 1 month
  10. Apple Developer Program- One Year Membership - $99 https://developer.apple.com/support/purchase-activation/

Total Budget: $116.26

Draft of App Layout

GG1.jpg.png Gg2.pdf.png Gg3.pdf.png Gg4.pdf.png Gg5.pdf.png

Design and Solutions

Design Components

The app was designed to crowdsource data from customers at Paws N Go so that they can:

  1. List items and their barcodes for the total cost of shopping
  2. Scan barcodes to add to cart and update the stock
  3. View and be alerted by the amount of items left in stock at Paws N Go
  4. Manually search for items in Paws N Go

User Interface

  • The UI for Grocery Guru was created in Xcode, Apple's Developer program, in the Swift language
  • Multiple View Controllers were created, which houses the code for each new page of the app
  • Xcode has a built in Utilities tool to provide easy implementation of a user-friendly interface
    • This includes buttons for the camera (scanning), tapping an item, adjusting the slider, text fields for inputting the names of items
  • A foundation was used for the barcode scanner and then was implemented into our code
  • JSON was used to access the php files in order to store the information from the database

Server and Database

  • Used Bluehost to set up a web domain (thepawsngo.com), SQL database, and database user
  • Within Bluehost, used phpMyAdmin to create a table with columns "UPC", "Name", "Price", and "Stock" and inserted rows of data for all of the items in Paws N Go
  • Created php files on the Bluehost file manager to run SQL queries:
    • service.php: establishes a connection with the SQL database and used the SELECT query to get the rows from the database and display as an array on the webpage, thepawsngo.com/service.php. This allowed us to access the database in Xcode.
    • combine.php: establishes a connection with the database and uses the UPDATE query for customers to have the ability to update the amount of items left in stock. This occurs by sending a POST request to the database.
    • We tested the functionality of the php files using the Chrome applet, Postman, before implementing them into the code for the app

Final App Layout

HowTos

How To Create a Database

How To Install a Barcode API

Results

Source Code

https://github.com/adelzell/GroceryGuru