geido opened a new pull request #18835: URL: https://github.com/apache/superset/pull/18835
### SUMMARY This PR fixes an issue for which the Pivot Table V2 would fail when the "Sort by" control was cleared with D&D enabled. The reason for the failure was that when the "Sort by" was cleared, the `series_limit_metric` was passed as an empty array due to the default behavior of the Select control. With the changes in this PR, the `series_limit_metric` type is strictly checked and converted to `undefined` when the selection is cleared up / an empty array is passed. ### BEFORE https://user-images.githubusercontent.com/60598000/154978541-c8961854-77e4-461a-9a47-830bfd337c9a.mp4 ### AFTER https://user-images.githubusercontent.com/60598000/154979004-0e3d2438-f2fb-4cbf-9450-c40900d19432.mp4 ### TESTING INSTRUCTIONS 1. Open a Pivot Table V2 with D&D enabled 2. Add a "Sort by" option 3. Clear the "Sort by" 4. Make sure the data is loaded as expected ### ADDITIONAL INFORMATION <!--- Check any relevant boxes with "x" --> <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue --> - [ ] Has associated issue: - [x] Required feature flags: `ENABLE_EXPLORE_DRAG_AND_DROP` `ENABLE_DND_WITH_CLICK_UX` - [ ] 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]
