king
2020-01-10 1b0fd0a20d54068f0f4716177780e00a75b860ef
src/components/sidemenu/editthdmenu/index.jsx
@@ -18,6 +18,7 @@
import './index.scss'
const ComTableConfig = asyncLoadComponent(() => import('@/templates/comtableconfig'))
const FormTabConfig = asyncLoadComponent(() => import('@/templates/formtabconfig'))
const ModalConfig = asyncLoadComponent(() => import('@/templates/modalconfig'))
const SubTable = asyncLoadComponent(() => import('@/templates/subtableconfig'))
@@ -447,7 +448,7 @@
  }
  handleSubConfig = (item, originMenu, config, type) => {
    if (type === 'button') {
    if (type === 'button') { // 三级菜单页面,按钮配置
      if (item.OpenType === 'pop') {
        let pageParam = ''
        if (config && config.type === 'Modal') {
@@ -462,7 +463,7 @@
          tabview: 'Modal'
        })
      }
    } else if (type === 'tab') {
    } else if (type === 'tab') { // 三级菜单页面,标签配置
      if (item.type === 'SubTable' || item.tabType === 'SubTable') {
        this.setState({
          editMenu: originMenu,
@@ -471,7 +472,7 @@
          tabview: 'SubTable'
        })
      }
    } else if (type === 'tabButton') {
    } else if (type === 'tabButton') { // 三级菜单下,标签下,按钮配置
      let pageParam = ''
      if (config && config.type === 'Modal') {
        pageParam = config
@@ -482,6 +483,18 @@
        editAction: item,
        btnParam: pageParam,
        tabview: 'Modal'
      })
    } else if (type === 'tabview') { // 三级菜单下,打开新标签页或当前页跳转,类型的按钮配置
      let pageParam = ''
      if (config && config.type === 'formTab') {
        pageParam = config
      }
      this.setState({
        editMenu: originMenu,
        editAction: item,
        btnParam: pageParam,
        tabview: 'FormTab'
      })
    }
  }
@@ -623,6 +636,15 @@
            handleSubConfig={this.handleSubConfig}
          />
        }
        {this.state.tabview === 'FormTab' &&
          <FormTabConfig
            menu={this.state.editMenu}
            config={this.state.btnParam}
            editAction={this.state.editAction}
            handleConfig={this.handleConfig}
            handleSubConfig={this.handleSubConfig}
          />
        }
        {/* 图片预览 */}
        <Preview cancel={this.cancelPrePicture} preview={this.state.preview} template={this.state.pretemplate} confirm={this.useTemplate}/>
        {/* 解冻菜单模态框 */}