Fix initial code step functionInput (#18002)
At code step creation ## before <img width="623" height="816" alt="image" src="https://github.com/user-attachments/assets/0aed5ed8-8d56-4988-9d31-fe80942191bb" /> ## after <img width="627" height="528" alt="image" src="https://github.com/user-attachments/assets/9e2a5cb9-7480-4734-8e41-25b45edcec07" />
This commit is contained in:
+4
-2
@@ -1,5 +1,7 @@
|
||||
import { type ObjectRecordGroupByDateGranularity } from 'twenty-shared/types';
|
||||
import { type FirstDayOfTheWeek } from 'twenty-shared/utils';
|
||||
import {
|
||||
type FirstDayOfTheWeek,
|
||||
type ObjectRecordGroupByDateGranularity,
|
||||
} from 'twenty-shared/types';
|
||||
|
||||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
|
||||
|
||||
+4
-2
@@ -1,5 +1,7 @@
|
||||
import { type ObjectRecordGroupByDateGranularity } from 'twenty-shared/types';
|
||||
import { type FirstDayOfTheWeek } from 'twenty-shared/utils';
|
||||
import {
|
||||
type ObjectRecordGroupByDateGranularity,
|
||||
type FirstDayOfTheWeek,
|
||||
} from 'twenty-shared/types';
|
||||
|
||||
export type DateFieldGroupByDefinition = {
|
||||
granularity: ObjectRecordGroupByDateGranularity;
|
||||
|
||||
+1
-1
@@ -3,8 +3,8 @@ import {
|
||||
type ObjectRecordGroupByDateGranularity,
|
||||
type ObjectRecordOrderByForCompositeField,
|
||||
type ObjectRecordOrderByForScalarField,
|
||||
type FirstDayOfTheWeek,
|
||||
} from 'twenty-shared/types';
|
||||
import { type FirstDayOfTheWeek } from 'twenty-shared/utils';
|
||||
|
||||
export type ObjectRecordFilter = Partial<{
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
|
||||
+5
-2
@@ -1,5 +1,8 @@
|
||||
import { type ObjectRecordGroupByDateGranularity } from 'twenty-shared/types';
|
||||
import { type FirstDayOfTheWeek, isDefined } from 'twenty-shared/utils';
|
||||
import {
|
||||
type ObjectRecordGroupByDateGranularity,
|
||||
type FirstDayOfTheWeek,
|
||||
} from 'twenty-shared/types';
|
||||
import { isDefined } from 'twenty-shared/utils';
|
||||
|
||||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
import { type GroupByRawResult } from 'src/modules/dashboard/chart-data/types/group-by-raw-result.type';
|
||||
|
||||
+5
-2
@@ -1,5 +1,8 @@
|
||||
import { type ObjectRecordGroupByDateGranularity } from 'twenty-shared/types';
|
||||
import { type FirstDayOfTheWeek, isDefined } from 'twenty-shared/utils';
|
||||
import {
|
||||
type ObjectRecordGroupByDateGranularity,
|
||||
type FirstDayOfTheWeek,
|
||||
} from 'twenty-shared/types';
|
||||
import { isDefined } from 'twenty-shared/utils';
|
||||
|
||||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
import { type GroupByRawResult } from 'src/modules/dashboard/chart-data/types/group-by-raw-result.type';
|
||||
|
||||
+6
-1
@@ -9,6 +9,7 @@ import {
|
||||
import { isDefined, isValidUuid } from 'twenty-shared/utils';
|
||||
import {
|
||||
IF_ELSE_BRANCH_POSITION_OFFSETS,
|
||||
getFunctionInputFromInputSchema,
|
||||
type StepIfElseBranch,
|
||||
} from 'twenty-shared/workflow';
|
||||
import { Repository } from 'typeorm';
|
||||
@@ -181,7 +182,11 @@ export class WorkflowVersionStepOperationsWorkspaceService {
|
||||
},
|
||||
input: {
|
||||
logicFunctionId: newLogicFunction.id,
|
||||
logicFunctionInput: newLogicFunction.toolInputSchema ?? {},
|
||||
logicFunctionInput: isDefined(newLogicFunction.toolInputSchema)
|
||||
? (getFunctionInputFromInputSchema([
|
||||
newLogicFunction.toolInputSchema,
|
||||
])[0] ?? {})
|
||||
: {},
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user