Skip to content
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

Fix for onEmptyFilter getting stuck on internal datasource filters. #13529

Merged

Conversation

deanhannigan
Copy link
Contributor

Description

The onEmptyFilter filter gets stuck in the filter list when all filter fields are removed. If you had previously set this filter to none it will cause the filter to always return zero rows. The only way to get around it is to refresh or add in fields to make the onEmptyFilter UI visible again.

Addresses

Clears the onEmptyFilter when all field filters have been removed. This ensures that all rows continue to be returned when no fields are specified.

Steps

  1. Pick an internal datasource in the Data section and open the filter menu
  2. Add a field to the search and the change the When filter empty to Return no rows
  3. Remove the field entry and save the filter.
  4. Despite all field filters being removed and the When filter empty option being hidden, the onEmptyFilter is still present in the filter UX and will cause no rows to appear.

The same behaviour can be seen when filtering datasources on components in the builder.

Screenshots

Screenshot 2024-04-19 at 12 59 41

Launchcontrol

Minor fix to ensure onEmptyFilter is cleared from datasource filters when no fields are specified.

@aptkingston aptkingston merged commit bff6340 into master Apr 22, 2024
10 checks passed
@aptkingston aptkingston deleted the fix/clear-empty-filter-when-all-fields-are-removed branch April 22, 2024 09:21
@github-actions github-actions bot locked and limited conversation to collaborators Apr 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants