the web server should be working!!!
External API is provided by https://rapidapi.com/, due to this, the API will collect money if user exceed 100 request/day.
The external API service, shown on homepage(index.html) ran with script (./script/rec_api.js) will be turned off to avoid losing money.
If the work check required this API to be turned on, please see (./script/rec_api.js), a short instruction will be inside to show you how to activate the API.
All testcase should be in (./routes/crud.js), the testcase is commented, please try it out as instructed in the CRUD file.
there are two type of GET: Get all, and Get by primary key (movie ID or Email)
This is a web writing project for Year 2 Term 2 Web programming. Written by:
- Ariya P.
- Phichayut N.
- Kulawut M.
- Perakorn N.
git remote add origin https://github.com/Silberweich/Y2T2_WebProg.git
git clone https://github.com/Silberweich/Y2T2_WebProg.git
!!!IMPORTANT!!!
git branch -M react
git push -u origin react
git pull origin react
https://fonts.google.com/specimen/Quicksand
- TEAM: Navigation Diagram
- ENG: Homepage / Index.html
- VIEW: About us page / about.html
- PETE: Admin + Login
- CHAN: Search + Result
- Authentication Service
- CRUD(Search, Insert, Update, Delete) + Test cases
- Authentication Service Interaction
- Search Service Interaction
- Public web service interaction (External API)
- Home
- Login + API
- Admin Movie
- Display movies
- Search (No criteria + 3 criteria)
- Create
- Update
- Delete
- Dynamic page for each movie
- Admin User
- Display users
- Search (No criteria + 3 criteria)
- Create
- Update
- Delete
- Dynamic page for each user
- Report
1. React Router Dom v6 (npm install react-router-dom@6)
2. React Styled-Component (npm install --save styled-components)
3. Axios (npm install axios)
"body-parser": "^1.19.2",
"cookie-parser": "^1.4.6",
"cors": "^2.8.5",
"dotenv": "^16.0.0",
"express": "^4.17.3",
"jsonwebtoken": "^8.5.1",
"mysql2": "^2.3.3",
"node-fetch": "^3.2.3",
"nodemon": "^2.0.15"
Go to .env file and replace the http://localhost:4203 with another domain
index.js
added '/searchMoviesReact' route (the same as'/searchMovies'
), but only data is returnedcrud.js
- Added GET methods:
'/userSearchEmail', '/userSearchFname', '/userSearchLname'
for criteria search - Change
req.body.data[0].${varName}
toreq.body.data.${varName}
in PUT and DELETE methods, so that they can be use with the React APP easily
- Added GET methods: