Use variables within Iterators (#14604)
Variables were not working properly. Output schema was outdated and parent steps were not calculated properly. Before https://github.com/user-attachments/assets/b070c1ff-41dd-4ea0-a590-25bb39027456 After https://github.com/user-attachments/assets/baa43e69-0e7c-4697-8812-3ce523efba13
This commit is contained in:
+3
-2
@@ -25,9 +25,10 @@ export const useAvailableVariablesInWorkflowStep = ({
|
||||
);
|
||||
const flow = useFlowOrThrow();
|
||||
const steps = flow.steps ?? [];
|
||||
const currentStep = steps.find((step) => step.id === workflowSelectedNode);
|
||||
|
||||
const previousStepIds: string[] = isDefined(workflowSelectedNode)
|
||||
? getPreviousSteps(steps, workflowSelectedNode).map((step) => step.id)
|
||||
const previousStepIds: string[] = isDefined(currentStep)
|
||||
? getPreviousSteps({ steps, currentStep }).map((step) => step.id)
|
||||
: [];
|
||||
|
||||
const availableStepsOutputSchema: StepOutputSchemaV2[] = useRecoilValue(
|
||||
|
||||
Reference in New Issue
Block a user