king
2020-05-22 5afa6791ca4f1f962273f48f61cfc61107d94561
src/tabviews/subtable/index.jsx
@@ -23,6 +23,7 @@
const { TabPane } = Tabs
const SubAction = asyncComponent(() => import('@/tabviews/zshare/actionList'))
const CardComponent = asyncComponent(() => import('@/tabviews/zshare/cardcomponent'))
const SubTabTable = asyncLoadComponent(() => import('@/tabviews/subtabtable'))
class SubTabViewTable extends Component {
@@ -192,6 +193,7 @@
        // 视图权限
        config.charts = config.charts.filter(item => {
          if (item.Hide === 'true') return false
          if (!item.blacklist || item.blacklist.length === 0) return true
          let _black = item.blacklist.filter(v => {
@@ -204,6 +206,9 @@
            return true
          }
        })
      } else {
        // 隐藏视图
        config.charts = config.charts.filter(item => item.Hide !== 'true')
      }
      if (config.charts.length <= 1) {
@@ -991,13 +996,50 @@
                  </div>
                </Col>
              )
            } else if (item.chartType === 'card') {
              return (
                <Col span={item.width} key={item.uuid}>
                  <CardComponent
                    plot={item}
                    config={config}
                    data={this.state.data}
                    loading={this.state.loading}
                    tableId={this.props.Tab.uuid}
                    buttonTrigger={this.buttonTrigger}
                    handleTableId={this.handleTableId}
                  />
                  <div style={{display: 'none'}}>
                    <SubAction
                      type="sub"
                      menuType={this.props.menuType}
                      triggerBtn={triggerBtn}
                      setting={setting}
                      actions={actions}
                      Tab={this.props.Tab}
                      BID={this.props.BID}
                      BData={this.props.BData}
                      dict={this.state.dict}
                      MenuID={this.props.MenuID}
                      dataManager={this.props.dataManager}
                      permRoles={this.props.permRoles}
                      logcolumns={this.state.logcolumns}
                      refreshdata={this.refreshbyaction}
                      ContainerId={this.props.ContainerId}
                      triggerPopview={this.triggerPopview}
                      getexceloutparam={this.getexceloutparam}
                      gettableselected={this.gettableselected}
                    />
                  </div>
                </Col>
              )
            } else {
              return (
                <Col span={item.width} key={item.uuid}>
                  <ChartComponent
                    plot={item}
                    data={this.state.data}
                    config={config}
                    data={this.state.data}
                    loading={this.state.loading}
                  />
                </Col>
              )