ObservabilityTeam opened a new pull request, #34137:
URL: https://github.com/apache/superset/pull/34137

   * adds a fix for correctly selecting first value of a dependent filter
   * adds a fix for automatically selecting the correct dependent filter value 
on changing parent filter value
   * adds dependent filters fix support for time range filter
   
   ### SUMMARY
   <!--- Describe the change below, including rationale and design decisions -->
   These fixes address issues with dependent filters using the "Select first 
filter value by default" option:
   
   - FilterValue.tsx: Prevents child filters from requesting data before their 
parent values are set. The request is now delayed until all parent filter data 
is available, ensuring correct first value selection.
   
   - SelectFilterPlugin: Ensures the first value is correctly updated when 
parent filter values change. A post-check hook verifies external data changes 
and selects the appropriate default.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   <!--- Skip this if not applicable -->
   
![Dependent-filters-before](https://github.com/user-attachments/assets/683fb096-5eba-4759-931e-33971f971b5c)
   
![Dependent-filters-after](https://github.com/user-attachments/assets/6f6facf8-2698-4ad3-b519-9e6e2016e2b8)
   
   ### TESTING INSTRUCTIONS
   <!--- Required! What steps can be taken to manually verify the changes? -->
   
   1. Create a dashboard with two filters and some charts these filters are 
applied to.
   2. Make both filters required and "Select first filter value as default".
   3. Make one of the filters dependent (child) on the other.
   4. Make sure the first value of the dependent filter is not available with 
the first value of the other filter.
   5. Load dashboard in UI.
   6. First value of the dependent (child) filter is NOT chosen based on it's 
parent filter(s)
   7. If you change the value of the parent filter(s), the first value of the 
child does not change which should not be the case because it should reflect 
changes based on it's parent(s) value. 
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [x] Has associated issue: Fixes 
#[22979](https://github.com/apache/superset/issues/22979)
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in 
[SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to