An E-Commerce Backend that demonstrates Object-Relational Mapping
This is a Node.js application that will take in input regarding a manager and the engineers and interns on their team. Using this information, it will generate an HTML web page. The application uses JavaScript and Node.js. The HTML webpage uses Bootstrap, FontAwesome, and an application-specific CSS file.
- Clone the project from the main branch of the repository to the local filesystem
- make sure that node.js and npm are installed
- run the command "npm install" to install the dependencies from the package.json file
- create an .env file with your MySQL username and password, and the database set to "ecommerce_db"
- run "cd db" in order to enter the db folder
- open a MySQL shell, and use the command "source schema.sql" in order to load the schema folder
- exit out of the MySQL shell, and navigate back to the main folder
- run the command "npm run seed" in order to seed the database
- in the main folder, run the command "npm start"
- using Insomnia or another API client, go to localhost:3001/api/
- Product routes are localhost:3001/api/products/
- Category routes are localhost:3001/api/categories/
- Tag routes are localhost:3001/api/tags/
- GET requests are at / and can have an id parameter passed
- POST for products should be formatted as: { product_name: "Basketball", price: 200.00, stock: 3, tagIds: [1, 2, 3, 4] }
- POST requests for categories should be formatted as: { "category_name": "Underwear" }
- POST requests for tags should be formatted as: { "tag_name": "cyan", "prodIds": [1, 2, 3, 4] }
- PUT requests for products should be formatted as: { "product_name": "Basketball", "price": 250.00, "stock": 2, "tagIds": [3, 4] }
- PUT requests for categories should be formatted as: { "category_name": "Undergarments" }
- PUT requests for tags should be formatted as: { "tag_name": "fuschia" }
https://drive.google.com/file/d/1Qxct1RAqi-oiIoCqu3e5YKg96VuCM8Z5/view
- Clone the Main branch of the repository from GitHub
- Create a Branch and name it using the format: "feature_contributor"
- Create a pull request
- Send an email to the address listed in the Questions section, containing a summary of the contribution
MIT https://opensource.org/licenses/MIT A short and simple permissive license with conditions only requiring preservation of copyright and license notices. Licensed works, modifications, and larger works may be distributed under different terms and without source code.
GitHub name: KatsuMatsushita
To contact me, drop an email to: katsu.matsushita@gmail.com