king
2021-04-07 9e100b8804d43d9f7559cdf41b67ed7475a809b8
src/menu/datasource/index.jsx
@@ -1,6 +1,5 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import {connect} from 'react-redux'
import { is, fromJS } from 'immutable'
import { Icon, Modal } from 'antd'
@@ -35,7 +34,7 @@
  }
  editDataSource = () => {
    const { config, menu } = this.props
    const { config } = this.props
    let search = []
    let parents = []
@@ -50,7 +49,7 @@
            _conf = item
            if (_conf.parentId && _conf.tabId) {
              getParents(menu)
              getParents(tab)
            }
          } else {
            getParents(tab)
@@ -60,10 +59,10 @@
    }
    if (config.parentId && config.tabId) {
      getParents(menu)
      getParents(window.GLOB.customMenu)
    }
    parents.unshift(menu)
    parents.unshift(window.GLOB.customMenu)
    parents.forEach(parent => {
      parent.components.forEach(item => {
@@ -110,7 +109,7 @@
  }
  render () {
    const { config, menu } = this.props
    const { config } = this.props
    const { visible, dict, loading, mainSearch } = this.state
    return (
@@ -130,7 +129,7 @@
        >
          <VerifyCard
            dict={dict}
            menu={menu}
            menu={window.GLOB.customMenu}
            mainSearch={mainSearch}
            config={config}
            wrappedComponentRef={(inst) => this.verifyRef = inst}
@@ -141,14 +140,4 @@
  }
}
const mapStateToProps = (state) => {
  return {
    menu: state.customMenu
  }
}
const mapDispatchToProps = () => {
  return {}
}
export default connect(mapStateToProps, mapDispatchToProps)(DataSource)
export default DataSource