Manager's want to be able to resolve a log, so the caregivers, instructors, or recipients who created it know the issue has been seen and addressed.
Resolving a Log introduces 3 new attributes on the Log model ->
resolved: boolean (required) - if a log has been resolved or not
resolution: String (optional) - a short comment that explains how or why the log was resolved
resolver: User reference (optional) - the user (Manager or Admin) that resolved the log
Add these attributes to the server/db/models/Log.js model.
Refactor the PATCH /api/logs/:id endpoint to enable log resolutions.
Ensure only users with role: "Manager" can resolve logs
Refactor the POST /api/logs/search endpoint to filter by resolved status.
Refactor the seeder script if needed.
Description
Manager's want to be able to resolve a log, so the caregivers, instructors, or recipients who created it know the issue has been seen and addressed.
Resolving a Log introduces 3 new attributes on the Log model ->
resolved: boolean (required)
- if a log has been resolved or notresolution: String (optional)
- a short comment that explains how or why the log was resolvedresolver: User reference (optional)
- the user (Manager or Admin) that resolved the logAdd these attributes to the
server/db/models/Log.js
model.Refactor the
PATCH /api/logs/:id
endpoint to enable log resolutions.role: "Manager"
can resolve logs Refactor thePOST /api/logs/search
endpoint to filter byresolved
status. Refactor the seeder script if needed.Acceptance Criteria
Other Notes