king
2023-02-17 2e3bf38aced62c8ecf4af58ca2685f09d3d47dde
src/menu/datasource/verifycard/index.jsx
@@ -759,16 +759,7 @@
  copyDatasource = () => {
    const { config } = this.props
    const { columns, scripts } = this.state
    if (columns.length === 0) {
      notification.warning({
        top: 92,
        message: '请添加字段集!',
        duration: 5
      })
      return
    }
    const { columns, subColumns, scripts } = this.state
    this.settingForm.handleConfirm().then(res => {
      delete res.supModule
@@ -777,7 +768,7 @@
      let source = {
        key: 'interface',
        type: 'line',
        data: {setting: res, columns, scripts, pageable: false, format: 'array', name: res.name, status: 'false', type: 'interface', uuid: '' }
        data: {setting: res, columns, subColumns, scripts, pageable: false, format: 'array', name: res.name, status: 'false', type: 'interface', uuid: '' }
      }
      try {
@@ -825,6 +816,15 @@
      }
      if (config.subtype !== 'basetable') {
        let subColumns = []
        if (config.subtype === 'dualdatacard' && res.data.subColumns) {
          subColumns = res.data.subColumns.map(col => {
            col.uuid = Utils.getuuid()
            return col
          })
        }
        this.setState({
          scripts: res.data.scripts.map(col => {
            col.uuid = Utils.getuuid()
@@ -834,6 +834,7 @@
            col.uuid = Utils.getuuid()
            return col
          }),
          subColumns: subColumns,
          setting: res.data.setting,
          median: res.data.setting,
          reload: true,
@@ -926,6 +927,7 @@
            {!reload ? <SettingForm
              config={config}
              columns={columns}
              subColumns={subColumns}
              setting={setting}
              scripts={scripts}
              updateStatus={(res) => this.setState({median: {...res}})}