diff --git a/packages/plugins/workflow/src/client/ExecutionCanvas.tsx b/packages/plugins/workflow/src/client/ExecutionCanvas.tsx
index 0fb1a6c54b..1c7695cfd8 100644
--- a/packages/plugins/workflow/src/client/ExecutionCanvas.tsx
+++ b/packages/plugins/workflow/src/client/ExecutionCanvas.tsx
@@ -96,7 +96,7 @@ export function ExecutionCanvas() {
-
+
diff --git a/packages/plugins/workflow/src/client/WorkflowCanvas.tsx b/packages/plugins/workflow/src/client/WorkflowCanvas.tsx
index f3990d5723..5ca2c9c6ab 100644
--- a/packages/plugins/workflow/src/client/WorkflowCanvas.tsx
+++ b/packages/plugins/workflow/src/client/WorkflowCanvas.tsx
@@ -144,7 +144,7 @@ export function WorkflowCanvas() {
-
+
diff --git a/packages/plugins/workflow/src/client/triggers/index.tsx b/packages/plugins/workflow/src/client/triggers/index.tsx
index 28985c4e99..b8b3f15725 100644
--- a/packages/plugins/workflow/src/client/triggers/index.tsx
+++ b/packages/plugins/workflow/src/client/triggers/index.tsx
@@ -6,7 +6,7 @@ import React from "react";
import { useTranslation } from "react-i18next";
import { InfoOutlined } from '@ant-design/icons';
-import { SchemaComponent, useActionContext, useAPIClient, useCompile, useResourceActionContext } from '@nocobase/client';
+import { SchemaComponent, useActionContext, useAPIClient, useCompile, useRequest, useResourceActionContext } from '@nocobase/client';
import { nodeCardClass, nodeHeaderClass, nodeMetaClass, nodeTitleClass } from "../style";
import { useFlowContext } from "../FlowContext";
@@ -128,9 +128,10 @@ function TriggerExecution() {
);
}
-export const TriggerConfig = ({ workflow }) => {
+export const TriggerConfig = () => {
const { t } = useTranslation();
const compile = useCompile();
+ const { workflow } = useFlowContext();
if (!workflow || !workflow.type) {
return null;
}
@@ -161,7 +162,11 @@ export const TriggerConfig = ({ workflow }) => {
'x-component': 'Action.Drawer',
'x-decorator': 'Form',
'x-decorator-props': {
- initialValue: { config }
+ useValues(options) {
+ return useRequest(() => Promise.resolve({
+ data: { config },
+ }), options);
+ },
},
properties: {
config: {