-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add update remove objectives #352
Merged
Merged
Conversation
This file contains 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
The frontend can add objects to goals. Uses react-hook-form's field array for objectives. I could not find an example where a field array was nested without the first array also being a part of the field array. Since goals are done with the multiselect I couldn't figure out a way to use a field array with goals. I had some issues getting everything to work but once I moved the objective's "edit" state outside of hook form and into the objective component as state things started to simplify a bit. Waiting for the recent form validation PR to merge before moving this forward. Still need to handle error messages and finalize validations.
Conflicts: frontend/src/components/MultiSelect.js
If a goal has zero objectives one is added. If a goal only has one objective that objective cannot be removed.
Small goals were not taking up the proper space. Now they always take 100% of the parent and the trash can icon is placed to the right
Objectives no longer uses react-hook-from field arrays. This change simplifies the code a bit. Also avoids the fight between the multiselect and field arrays.
Splitting out the goal validator makes testing the validator easier. Also makes understanding the validator easier as well.
Conflicts: frontend/yarn.lock
Goals can have 0 objectives. Cancel button added to objectvies that will: * Remove the objective if it is empty * Cancel any updates if the objective already has values
Conflicts: frontend/src/pages/ActivityReport/Pages/goalsObjectives.js
…tives Add update remove objectives
Include the context menu in the activity reports table
rahearn
approved these changes
Mar 8, 2021
AdamAdHocTeam
added a commit
that referenced
this pull request
Jul 8, 2021
* Revert "Revert "Ttahub 182/add three new topics"" * Update yaml config to push to SB.
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.
Description of change
The frontend can add objects to goals. Uses react-hook-form's field array for objectives. I could not find an example where a field array was nested without the first array also being a part of the field array. Since goals are done with the multiselect I couldn't figure out a way to use a field array with goals. I had some issues getting everything to work but once I moved the objective's "edit" state outside of hook form and into the objective component as state things started to simplify a bit.
Keeping as a draft until more pieces make it to main, mainly the context menu and validations.How to test
grantee
and the first few grantsIssue(s)
Checklist
This PR also includes a change for adding a context menu to the landing page activity reports table