CourtneyBrothers / plastictracker

0 stars 0 forks source link

Cb 1 #8

Closed CourtneyBrothers closed 6 years ago

CourtneyBrothers commented 6 years ago

Start here to initilizate the project

this interface assumes a global installation of psql if not already installed

npm install psql -g

steps : to access all required dependencies npm install

how to build database and connect to postgres

once your project is initiliazed as above

  1. Open in your terminal run psql

  2. CREATE DATABASE plastictracker create database named plastictracker

  3. \c plastictracker connect to plastictracker

in the command line you will see "You are now connected to the database"

  1. In your config.json file enter the name of the database you created in the previous step

"database": "plastictracker",

  1. To build the database from the project

run node build_db

  1. To run the app

nodemon app.js recommmended ** note npm install -g nodemon assumed but with no global install add nodemon to your dependencies npm install --save-dev nodemon

serving the app will present a login page. A dummy user is in json in order for developers to login w/o re-registering each time

after login users are presented with a view to select type and quantity of plastic saved

after submission users are presented with totals of each type of plastic saved by id