Add is_nullish operator
Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7 Reviewed By: antonk52 Differential Revision: D49230135 fbshipit-source-id: 1f7d88512eb3ed592eb406f0950ffa0c6985772c
This commit is contained in:
committed by
Facebook GitHub Bot
parent
75884674e0
commit
3a4dada2fc
@@ -111,6 +111,11 @@ export const dataTablePowerSearchOperators = {
|
||||
valueType: 'ENUM_SET',
|
||||
enumLabels,
|
||||
}),
|
||||
is_nullish: () => ({
|
||||
label: 'is nullish',
|
||||
key: 'is_nullish',
|
||||
valueType: 'NO_VALUE',
|
||||
}),
|
||||
} satisfies {
|
||||
[key: string]: (...args: any[]) => OperatorConfig;
|
||||
};
|
||||
@@ -169,4 +174,5 @@ export const dataTablePowerSearchOperatorProcessorConfig = {
|
||||
searchValue.some((item) => value === item),
|
||||
enum_set_is_none_of: (_operator, searchValue: string[], value: string) =>
|
||||
!searchValue.some((item) => value === item),
|
||||
is_nullish: (_operator, _searchValue, value) => value == null,
|
||||
} satisfies PowerSearchOperatorProcessorConfig;
|
||||
|
||||
Reference in New Issue
Block a user