-
Notifications
You must be signed in to change notification settings - Fork 9
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
BugFix: Fix Sampling Information Cache #1495
Conversation
Openshift URLs for the PR Deployment: |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## dev #1495 +/- ##
==========================================
+ Coverage 45.92% 47.49% +1.57%
==========================================
Files 907 926 +19
Lines 23537 24018 +481
Branches 3492 3570 +78
==========================================
+ Hits 10809 11407 +598
+ Misses 12136 11991 -145
- Partials 592 620 +28 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Skimmed the code and tested the UI LGTM
Add unit tests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍🏼
|
Links to Jira Tickets
n/a
Description of Changes
Fixes the sampling information cache.
The sampling site, technique, and period columns in the observations data grid should now load records as expected, based on the correct site -> technique -> period record relationships.
Typing in the sites drop-down should filter the results as expected (fixed in previous PR).
Dev Notes
The cache works by tracking 3 objects (for site, technique, period). Where the key is the primary ID, and the value is the respective autocomplete option.
There are 2 new index objects, which tracks a key against an array of ids.
This way, the technique edit component can filter its drop-down options based on the site value provided (from the site datagrid value).
And the period edit component can filter its drop-down options based on both the site and technique values provided (based on their respective values in the datagrid state).
Testing Notes
Site column should search and filter as expected from an autocomplete field.
Technique column should show all valid techniques for the chosen site, or nothing if no site value has been selected.
If the site value changes, the technique value will be cleared.
Period column should show all valid periods for the chosen site + technique, or nothing if no site or technique values have been selected.
If the site or technique value changes, the period value will be cleared.