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(ui): filter out fields with disableListFilter in whereBuilder prior to adding conditions #10112

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

akhrarovsaid
Copy link
Contributor

@akhrarovsaid akhrarovsaid commented Dec 20, 2024

What?

This PR fixes an issue with the WhereBuilder where if the first field in a collection had disableListFilter enabled, the select in that fields Condition would be rendered disabled, making it impossible to query docs in list view.

Why?

To allow users to query their documents while still being able to set disableListFilter on fields regardless of where they are in the collection hierarchy.

How?

By filtering out unfilterable fields earlier in WhereBuilder and Condition components.

Fixes #10110

Before:
Dashboard-wherebuilder-before--Payload.webm

After:
Dashboard-wherebuilder-after--Payload.webm

Copy link
Contributor

@DanRibbens DanRibbens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, looks good!

@DanRibbens DanRibbens enabled auto-merge (squash) December 21, 2024 11:54
@DanRibbens DanRibbens self-assigned this Dec 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

All filters are disabled if the first field in the select has disableListFilter=true
2 participants