feat: Add new 'is empty' and 'is not empty' operators to Filter (#8445)

Co-authored-by: Michael Kret <michael.k@radency.com>
This commit is contained in:
Elias Meire
2024-01-26 11:17:41 +01:00
committed by GitHub
parent a517c8251b
commit c21c4b9178
3 changed files with 48 additions and 0 deletions

View File

@@ -179,6 +179,10 @@ export function executeFilterCondition(
const right = (rightValue ?? '') as string;
switch (condition.operator.operation) {
case 'empty':
return left.length === 0;
case 'notEmpty':
return left.length !== 0;
case 'equals':
return left === right;
case 'notEquals':