This issue should be completed after the issue with the title "Create UCSBOrganizationController..."
Overview
In this issue, we add one more method from the example Controller used as a basis for our code; namely the method with the annotation shown below:
Annotation
Purpose
@GetMapping("")
Get a single record from the table; use the value passed in as a @RequestParam to do a lookup by id. If a matching row is found, return the row as a JSON object, otherwise throw an EntityNotFoundException.
Add GET (show) endpoint for a single record in UCSBOrganization table
Also add the tests for this endpoint.
Acceptance Criteria:
[x] In UCSBOrganizationController.java there is code for an
endpoint GET /api/UCSBOrganization?id=123 endpoint
that returns the JSON of the database record with id 123 if it
exists, or a 404 and the error message id 123 not found if it
does not.
[x] The Swagger-UI endpoints for this endpoint is well documented
so that any member of the team can understand how to use it.
[x] The endpoint works as expected on localhost.
[x] The endpoint works as expected when deployed to Dokku.
[x] There is full test coverage (Jacoco) for the new code in
UCSBOrganizationController.java
[x] There is full mutation test coverage (Pitest) for new code in
UCSBOrganizationController.java
What to do next
Do a PR, following all of the usual steps (title, description, Closes #n text,
dragging issue to "In Review", requesting reviewers).
Check to see if any fellow team members PRs need to be reviewed.
Then, assign yourself the next incomplete issue for your database table (UCSBOrganization)
Follow all the usual steps (assign to self, drag to "In Progress", start new branch.)
When you are done with all issues for UCSBOrganization, please give your full attention to
helping others on your team to complete the sprint, so that the team
is ready to submit on Canvas by the deadline.
Dependencies
This issue should be completed after the issue with the title "Create
UCSBOrganizationController
..."Overview
In this issue, we add one more method from the example Controller used as a basis for our code; namely the method with the annotation shown below:
@GetMapping("")
@RequestParam
to do a lookup by id. If a matching row is found, return the row as a JSON object, otherwise throw anEntityNotFoundException
.Add
GET
(show) endpoint for a single record in UCSBOrganization tableAlso add the tests for this endpoint.
Acceptance Criteria:
UCSBOrganizationController.java
there is code for an endpointGET /api/UCSBOrganization?id=123
endpoint that returns the JSON of the database record with id 123 if it exists, or a 404 and the error messageid 123 not found
if it does not.UCSBOrganizationController.java
UCSBOrganizationController.java
What to do next
Do a PR, following all of the usual steps (title, description,
Closes #n
text, dragging issue to "In Review", requesting reviewers).Check to see if any fellow team members PRs need to be reviewed.
Then, assign yourself the next incomplete issue for your database table (
UCSBOrganization
)Follow all the usual steps (assign to self, drag to "In Progress", start new branch.)
When you are done with all issues for
UCSBOrganization
, please give your full attention to helping others on your team to complete the sprint, so that the team is ready to submit on Canvas by the deadline.