Team Members: Chen Hui, Jason Sathya Citro, Lim Jun Kuang Lionel, Lin Yuting
A Food Delivery Service App for Customers, Delivery Riders, Restaurant Staff and FDS Manager.
Home page
Entity Relationship Diagram
View our full project report for more detailed information
The database has been loaded with randomised and correct data exceeding 120,000 orders.
- ReactJS
- Axios
- Flask
- psycopg2
- PostgreSQL
Requirements: Have PostgreSQL installed
- Clone the repo.
git clone https://github.com/jascxx/Food-Delivery-Service-App.git
- Change directory to frontend. Install NPM Packages.
cd frontend
npm install
- Start the React Web App. This starts the web client on localhost:3000.
npm start
- Change directory to webservice and install flask and psycopg2 packages.
cd ../webservice
pip3 install flask
pip3 install psycopg2==2.7.6
- Run webserver.
python3 app.py
- Change directory to csvGenerator and generate csv data.
cd csvGenerator
python3 init_customers_users.py
python3 generate_orders.py
-
Allow some time to load the data. (No longer than 30 seconds)
-
Change directory to backend. Run psql on localhost on port 5432.
-
You need to supply your own username and password for psql.
cd ../../backend
psql -h localhost -p 5432 --u [username]
[input password]
- Create database and connect to database.
CREATE DATABASE fds;
\c fds
- Initialise data. (Make sure you are at backend directory)
\i init.sql
-
Allow some time to load the data. (No longer than 30 seconds)
-
FDS should now be operating. If the database is initialized correctly, you should be able to login with existing accounts or create a new account. Existing accounts all have username as their password. You may try logging in using the sample accounts listed below which have data pre-loaded.
Sample Customer UserID: Emma
Sample Customer password: Emma
- If you tried to register on localhost:3000 but failed, go to webservice/db.py and manually type in your psql username and password there, as shown in the picture below.
cd webservice/db.py