king
2021-01-07 2292d1826e69e21c8a411c217faef635fe57d458
src/tabviews/commontable/index.jsx
@@ -225,10 +225,6 @@
        config.easyCode = _curUserConfig.easyCode || config.easyCode || ''
        config.action = config.action.map(item => {
          if (item.execMode) {
            item.OpenType = 'funcbutton'
          }
          if (_curUserConfig.action[item.uuid]) {
            delete _curUserConfig.action[item.uuid].label
            item = {...item, ..._curUserConfig.action[item.uuid]}
@@ -267,10 +263,8 @@
      config.action.forEach(item => {
        item.logLabel = MenuName + '-' + item.label // 用于sPC_TableData_InUpDe记录操作按钮
        if (item.execMode) {
          item.OpenType = 'funcbutton'
        }
        item.$menuId = this.props.MenuID
        if (item.position === 'toolbar') {
          _actions.push(item)
        } else if (item.position === 'grid') {
@@ -744,16 +738,18 @@
  /**
   * @description 导出Excel时,获取页面搜索排序等参数
   */
  getexceloutparam = () => {
    const { MenuName } = this.props
  getexceloutparam = (menuId, btnId) => {
    const { MenuName, MenuID } = this.props
    const { arr_field, orderBy, search, setting} = this.state
    return {
    if (MenuID !== menuId) return
    MKEmitter.emit('execExcelout', MenuID, btnId, {
      arr_field: arr_field,
      orderBy: orderBy || setting.order,
      search: search,
      menuName: MenuName
    }
    })
  }
  /**
@@ -918,6 +914,7 @@
    MKEmitter.addListener('reloadData', this.reloadData)
    MKEmitter.addListener('reloadMenuView', this.reloadMenuView)
    MKEmitter.addListener('resetActiveMenu', this.resetActiveMenu)
    MKEmitter.addListener('getexceloutparam', this.getexceloutparam)
  }
  /**
@@ -931,6 +928,7 @@
    MKEmitter.removeListener('reloadData', this.reloadData)
    MKEmitter.removeListener('reloadMenuView', this.reloadMenuView)
    MKEmitter.removeListener('resetActiveMenu', this.resetActiveMenu)
    MKEmitter.removeListener('getexceloutparam', this.getexceloutparam)
  }
  render() {
@@ -968,7 +966,6 @@
                      selectedData={selectedData}
                      ContainerId={this.state.ContainerId}
                      refreshdata={this.refreshbyaction}
                      getexceloutparam={this.getexceloutparam}
                    />
                  </div>
                  <div className="main-table-box">
@@ -1021,7 +1018,6 @@
                    loading={this.state.loading}
                    ContainerId={this.state.ContainerId}
                    refreshdata={this.refreshbyaction}
                    getexceloutparam={this.getexceloutparam}
                    handleTableId={this.handleTableId}
                  />
                </Col>
@@ -1034,7 +1030,6 @@
                    plot={item}
                    config={config}
                    data={this.state.data}
                    getexceloutparam={this.getexceloutparam}
                    loading={this.state.loading}
                  />
                </Col>