From 03a22ec6f9ad7303d10b4c65bb5bc6fa5cbd448a Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期六, 22 十月 2022 23:21:42 +0800 Subject: [PATCH] 2022-10-22 --- src/menu/datasource/verifycard/index.jsx | 49 ++++++++++++++++++++++++++++++++----------------- 1 files changed, 32 insertions(+), 17 deletions(-) diff --git a/src/menu/datasource/verifycard/index.jsx b/src/menu/datasource/verifycard/index.jsx index 66a6a93..ec62f40 100644 --- a/src/menu/datasource/verifycard/index.jsx +++ b/src/menu/datasource/verifycard/index.jsx @@ -739,6 +739,7 @@ } pasteSubmit = () => { + const { config } = this.props const { setting } = this.state this.pasteFormRef.handleConfirm().then(res => { @@ -762,21 +763,35 @@ res.data.setting.supModule = setting.supModule } - this.setState({ - scripts: res.data.scripts.map(col => { - col.uuid = Utils.getuuid() - return col - }), - columns: res.data.columns.map(col => { - col.uuid = Utils.getuuid() - return col - }), - setting: res.data.setting, - reload: true, - pvisible: false - }, () => { - this.setState({reload: false}) - }) + if (config.subtype !== 'basetable') { + this.setState({ + scripts: res.data.scripts.map(col => { + col.uuid = Utils.getuuid() + return col + }), + columns: res.data.columns.map(col => { + col.uuid = Utils.getuuid() + return col + }), + setting: res.data.setting, + reload: true, + pvisible: false + }, () => { + this.setState({reload: false}) + }) + } else { + this.setState({ + scripts: res.data.scripts.map(col => { + col.uuid = Utils.getuuid() + return col + }), + setting: res.data.setting, + reload: true, + pvisible: false + }, () => { + this.setState({reload: false}) + }) + } }) } @@ -834,7 +849,7 @@ wrappedComponentRef={(inst) => this.settingForm = inst} /> : null} </TabPane> - <TabPane tab={ + {config.subtype !== 'basetable' ? <TabPane tab={ <span> 瀛楁闆� {columns.length ? <span className="count-tip">{columns.length}</span> : null} @@ -848,7 +863,7 @@ updatefield={this.updatefields} /> <EditTable actions={['edit', 'move', 'copy', 'del', 'clear']} type="datasourcefield" wrappedComponentRef={(inst) => this.datasource = inst} data={columns} columns={colColumns} onChange={(columns) => this.setState({columns})}/> - </TabPane> + </TabPane> : null} <TabPane tab={ <span> 鑷畾涔夎剼鏈� -- Gitblit v1.8.0