From c603108542d62d46bd2276b7caeecd79f0bf1f4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E5=B0=8F=E6=96=90?= Date: Thu, 25 May 2023 10:33:59 +0800 Subject: [PATCH] fix: disable popup button in add-modal (#1808) * fix: disable popup button in add-modal * fix: disable popup button in form block --- .../buttons/FormActionInitializers.tsx | 202 +++++++++--------- 1 file changed, 102 insertions(+), 100 deletions(-) diff --git a/packages/core/client/src/schema-initializer/buttons/FormActionInitializers.tsx b/packages/core/client/src/schema-initializer/buttons/FormActionInitializers.tsx index 0cc57a44f..660445447 100644 --- a/packages/core/client/src/schema-initializer/buttons/FormActionInitializers.tsx +++ b/packages/core/client/src/schema-initializer/buttons/FormActionInitializers.tsx @@ -24,56 +24,57 @@ export const FormActionInitializers = { type: 'subMenu', title: '{{t("Customize")}}', children: [ - { - type: 'item', - title: '{{t("Popup")}}', - component: 'CustomizeActionInitializer', - schema: { - type: 'void', - title: '{{ t("Popup") }}', - 'x-action': 'customize:popup', - 'x-designer': 'Action.Designer', - 'x-component': 'Action', - 'x-component-props': { - openMode: 'drawer', - }, - properties: { - drawer: { - type: 'void', - title: '{{ t("Popup") }}', - 'x-component': 'Action.Container', - 'x-component-props': { - className: 'nb-action-popup', - }, - properties: { - tabs: { - type: 'void', - 'x-component': 'Tabs', - 'x-component-props': {}, - 'x-initializer': 'TabPaneInitializers', - properties: { - tab1: { - type: 'void', - title: '{{t("Details")}}', - 'x-component': 'Tabs.TabPane', - 'x-designer': 'Tabs.Designer', - 'x-component-props': {}, - properties: { - grid: { - type: 'void', - 'x-component': 'Grid', - 'x-initializer': 'RecordBlockInitializers', - properties: {}, - }, - }, - }, - }, - }, - }, - }, - }, - }, - }, + // 表单区块内暂时屏蔽【打开弹窗】按钮 + // { + // type: 'item', + // title: '{{t("Popup")}}', + // component: 'CustomizeActionInitializer', + // schema: { + // type: 'void', + // title: '{{ t("Popup") }}', + // 'x-action': 'customize:popup', + // 'x-designer': 'Action.Designer', + // 'x-component': 'Action', + // 'x-component-props': { + // openMode: 'drawer', + // }, + // properties: { + // drawer: { + // type: 'void', + // title: '{{ t("Popup") }}', + // 'x-component': 'Action.Container', + // 'x-component-props': { + // className: 'nb-action-popup', + // }, + // properties: { + // tabs: { + // type: 'void', + // 'x-component': 'Tabs', + // 'x-component-props': {}, + // 'x-initializer': 'TabPaneInitializers', + // properties: { + // tab1: { + // type: 'void', + // title: '{{t("Details")}}', + // 'x-component': 'Tabs.TabPane', + // 'x-designer': 'Tabs.Designer', + // 'x-component-props': {}, + // properties: { + // grid: { + // type: 'void', + // 'x-component': 'Grid', + // 'x-initializer': 'RecordBlockInitializers', + // properties: {}, + // }, + // }, + // }, + // }, + // }, + // }, + // }, + // }, + // }, + // }, { type: 'item', title: '{{t("Save record")}}', @@ -154,56 +155,57 @@ export const CreateFormActionInitializers = { type: 'subMenu', title: '{{t("Customize")}}', children: [ - { - type: 'item', - title: '{{t("Popup")}}', - component: 'CustomizeActionInitializer', - schema: { - type: 'void', - title: '{{ t("Popup") }}', - 'x-action': 'customize:popup', - 'x-designer': 'Action.Designer', - 'x-component': 'Action', - 'x-component-props': { - openMode: 'drawer', - }, - properties: { - drawer: { - type: 'void', - title: '{{ t("Popup") }}', - 'x-component': 'Action.Container', - 'x-component-props': { - className: 'nb-action-popup', - }, - properties: { - tabs: { - type: 'void', - 'x-component': 'Tabs', - 'x-component-props': {}, - 'x-initializer': 'TabPaneInitializers', - properties: { - tab1: { - type: 'void', - title: '{{t("Details")}}', - 'x-component': 'Tabs.TabPane', - 'x-designer': 'Tabs.Designer', - 'x-component-props': {}, - properties: { - grid: { - type: 'void', - 'x-component': 'Grid', - 'x-initializer': 'RecordBlockInitializers', - properties: {}, - }, - }, - }, - }, - }, - }, - }, - }, - }, - }, + // 添加弹窗内暂时屏蔽【打开弹窗】按钮 + // { + // type: 'item', + // title: '{{t("Popup")}}', + // component: 'CustomizeActionInitializer', + // schema: { + // type: 'void', + // title: '{{ t("Popup") }}', + // 'x-action': 'customize:popup', + // 'x-designer': 'Action.Designer', + // 'x-component': 'Action', + // 'x-component-props': { + // openMode: 'drawer', + // }, + // properties: { + // drawer: { + // type: 'void', + // title: '{{ t("Popup") }}', + // 'x-component': 'Action.Container', + // 'x-component-props': { + // className: 'nb-action-popup', + // }, + // properties: { + // tabs: { + // type: 'void', + // 'x-component': 'Tabs', + // 'x-component-props': {}, + // 'x-initializer': 'TabPaneInitializers', + // properties: { + // tab1: { + // type: 'void', + // title: '{{t("Details")}}', + // 'x-component': 'Tabs.TabPane', + // 'x-designer': 'Tabs.Designer', + // 'x-component-props': {}, + // properties: { + // grid: { + // type: 'void', + // 'x-component': 'Grid', + // 'x-initializer': 'RecordBlockInitializers', + // properties: {}, + // }, + // }, + // }, + // }, + // }, + // }, + // }, + // }, + // }, + // }, { type: 'item', title: '{{t("Save record")}}',