Allow supervisors/ admin to update court report due date#999
Merged
Conversation
**What github issue is this PR for, if any?** Resolves rubyforgood#808 **What changed, and why?** - Adds a `court_report_due_date` column to the `CasaCase` table. - Adds a `court_report_due_date` date field in the details view that admins and supervisors can edit. Volunteers will see a non-editable date. - Minor refactor of date parse method in `CasaCase` to allow court report due date validation. **How will this affect user permissions?** - Volunteer permissions: View court report due date. - Supervisor permissions: View/Edit court report due date. - Admin permissions: View/Edit court report due date. **How is this tested? (please write tests!)** - Test that the court report due date field is editable in `supervisor_edits_case_spec` and `admin_edits_case_spec`. - Test the the court report due date field is visible in `volunteer_edits_case_spec`. - Test that an invalid court report due date throws an error in `supervisor_edits_case_spec`.
Collaborator
Author
|
I largely followed the existing implementation from #807. I ran the linters on the files I changed and so a few additional changes seem to have slipped in. 😅 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What github issue is this PR for, if any?
Resolves #808
What changed, and why?
court_report_due_datecolumn to theCasaCasetable.court_report_due_datedate field in the details view thatadmins and supervisors can edit. Volunteers will see a non-editable
date.
CasaCaseto allow court reportdue date validation.
How will this affect user permissions?
How is this tested? (please write tests!)
supervisor_edits_case_specandadmin_edits_case_spec.volunteer_edits_case_spec.supervisor_edits_case_spec.Screenshots