In this PR, I created all CRUD operations for the backend of Courses.
[x] Create personal dokku dev
[x] Create database table for Courses (initial DB table for courses has been created. Database files for happycows, including migration file, entity, and repository file have been been added)
[x] Create CoursesController.java, add Get and POST
[x] Add GET endpoint for single record in Courses table
[x] Add PUT endpoint for single record in Courses table
[x] Add DELETE endpoint for specific record in Courses table
Screenshots (Optional)
Database table on Dokku:
CRUD Endpoints on Swagger:
PUT Endpoint:
POST Endpoint:
GET SINGLE Endpoint:
GET ALL Endpoint:
DELETE Endpoint:
Pit Test Coverage:
Jacoco tests:
Feedback Request (Optional)
Please give suggestions on the following:
I have defined 3 variables for the Courses.entity file: id, name, and term. I removed GitHub id, start and endtime, and school. Because the application was geared towards UCSB CHEM students, so there was no need for GitHub id or school variable. Additionally, the commons had a variable for start and endtime, so there was no need to create those again.
Overview
In this PR, I created all CRUD operations for the backend of Courses.
[x] Create personal dokku dev
[x] Create database table for Courses (initial DB table for courses has been created. Database files for happycows, including migration file, entity, and repository file have been been added)
[x] Create CoursesController.java, add Get and POST
[x] Add GET endpoint for single record in Courses table
[x] Add PUT endpoint for single record in Courses table
[x] Add DELETE endpoint for specific record in Courses table
Screenshots (Optional)
Database table on Dokku:
CRUD Endpoints on Swagger:
PUT Endpoint:
POST Endpoint:
GET SINGLE Endpoint:
GET ALL Endpoint:
DELETE Endpoint:
Pit Test Coverage:
Jacoco tests:
Feedback Request (Optional)
Please give suggestions on the following:
Validation (Optional)
Tests
mvn test
) passmvn test jacoco:report
) 100%mvn test pitest:mutationCoverage
) 100%npm test
) passnpm run coverage
) 100%npx stryker run
) 100%npx eslint --fix src
)Linked Issues
Closes #25