king
2021-10-18 ccbd330b46d2bddcf0228fd834bb82d482de3613
2021-10-18
2个文件已修改
38 ■■■■■ 已修改文件
src/tabviews/commontable/index.jsx 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/zshare/automatic/index.jsx 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/commontable/index.jsx
@@ -75,11 +75,11 @@
   * @description 获取页面配置信息
   */
  async loadconfig () {
    const { permAction, permMenus, param, MenuName } = this.props
    const { permAction, permMenus, param, MenuName, MenuID } = this.props
    let _param = {
      func: 'sPC_Get_LongParam',
      MenuID: this.props.MenuID
      MenuID: MenuID
    }
    let result = await Api.getCacheConfig(_param)
@@ -89,7 +89,7 @@
      try { // 配置信息解析
        config = JSON.parse(window.decodeURIComponent(window.atob(result.LongParam)))
        config.MenuID = this.props.MenuID
        config.MenuID = MenuID
        config.MenuName = MenuName
        config.setting.MenuName = MenuName
        config.setting.$name = MenuName
@@ -160,7 +160,21 @@
      if (this.props.menuType !== 'HS') {
        config.action = config.action.filter(item => permAction[item.uuid])
        config.tabgroups.forEach(group => {
          group.sublist = group.sublist.filter(tab => permAction[tab.linkTab])
          group.sublist = group.sublist.filter(tab => {
            if (tab.supMenu === 'mainTable') {
              tab.supMenu = MenuID
            }
            return permAction[tab.linkTab]
          })
        })
      } else {
        config.tabgroups.forEach(group => {
          group.sublist = group.sublist.map(tab => {
            if (tab.supMenu === 'mainTable') {
              tab.supMenu = MenuID
            }
            return tab
          })
        })
      }
      // 去除空行标签
@@ -1068,7 +1082,7 @@
  }
  render() {
    const { menuType } = this.props
    const { menuType, MenuID } = this.props
    const { BID, setting, searchlist, pageSize, actions, columns, loadingview, viewlost, pickup, config, chartId, search, selectedData, shortcuts, autoMatic } = this.state
    return (
@@ -1098,7 +1112,7 @@
                      actions={actions}
                      columns={columns}
                      dict={this.state.dict}
                      MenuID={this.props.MenuID}
                      MenuID={MenuID}
                      selectedData={selectedData}
                      ContainerId={this.state.ContainerId}
                    />
@@ -1108,7 +1122,8 @@
                      <Switch title="收起" className="main-pickup" checkedChildren="开" unCheckedChildren="关" checked={pickup} onChange={this.pickupChange} /> : null
                    }
                    <MainTable
                      tableId="mainTable"
                      MenuID={MenuID}
                      tableId={MenuID}
                      pickup={pickup}
                      setting={setting}
                      columns={columns}
@@ -1116,7 +1131,6 @@
                      dict={this.state.dict}
                      data={this.state.data}
                      total={this.state.total}
                      MenuID={this.props.MenuID}
                      loading={this.state.loading}
                      statFValue={this.state.statFValue}
                      ContainerId={this.state.ContainerId}
@@ -1133,11 +1147,11 @@
                  <CardComponent
                    BID={BID}
                    plot={item}
                    MenuID={MenuID}
                    config={config}
                    tableId={MenuID}
                    columns={columns}
                    tableId="mainTable"
                    data={this.state.data}
                    MenuID={this.props.MenuID}
                    loading={this.state.loading}
                    ContainerId={this.state.ContainerId}
                    handleTableId={this.handleTableId}
@@ -1171,9 +1185,9 @@
                } key={_tab.uuid}>
                  <SubTable
                    Tab={_tab}
                    SupMenuID={MenuID}
                    MenuID={_tab.linkTab}
                    mainSearch={_tab.searchPass === 'true' ? search : null}
                    SupMenuID={this.props.MenuID}
                    ContainerId={this.state.ContainerId}
                    BID={this.state.BIDs[_tab.supMenu] || ''}
                    BData={this.state.BIDs[_tab.supMenu + 'data'] || ''}
src/tabviews/zshare/automatic/index.jsx
@@ -34,7 +34,7 @@
    // const { config } = this.props
    let running = !this.state.running
    // MKEmitter.emit('modifyTabs', config.MenuID, 0)
    // MKEmitter.emit('autoQueryData', config.MenuID, 0)
    this.setState({running: running})
  }