From 7f6c19c16e8628ef9c1cf33d51c61963eac5a437 Mon Sep 17 00:00:00 2001 From: Katherine Date: Thu, 26 Sep 2024 17:19:16 +0800 Subject: [PATCH] fix: missing afterSuccess configuration for the submit action (#5329) --- .../actions/save-record/customizeSaveRecordActionSettings.tsx | 4 ---- .../src/modules/actions/submit/createSubmitActionSettings.tsx | 4 ---- .../src/modules/actions/submit/updateSubmitActionSettings.tsx | 4 ---- .../src/client/BulkUpdateAction.Settings.tsx | 4 ---- .../settings/customizeSubmitToWorkflowActionSettings.tsx | 4 ---- 5 files changed, 20 deletions(-) diff --git a/packages/core/client/src/modules/actions/save-record/customizeSaveRecordActionSettings.tsx b/packages/core/client/src/modules/actions/save-record/customizeSaveRecordActionSettings.tsx index 87eaf97dc..165900122 100644 --- a/packages/core/client/src/modules/actions/save-record/customizeSaveRecordActionSettings.tsx +++ b/packages/core/client/src/modules/actions/save-record/customizeSaveRecordActionSettings.tsx @@ -52,10 +52,6 @@ export const customizeSaveRecordActionSettings = new SchemaSettings({ { name: 'afterSuccessfulSubmission', Component: AfterSuccess, - useVisible() { - const fieldSchema = useFieldSchema(); - return isValid(fieldSchema?.['x-action-settings']?.onSuccess); - }, }, { name: 'bindWorkflow', diff --git a/packages/core/client/src/modules/actions/submit/createSubmitActionSettings.tsx b/packages/core/client/src/modules/actions/submit/createSubmitActionSettings.tsx index a6fe8cae2..42fe8cb78 100644 --- a/packages/core/client/src/modules/actions/submit/createSubmitActionSettings.tsx +++ b/packages/core/client/src/modules/actions/submit/createSubmitActionSettings.tsx @@ -181,10 +181,6 @@ export const createSubmitActionSettings = new SchemaSettings({ { name: 'afterSuccessfulSubmission', Component: AfterSuccess, - useVisible() { - const fieldSchema = useFieldSchema(); - return isValid(fieldSchema?.['x-action-settings']?.onSuccess); - }, }, { name: 'refreshDataBlockRequest', diff --git a/packages/core/client/src/modules/actions/submit/updateSubmitActionSettings.tsx b/packages/core/client/src/modules/actions/submit/updateSubmitActionSettings.tsx index a22fbaf4d..1ec881644 100644 --- a/packages/core/client/src/modules/actions/submit/updateSubmitActionSettings.tsx +++ b/packages/core/client/src/modules/actions/submit/updateSubmitActionSettings.tsx @@ -71,10 +71,6 @@ export const updateSubmitActionSettings = new SchemaSettings({ { name: 'afterSuccessfulSubmission', Component: AfterSuccess, - useVisible() { - const fieldSchema = useFieldSchema(); - return isValid(fieldSchema?.['x-action-settings']?.onSuccess); - }, }, { name: 'refreshDataBlockRequest', diff --git a/packages/plugins/@nocobase/plugin-action-bulk-update/src/client/BulkUpdateAction.Settings.tsx b/packages/plugins/@nocobase/plugin-action-bulk-update/src/client/BulkUpdateAction.Settings.tsx index 6521d54bf..f5016985f 100644 --- a/packages/plugins/@nocobase/plugin-action-bulk-update/src/client/BulkUpdateAction.Settings.tsx +++ b/packages/plugins/@nocobase/plugin-action-bulk-update/src/client/BulkUpdateAction.Settings.tsx @@ -144,10 +144,6 @@ const schemaSettingsItems: SchemaSettingsItemType[] = [ { name: 'afterSuccess', Component: AfterSuccess, - useVisible() { - const fieldSchema = useFieldSchema(); - return isValid(fieldSchema?.['x-action-settings']?.onSuccess); - }, }, { name: 'refreshDataBlockRequest', diff --git a/packages/plugins/@nocobase/plugin-workflow/src/client/settings/customizeSubmitToWorkflowActionSettings.tsx b/packages/plugins/@nocobase/plugin-workflow/src/client/settings/customizeSubmitToWorkflowActionSettings.tsx index af1439d65..4729e2bde 100644 --- a/packages/plugins/@nocobase/plugin-workflow/src/client/settings/customizeSubmitToWorkflowActionSettings.tsx +++ b/packages/plugins/@nocobase/plugin-workflow/src/client/settings/customizeSubmitToWorkflowActionSettings.tsx @@ -47,10 +47,6 @@ export const customizeSubmitToWorkflowActionSettings = new SchemaSettings({ { name: 'afterSuccessfulSubmission', Component: AfterSuccess, - useVisible() { - const fieldSchema = useFieldSchema(); - return isValid(fieldSchema?.['x-action-settings']?.onSuccess); - }, }, { name: 'bindWorkflow',