From ba6dfb1792262e4da2399baf50f8268f0524b7ca Mon Sep 17 00:00:00 2001 From: zsmj1994 Date: Thu, 1 Apr 2021 20:13:35 +0800 Subject: [PATCH] =?UTF-8?q?DEC-17991=20chore:=20=E7=94=98=E8=80=81?= =?UTF-8?q?=E5=B8=88=E6=8F=92=E4=BB=B6=E6=8E=A5=E5=8F=A3=E9=97=AE=E9=A2=98?= =?UTF-8?q?=E5=8F=8D=E9=A6=88--=E6=95=B0=E6=8D=AE=E8=BF=9E=E6=8E=A5?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E5=88=9B=E5=BB=BA=E6=97=B6=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?connectionname?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../maintain/forms/components/form.plugin.ts | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/src/modules/pages/maintain/forms/components/form.plugin.ts b/src/modules/pages/maintain/forms/components/form.plugin.ts index ae9646e..d36ba2c 100644 --- a/src/modules/pages/maintain/forms/components/form.plugin.ts +++ b/src/modules/pages/maintain/forms/components/form.plugin.ts @@ -11,24 +11,28 @@ export class FormPlugin extends BI.Widget { plugin: any; render() { - const { connectionType } = this.options.formData; - + const { connectionType, connectionId, connectionName, connectionData } = this.options.formData; + return { type: getPluginWidgetEdit(connectionType), ref: (_ref: any) => { this.plugin = _ref; }, - value: this.options.formData.connectionData, + value: connectionData, // 兼容 + connectionData, + connectionId, + connectionType, + connectionName, }; } public getSubmitValue(): Connection { - const { connectionType, connectionId, connectionName } = this.options.formData; - + const { connectionType, connectionId } = this.options.formData; + return { connectionId, connectionType, - connectionName, + connectionName: this.plugin.getName ? this.plugin.getName() : '', connectionData: this.plugin.getValue(), }; }