generated from ctc-uci/npo-template-merged
-
Notifications
You must be signed in to change notification settings - Fork 0
Milestone
Description
Quote
“You know the kids gon' act a fool, when you stop the programs for after school.” - Kanye West, We Don't Care
Description
- Your task is to create backend CRUD routes that will allow us to interact with our database
- CRUD stands for Create, Read, Update, Delete. Each maps to a different function for a RESTful (invented at UCI 🐜) API in Express.js: post, get, put, delete
Instructions
- Create a Express.js file with routes for interacting with the
programtable - Create a Express.js file with routes for interacting with the
partner_organizationtable
Notes
- Use the
server/routes/sample.tsas reference for new routes
Acceptance Criteria
-
server/routes/program.jscontains CRUD routes for theprogramtable- Route for creating a program
- Route for reading all programs
- Route for reading a program
- Route for updating a program
- Route for deleting a program
-
server/routes/partnerOrganization.jscontains CRUD routes for thepartner_organizationtable- Route for creating a partner organization
- Route for reading all partner organizations
- Route for reading a partner organization
- Route for updating a partner organization
- Route for deleting a partner organization
- Add routes to
server/src/app.ts- programRouter for
/programs - parterOrganizationRouter for
/partners
- programRouter for
- Backend routes work, able to test using Postman/curl (Include pictures if possible)
- Be careful because routes will actually affect the database !!
Resources
- DB Model
- Refer to Sample API Route
Metadata
Metadata
Assignees
Labels
No labels