Skip to content

ethanchurchill/FinTeach

Repository files navigation

FinTeach

Important Links

Getting Started

Before running the application, make sure postgres and node are installed on your machine. Once postgres and node are installed, clone the repo, navigate project directory and checkout master for the latest stable version.
Postgres: https://www.postgresql.org/download/
Node: https://nodejs.org/en/download/

Backend

Ensure PostgreSQL and PGAdmin are installed using the link above Navigate to the database folder in the base directory and get the two sql files there for use below
Create a new database called finteach_db and set postgres as the user.
Open a new query and run the contents of finteach_db_1_create_schema.sql.
Open a new query and run the contents of finteach_db_2_populate_table.sql.

Frontend

Navigate to the FinTeach/FinTeach folder within the base directory. Run the following commands
npm install -g @angular/cli
npm install
npm start
Upon succesfully running each of these three commands, the frontend on its own will be up and running.
It can be viewed by opening your browser and navigating to http://localhost:4200/

Express Server

Navigate to the FinTeach/nodejs-express-sequelize-postgresql directory
Based on the instructions and your postgres configuration, update the db config file
To do this, navigate to FinTeach/nodejs-express-sequelize-postgresql/app/config and open db.config.js
Update the user, password, and db fields
These are established during first time postgres setup as well as by following the database instructions above
Once these values are updated, you can run the Express server. Run the following commands
npm install express sequelize pg pg-hstore cors --save
npm install
node server.js
Upon successfully running these commands, the express server will be up and running.
It can be viewed by opening your browser and navigating to http://localhost:8080/

Project Structure

The FinTeach/FinTeach directory contains the components for the frontend of the application. The nodejs-express-sequelize-postgresql directory contains the backend. The database folder contains the database sql scripts.