-
Notifications
You must be signed in to change notification settings - Fork 843
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
Support EXACT operator in filters #3920
Labels
Comments
nyurik
added a commit
to nyurik/eui
that referenced
this issue
Aug 14, 2020
nyurik
added a commit
to nyurik/eui
that referenced
this issue
Aug 14, 2020
Additionally adds a an operator example to the search bar demo, and use `OperatorType` in all other filters TS declaration. closes: elastic#3920
3 tasks
nyurik
added a commit
to nyurik/eui
that referenced
this issue
Aug 14, 2020
Additionally adds a an operator example to the search bar demo, and use `OperatorType` in all other filters TS declaration. closes: elastic#3920
chandlerprall
added a commit
that referenced
this issue
Aug 25, 2020
* Support operator in field_value_selection filters Additionally adds a an operator example to the search bar demo, and use `OperatorType` in all other filters TS declaration. closes: #3920 * update docs for field_value_selection * changelog Co-authored-by: Chandler Prall <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Query bar supports
EXACT
operator, e.g.lang=ru
andlang=(ru,fr)
, but the filter boxes only use the defaultEQ
operator - producinglang:ru
which matches bothru
andruo
.Two possible solutions:
operator ?: OperatorType
-- there could be usecases for other operators likelt
-- e.g. options list preset well known values like 25%, 50%, and selecting it producesfield<0.25
.exactMatch ?: boolean
parameter to theFieldValueSelectionFilterConfigType
, with default set tofalse
-- not as flexible approach.Note that
ast.addOrFieldValue
already supports operator as the 4th optional param, so all that's needed would be to pass it.Relevant code:
eui/src/components/search_bar/filters/field_value_selection_filter.tsx
Line 49 in fa2916e
eui/src/components/search_bar/query/ast.ts
Lines 388 to 392 in 43ccf53
P.S. for now just a community project, low priority unless needed by some Elastic project
The text was updated successfully, but these errors were encountered: