From 98544a24797346b76639dcc047e183d7ad0dd194 Mon Sep 17 00:00:00 2001 From: Marie <51697796+ijreilly@users.noreply.github.com> Date: Thu, 2 Oct 2025 15:16:42 +0200 Subject: [PATCH] [Fix] Handle deprecated viewFilterOperand - follow-up (#14841) --- .../src/types/ViewFilterOperandDeprecated.ts | 4 ++-- ...t-view-filter-operand-to-core-operand.util.ts | 16 ---------------- 2 files changed, 2 insertions(+), 18 deletions(-) diff --git a/packages/twenty-shared/src/types/ViewFilterOperandDeprecated.ts b/packages/twenty-shared/src/types/ViewFilterOperandDeprecated.ts index 04c38a1c21..a758530931 100644 --- a/packages/twenty-shared/src/types/ViewFilterOperandDeprecated.ts +++ b/packages/twenty-shared/src/types/ViewFilterOperandDeprecated.ts @@ -2,8 +2,8 @@ export enum ViewFilterOperandDeprecated { Is = 'is', IsNotNull = 'isNotNull', IsNot = 'isNot', - LessThanOrEqual = 'lessThanOrEqual', - GreaterThanOrEqual = 'greaterThanOrEqual', + LessThanOrEqual = 'lessThan', + GreaterThanOrEqual = 'greaterThan', IsBefore = 'isBefore', IsAfter = 'isAfter', Contains = 'contains', diff --git a/packages/twenty-shared/src/utils/filter/utils/convert-view-filter-operand-to-core-operand.util.ts b/packages/twenty-shared/src/utils/filter/utils/convert-view-filter-operand-to-core-operand.util.ts index 51755bb46d..9b8746a408 100644 --- a/packages/twenty-shared/src/utils/filter/utils/convert-view-filter-operand-to-core-operand.util.ts +++ b/packages/twenty-shared/src/utils/filter/utils/convert-view-filter-operand-to-core-operand.util.ts @@ -1,22 +1,6 @@ import { ViewFilterOperand, ViewFilterOperandDeprecated } from '@/types'; const operandMapping: Record = { - Is: ViewFilterOperand.IS, - IsNotNull: ViewFilterOperand.IS_NOT_NULL, - IsNot: ViewFilterOperand.IS_NOT, - LessThanOrEqual: ViewFilterOperand.LESS_THAN_OR_EQUAL, - GreaterThanOrEqual: ViewFilterOperand.GREATER_THAN_OR_EQUAL, - IsBefore: ViewFilterOperand.IS_BEFORE, - IsAfter: ViewFilterOperand.IS_AFTER, - Contains: ViewFilterOperand.CONTAINS, - DoesNotContain: ViewFilterOperand.DOES_NOT_CONTAIN, - IsEmpty: ViewFilterOperand.IS_EMPTY, - IsNotEmpty: ViewFilterOperand.IS_NOT_EMPTY, - IsRelative: ViewFilterOperand.IS_RELATIVE, - IsInPast: ViewFilterOperand.IS_IN_PAST, - IsInFuture: ViewFilterOperand.IS_IN_FUTURE, - IsToday: ViewFilterOperand.IS_TODAY, - VectorSearch: ViewFilterOperand.VECTOR_SEARCH, [ViewFilterOperandDeprecated.Is]: ViewFilterOperand.IS, [ViewFilterOperandDeprecated.IsNotNull]: ViewFilterOperand.IS_NOT_NULL, [ViewFilterOperandDeprecated.IsNot]: ViewFilterOperand.IS_NOT,