Add float_greater_than operator

Summary: Doc: https://docs.google.com/document/d/1miofxds9DJgWScj0zFyBbdpRH5Rj0T9FqiCapof5-vU/edit#heading=h.pg8svtdjlx7

Reviewed By: antonk52

Differential Revision: D49230130

fbshipit-source-id: 31755bc19d4bb7a397c361f5d0e236e08c945cd1
This commit is contained in:
Andrey Goncharov
2023-09-14 04:48:12 -07:00
committed by Facebook GitHub Bot
parent 092e9e7a72
commit 467a4591b0

View File

@@ -66,6 +66,11 @@ export const dataTablePowerSearchOperators = {
key: 'int_less_or_equal',
valueType: 'INTEGER',
}),
float_greater_than: () => ({
label: '>',
key: 'float_greater_than',
valueType: 'FLOAT',
}),
} satisfies {
[key: string]: (...args: any[]) => OperatorConfig;
};
@@ -108,4 +113,6 @@ export const dataTablePowerSearchOperatorProcessorConfig = {
value < searchValue,
int_less_or_equal: (_operator, searchValue: number, value: number) =>
value <= searchValue,
float_greater_than: (_operator, searchValue: number, value: number) =>
value > searchValue,
} satisfies PowerSearchOperatorProcessorConfig;