king
2020-04-20 6b680ace26dc95031a1b7a3e33f8785c112f787d
2020-04-20
14个文件已修改
2个文件已添加
1036 ■■■■■ 已修改文件
package-lock.json 245 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
package.json 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/commontable/index.jsx 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/subtable/index.jsx 31 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/zshare/actionList/index.jsx 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/comtableconfig/actionform/index.jsx 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/comtableconfig/index.jsx 172 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/comtableconfig/index.scss 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/subtableconfig/actionform/index.jsx 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/subtableconfig/index.jsx 191 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/subtableconfig/index.scss 29 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/zshare/editcomponent/index.jsx 226 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/zshare/editcomponent/index.scss 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/zshare/formconfig.jsx 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/zshare/tabform/index.jsx 33 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/utils.js 28 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
package-lock.json
@@ -35,6 +35,203 @@
        "babel-runtime": "6.26.0"
      }
    },
    "@antv/adjust": {
      "version": "0.2.2",
      "resolved": "https://registry.npmjs.org/@antv/adjust/-/adjust-0.2.2.tgz",
      "integrity": "sha512-b5cABT0WWgKU8pfhW2ssID4FBXDBnHPuxU/HAV3nOMq1lso2BI2/r1hHnrVMZId5Dntb7YrVTOsokiD9DFZ2+w==",
      "requires": {
        "@antv/util": "2.0.8",
        "tslib": "1.10.0"
      }
    },
    "@antv/attr": {
      "version": "0.3.2",
      "resolved": "https://registry.npmjs.org/@antv/attr/-/attr-0.3.2.tgz",
      "integrity": "sha512-31PfcVKeQdPBmr/QD+IC0NB/FbdtVKOXBCNMepFc5/dEs7jphmgG1V4tfAJmcXIHubCTHOjpscTrDIvoKSGvMQ==",
      "requires": {
        "@antv/color-util": "2.0.4",
        "@antv/util": "2.0.8",
        "tslib": "1.10.0"
      }
    },
    "@antv/color-util": {
      "version": "2.0.4",
      "resolved": "https://registry.npmjs.org/@antv/color-util/-/color-util-2.0.4.tgz",
      "integrity": "sha512-CM9bIuykFTKPKbp8iDv2hHfY9QoaAOAyqFKWoV7ux1ZlFOA3KfRwcBDJtk0WlMdhzuZyhMGq0sBlxHCs9YBsVQ==",
      "requires": {
        "@antv/util": "2.0.8",
        "tslib": "1.10.0"
      }
    },
    "@antv/component": {
      "version": "0.5.6",
      "resolved": "https://registry.npmjs.org/@antv/component/-/component-0.5.6.tgz",
      "integrity": "sha512-xT9s+gS6b8P+t/tc1ulOBxNe2nveQ0hHQWB5jyCXnpS57B9GINgwjDv0uI280PScIQCa8rkn1eRZYzV1OMeb2w==",
      "requires": {
        "@antv/dom-util": "2.0.2",
        "@antv/g-base": "0.4.4",
        "@antv/matrix-util": "2.0.7",
        "@antv/path-util": "2.0.7",
        "@antv/scale": "0.3.1",
        "@antv/util": "2.0.8",
        "tslib": "1.10.0"
      }
    },
    "@antv/coord": {
      "version": "0.2.7",
      "resolved": "https://registry.npmjs.org/@antv/coord/-/coord-0.2.7.tgz",
      "integrity": "sha512-0xfUYANsmvvvjmCm0ZuT2Bw1448Mm5EbizeBKJlPIlaV4Cf3Fz+ZdDVnRdhcVs7psSromRX+LqrjkxvT3GikLQ==",
      "requires": {
        "@antv/matrix-util": "2.0.7",
        "@antv/util": "2.0.8",
        "tslib": "1.10.0"
      }
    },
    "@antv/dom-util": {
      "version": "2.0.2",
      "resolved": "https://registry.npmjs.org/@antv/dom-util/-/dom-util-2.0.2.tgz",
      "integrity": "sha512-i/rh385casRd6OA4rbpbA2jyiwY/w7PtkA+74mH43PiBzOcLpDg1jEWR9dMO0tIqUzHQWWqKNNjmXVubl4GS6g==",
      "requires": {
        "tslib": "1.10.0"
      }
    },
    "@antv/event-emitter": {
      "version": "0.1.2",
      "resolved": "https://registry.npmjs.org/@antv/event-emitter/-/event-emitter-0.1.2.tgz",
      "integrity": "sha512-6C6NJOdoNVptCr5y9BVOhKkCgW7LFs/SpcRyAExUeSjAm0zJqcqNkSIRGsXYhj4PJI+CZICHzGwwiSnIsE68Ug=="
    },
    "@antv/g-base": {
      "version": "0.4.4",
      "resolved": "https://registry.npmjs.org/@antv/g-base/-/g-base-0.4.4.tgz",
      "integrity": "sha512-P5qptpFy4QiEiQsESNVxvLJsfJJkTuJyfgchP4tUv/g3Ir6xn3Hj8mFbyjesOJ4/wWyhABYTpekK0HNWr1WiXA==",
      "requires": {
        "@antv/event-emitter": "0.1.2",
        "@antv/g-math": "0.1.3",
        "@antv/matrix-util": "2.0.7",
        "@antv/path-util": "2.0.7",
        "@antv/util": "2.0.8",
        "@types/d3-timer": "1.0.9",
        "d3-ease": "1.0.6",
        "d3-interpolate": "1.4.0",
        "d3-timer": "1.0.10"
      }
    },
    "@antv/g-canvas": {
      "version": "0.4.8",
      "resolved": "https://registry.npmjs.org/@antv/g-canvas/-/g-canvas-0.4.8.tgz",
      "integrity": "sha512-OR9n+w4sCEnTgscjEr5mk2Y48JEKfdetZiX/2rRnJXdETH3oqoogHTmrQkT5AqS2vKNdi6xErXIO/Wg2fQs1aA==",
      "requires": {
        "@antv/g-base": "0.4.4",
        "@antv/g-math": "0.1.3",
        "@antv/path-util": "2.0.7",
        "@antv/util": "2.0.8",
        "gl-matrix": "3.3.0"
      }
    },
    "@antv/g-math": {
      "version": "0.1.3",
      "resolved": "https://registry.npmjs.org/@antv/g-math/-/g-math-0.1.3.tgz",
      "integrity": "sha512-m4jF1Xm9bSTDLU35u3bSW9UcqJJVxU+E+bKtJgNfXUiDwHILYJey825+ApsZ8yjU7SD1kDP6GH6NTGzmChszEQ==",
      "requires": {
        "@antv/util": "2.0.8",
        "gl-matrix": "3.3.0"
      }
    },
    "@antv/g-svg": {
      "version": "0.4.4",
      "resolved": "https://registry.npmjs.org/@antv/g-svg/-/g-svg-0.4.4.tgz",
      "integrity": "sha512-oHhfT3OhckGpBNlLM+FY5l6ysA044pqJ3CQ/NNqS269PwAXqswu7GbIIDmiy6lUURtaAVgyYxbAddoCnCvZ1Kg==",
      "requires": {
        "@antv/g-base": "0.4.4",
        "@antv/g-math": "0.1.3",
        "@antv/util": "2.0.8",
        "detect-browser": "4.8.0"
      }
    },
    "@antv/g2": {
      "version": "4.0.7",
      "resolved": "https://registry.npmjs.org/@antv/g2/-/g2-4.0.7.tgz",
      "integrity": "sha512-Eacs+kehvkfuQkgWbhIpc2xlaruZtNSOAG4wzFFtskPGcTgL1mcKr6+H/ByTWYug79f8FBax4PSqdj4e+iLSNw==",
      "requires": {
        "@antv/adjust": "0.2.2",
        "@antv/attr": "0.3.2",
        "@antv/color-util": "2.0.4",
        "@antv/component": "0.5.6",
        "@antv/coord": "0.2.7",
        "@antv/event-emitter": "0.1.2",
        "@antv/g-base": "0.4.4",
        "@antv/g-canvas": "0.4.8",
        "@antv/g-svg": "0.4.4",
        "@antv/matrix-util": "2.0.7",
        "@antv/path-util": "2.0.7",
        "@antv/scale": "0.3.1",
        "@antv/util": "2.0.8",
        "tslib": "1.10.0"
      }
    },
    "@antv/g2plot": {
      "version": "1.0.3",
      "resolved": "https://registry.npmjs.org/@antv/g2plot/-/g2plot-1.0.3.tgz",
      "integrity": "sha512-328WdD4sf9P/Q49QQDOszyOIscmmh4azXg2gYJNiULHZSLeCtEd+Car/PrL4lcfKUgL0Y4Ah5kyuC45WmHkg4g==",
      "requires": {
        "@antv/component": "0.5.6",
        "@antv/coord": "0.2.7",
        "@antv/dom-util": "2.0.2",
        "@antv/event-emitter": "0.1.2",
        "@antv/g-base": "0.4.4",
        "@antv/g-canvas": "0.4.8",
        "@antv/g-svg": "0.4.4",
        "@antv/g2": "4.0.7",
        "@antv/matrix-util": "2.0.7",
        "@antv/scale": "0.3.1",
        "@antv/util": "2.0.8",
        "d3-regression": "1.3.4",
        "resize-observer-polyfill": "1.5.1",
        "warning": "4.0.3"
      }
    },
    "@antv/gl-matrix": {
      "version": "2.7.1",
      "resolved": "https://registry.npmjs.org/@antv/gl-matrix/-/gl-matrix-2.7.1.tgz",
      "integrity": "sha512-oOWcVNlpELIKi9x+Mm1Vwbz8pXfkbJKykoCIOJ/dNK79hSIANbpXJ5d3Rra9/wZqK6MC961B7sybFhPlLraT3Q=="
    },
    "@antv/matrix-util": {
      "version": "2.0.7",
      "resolved": "https://registry.npmjs.org/@antv/matrix-util/-/matrix-util-2.0.7.tgz",
      "integrity": "sha512-bogifQY8jplWtSTZsPqBOdBlDdkM7IwDqYL8eMYL8OaSyOPCS7l9bnEQjQ9qTAwfCd7wHTuPoCnCpbiR8BYFvQ==",
      "requires": {
        "@antv/gl-matrix": "2.7.1",
        "@antv/util": "2.0.8",
        "tslib": "1.10.0"
      }
    },
    "@antv/path-util": {
      "version": "2.0.7",
      "resolved": "https://registry.npmjs.org/@antv/path-util/-/path-util-2.0.7.tgz",
      "integrity": "sha512-1gvgPxYjQ7QGqeFLJC8C3cQd7hP+3GQSdSTKoSSW4Q7nVXdibVx8D521kJe2NkketdKLwsT8gmwJWcu+NU43+w==",
      "requires": {
        "@antv/util": "2.0.8",
        "tslib": "1.10.0"
      }
    },
    "@antv/scale": {
      "version": "0.3.1",
      "resolved": "https://registry.npmjs.org/@antv/scale/-/scale-0.3.1.tgz",
      "integrity": "sha512-bl1IAuiwVasrCpgeeT/aXYpiCiL5T3vJSWgFiRLPJeWhMGCTfsMYP/XKp6gqpD0nVj/WsF2VsoUhJG4VlyY3Pw==",
      "requires": {
        "@antv/util": "2.0.8",
        "fecha": "3.0.3",
        "tslib": "1.10.0"
      }
    },
    "@antv/util": {
      "version": "2.0.8",
      "resolved": "https://registry.npmjs.org/@antv/util/-/util-2.0.8.tgz",
      "integrity": "sha512-G9QRygQJ8UNGMi8L1dfMIa4SofbEO+jkXwvRY4ek/MLd04Q01UN0U28JeMFzw6FCKJdxiFu+2uwT/zjoFr3QoQ==",
      "requires": {
        "tslib": "1.10.0"
      }
    },
    "@babel/code-frame": {
      "version": "7.5.5",
      "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.5.5.tgz",
@@ -1524,6 +1721,11 @@
      "requires": {
        "@babel/types": "7.6.1"
      }
    },
    "@types/d3-timer": {
      "version": "1.0.9",
      "resolved": "https://registry.npmjs.org/@types/d3-timer/-/d3-timer-1.0.9.tgz",
      "integrity": "sha512-WvfJ3LFxBbWjqRGz9n7GJt08RrTHPJDVsIwwoCMROlqF+iDacYiAFjf9oqnq0mXpb2juA2N/qjKP+MKdal3YNQ=="
    },
    "@types/eslint-visitor-keys": {
      "version": "1.0.0",
@@ -4211,6 +4413,34 @@
        "type": "1.0.3"
      }
    },
    "d3-color": {
      "version": "1.4.0",
      "resolved": "https://registry.npmjs.org/d3-color/-/d3-color-1.4.0.tgz",
      "integrity": "sha512-TzNPeJy2+iEepfiL92LAAB7fvnp/dV2YwANPVHdDWmYMm23qIJBYww3qT8I8C1wXrmrg4UWs7BKc2tKIgyjzHg=="
    },
    "d3-ease": {
      "version": "1.0.6",
      "resolved": "https://registry.npmjs.org/d3-ease/-/d3-ease-1.0.6.tgz",
      "integrity": "sha512-SZ/lVU7LRXafqp7XtIcBdxnWl8yyLpgOmzAk0mWBI9gXNzLDx5ybZgnRbH9dN/yY5tzVBqCQ9avltSnqVwessQ=="
    },
    "d3-interpolate": {
      "version": "1.4.0",
      "resolved": "https://registry.npmjs.org/d3-interpolate/-/d3-interpolate-1.4.0.tgz",
      "integrity": "sha512-V9znK0zc3jOPV4VD2zZn0sDhZU3WAE2bmlxdIwwQPPzPjvyLkd8B3JUVdS1IDUFDkWZ72c9qnv1GK2ZagTZ8EA==",
      "requires": {
        "d3-color": "1.4.0"
      }
    },
    "d3-regression": {
      "version": "1.3.4",
      "resolved": "https://registry.npmjs.org/d3-regression/-/d3-regression-1.3.4.tgz",
      "integrity": "sha512-o5nwONeooEfy+L98Ej+WPccb6LgLKtsnXLuWzXb8Ta1mN95Jy0Aw9X2TxV+S+OW+NcrBfEjxSURoSlQfVAEkrg=="
    },
    "d3-timer": {
      "version": "1.0.10",
      "resolved": "https://registry.npmjs.org/d3-timer/-/d3-timer-1.0.10.tgz",
      "integrity": "sha512-B1JDm0XDaQC+uvo4DT79H0XmBskgS3l6Ve+1SBCfxgmtIb1AVrPIoqd+nPSv+loMX8szQ0sVUhGngL7D5QPiXw=="
    },
    "damerau-levenshtein": {
      "version": "1.0.5",
      "resolved": "https://registry.npmjs.org/damerau-levenshtein/-/damerau-levenshtein-1.0.5.tgz",
@@ -4421,6 +4651,11 @@
      "version": "1.0.4",
      "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz",
      "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA="
    },
    "detect-browser": {
      "version": "4.8.0",
      "resolved": "https://registry.npmjs.org/detect-browser/-/detect-browser-4.8.0.tgz",
      "integrity": "sha512-f4h2dFgzHUIpjpBLjhnDIteXv8VQiUm8XzAuzQtYUqECX/eKh67ykuiVoyb7Db7a0PUSmJa3OGXStG0CbQFUVw=="
    },
    "detect-indent": {
      "version": "4.0.0",
@@ -6895,6 +7130,11 @@
        }
      }
    },
    "fecha": {
      "version": "3.0.3",
      "resolved": "https://registry.npmjs.org/fecha/-/fecha-3.0.3.tgz",
      "integrity": "sha512-6LQK/1jud/FZnfEEZJ7y81vw7ge81DNd/XEsX0hgMUjhS+QMljkb1C0czBaP7dMNRVrd5mw/J2J7qI2Nw+TWZw=="
    },
    "figgy-pudding": {
      "version": "3.5.1",
      "resolved": "https://registry.npmjs.org/figgy-pudding/-/figgy-pudding-3.5.1.tgz",
@@ -7725,6 +7965,11 @@
        "assert-plus": "1.0.0"
      }
    },
    "gl-matrix": {
      "version": "3.3.0",
      "resolved": "https://registry.npmjs.org/gl-matrix/-/gl-matrix-3.3.0.tgz",
      "integrity": "sha512-COb7LDz+SXaHtl/h4LeaFcNdJdAQSDeVqjiIihSXNrkWObZLhDI4hIkZC11Aeqp7bcE72clzB0BnDXr2SmslRA=="
    },
    "glob": {
      "version": "7.1.4",
      "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz",
package.json
@@ -3,6 +3,8 @@
  "version": "0.1.0",
  "private": true,
  "dependencies": {
    "@antv/g2": "^4.0.7",
    "@antv/g2plot": "^1.0.3",
    "@babel/core": "7.5.5",
    "@svgr/webpack": "4.3.2",
    "@typescript-eslint/eslint-plugin": "1.13.0",
src/tabviews/commontable/index.jsx
@@ -1188,7 +1188,7 @@
  }
  render() {
    const { view, setting, searchlist, actions, columns, loadingview, viewlost, pickup, config, triggerBtn, userConfig, tabActive } = this.state
    const { view, setting, searchlist, actions, columns, loadingview, viewlost, pickup, config, triggerBtn, userConfig, tabActive, search } = this.state
    return (
      <div>
@@ -1266,6 +1266,7 @@
                            Tab={_tab}
                            menuType="main"
                            MenuID={_tab.linkTab}
                            mainSearch={_tab.searchPass === 'true' ? search : null}
                            userConfig={userConfig ? userConfig[_tab.uuid] : null}
                            triggerBtn={triggerBtn}
                            SupMenuID={this.props.MenuID}
src/tabviews/subtable/index.jsx
@@ -31,6 +31,7 @@
    BData: PropTypes.any,            // 上级数据
    MenuID: PropTypes.string,        // 菜单Id
    SupMenuID: PropTypes.string,     // 上级菜单Id
    mainSearch: PropTypes.any,       // 主表搜索条件
    ContainerId: PropTypes.any,      // 三级菜单Container(html) ID
    handleTableId: PropTypes.func,   // 控制表格数据切换时,更新在主表中的id
    handleMainTable: PropTypes.func, // 刷新主表
@@ -81,6 +82,10 @@
      this.setState({
        triggerBtn: trigger
      })
    } else if (!this.props.Tab.supMenu && nextProps.mainSearch && !is(fromJS(this.props.mainSearch), fromJS(nextProps.mainSearch))) {
      this.setState({}, () => {
        this.loadmaindata()
      })
    }
  }
@@ -474,9 +479,15 @@
   * @description 获取用户自定义存储过程传参
   */
  getCustomParam = (BID) => {
    const { mainSearch } = this.props
    const { pageIndex, pageSize, orderBy, search, setting } = this.state
    let _search = Utils.formatCustomMainSearch(search)
    let searches = search
    if (mainSearch && mainSearch.length > 0) { // 主表搜索条件
      searches = [...mainSearch, ...search]
    }
    let _search = Utils.formatCustomMainSearch(searches)
    let param = {
      PageIndex: pageIndex,
@@ -515,9 +526,15 @@
   * @description 获取系统存储过程 sPC_Get_TableData 的参数
   */
  getDefaultParam = (BID) => {
    const { mainSearch } = this.props
    const { arr_field, pageIndex, pageSize, orderBy, search, setting } = this.state
    let _search = Utils.joinMainSearchkey(search)
    let searches = search
    if (mainSearch && mainSearch.length > 0) { // 主表搜索条件
      searches = [...mainSearch, ...search]
    }
    let _search = Utils.joinMainSearchkey(searches)
    _search = _search ? 'where ' + _search : ''
    let param = {
@@ -679,13 +696,18 @@
   * @description 导出Excel时,获取页面搜索排序等参数
   */
  getexceloutparam = () => {
    const { Tab } = this.props
    const { Tab, mainSearch } = this.props
    const { arr_field, orderBy, search, setting} = this.state
    let searches = search
    if (mainSearch && mainSearch.length > 0) { // 主表搜索条件
      searches = [...mainSearch, ...search]
    }
    return {
      arr_field: arr_field,
      orderBy: orderBy || setting.order,
      search: search,
      search: searches,
      menuName: Tab.label
    }
  }
@@ -713,7 +735,6 @@
        data: record
      }
    })
    // this.refs.subButton.actionTrigger(btn, record)
  }
  /**
src/tabviews/zshare/actionList/index.jsx
@@ -1965,6 +1965,28 @@
    let viewParam = this.props.getexceloutparam()
    let name = `${viewParam.menuName}${moment().format('YYYYMMDDHHmmss')}.xlsx`
    let pageSize = 1000
    if (btn.search === 'true' && viewParam.search && viewParam.search.length > 0) {
      let valid = false
      viewParam.search.forEach(item => {
        if (Array.isArray(item.value)) {
          if (item.value.length > 0) {
            valid = true
          }
        } else if (item.value || item.value === 0) {
          valid = true
        }
      })
      if (!valid) {
        notification.warning({
          top: 92,
          message: '搜索条件不可为空!',
          duration: 5
        })
        return
      }
    }
    
    this.setState({loadingUuid: btn.uuid})
src/templates/comtableconfig/actionform/index.jsx
@@ -111,9 +111,9 @@
      _options = ['label', 'Ot', 'OpenType', 'icon', 'class', 'position', 'tabType', 'linkTab', 'popClose']
    } else if (_opentype === 'excelOut') {    // 导入导出
      if (_intertype === 'outer') {
        _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
        _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
      } else {
        _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
        _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
      }
    } else if (_opentype === 'excelIn') {    // 导入导出
      if (_intertype === 'outer') {
@@ -214,9 +214,9 @@
        _options = ['label', 'Ot', 'OpenType', 'icon', 'class', 'position', 'tabType', 'linkTab', 'popClose']
      } else if (value === 'excelOut') {
        if (this.state.interType === 'outer') {
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
        } else {
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
        }
      } else if (value === 'excelIn') {
        if (this.state.interType === 'outer') {
@@ -363,9 +363,9 @@
      let _options = null
      if (openType === 'excelOut') {
        if (value === 'outer') {
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
        } else {
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
        }
      } else if (openType === 'excelIn') {
        if (value === 'outer') {
src/templates/comtableconfig/index.jsx
@@ -20,7 +20,6 @@
import TabForm from '@/templates/zshare/tabform'
import SearchForm from '@/templates/zshare/searchform'
import ColumnForm from '@/templates/zshare/columnform'
import PasteForm from '@/templates/zshare/pasteform'
import DragElement from '@/templates/zshare/dragelement'
import ColspanForm from '@/templates/zshare/colspanform'
import GridBtnForm from '@/templates/zshare/gridbtnform'
@@ -31,7 +30,7 @@
import VerifyCardPrint from '@/templates/zshare/verifycardprint'
import MenuForm from '@/templates/zshare/menuform'
import TabDragElement from '@/templates/zshare/tabdragelement'
import TransferForm from '@/components/transferform'
import EditComponent from '@/templates/zshare/editcomponent'
import SourceElement from '@/templates/zshare/dragelement/source'
import CreateFunc from '@/templates/zshare/createfunc'
import CreateInterface from '@/templates/zshare/createinterface'
@@ -77,8 +76,6 @@
    tabviews: [],            // 所有标签页
    profileVisible: false,   // 验证信息模态框
    optionLibs: null,        // 自定义下拉选项库
    thawBtnVisible: false,   // 解冻按钮弹窗
    thawbtnlist: null,       // 解冻按钮列表
    thawButtons: [],         // 已选择要解冻的按钮
    activeKey: '0',          // 默认展开基本信息
    sqlVerifing: false       // sql验证
@@ -675,6 +672,21 @@
          tooltip: '外键旨在标签页中执行默认函数(添加)时,替换BID字段',
          initVal: card.foreignKey || '',
          required: false
        },
        {
          type: 'radio',
          key: 'searchPass',
          label: '主表搜索',
          initVal: card.searchPass || 'false',
          tooltip: '使用主表搜索条件时,主表的搜索条件会传入子表中。',
          required: false,
          options: [{
            value: 'true',
            text: '使用'
          }, {
            value: 'false',
            text: '不使用'
          }]
        }
      ]
    })
@@ -2762,86 +2774,6 @@
    })
  }
  /**
   * @description 解冻按钮
   */
  handleThaw = () => {
    const { menu } = this.props
    this.setState({
      thawBtnVisible: true
    })
    Api.getSystemConfig({
      func: 'sPC_Get_FrozenMenu',
      ParentID: menu.MenuID,
      TYPE: 40
    }).then(res => {
      if (res.status) {
        let _list = []
        res.data.forEach(menu => {
          let _conf = ''
          if (menu.ParentParam) {
            try {
              _conf = JSON.parse(window.decodeURIComponent(window.atob(menu.ParentParam)))
            } catch (e) {
              console.warn('Parse Failure')
              _conf = ''
            }
          }
          if (_conf) {
            _list.push({
              key: menu.MenuID,
              title: menu.MenuName,
              btnParam: _conf
            })
          }
        })
        this.setState({
          thawbtnlist: _list
        })
      } else {
        notification.warning({
          top: 92,
          message: res.message,
          duration: 5
        })
      }
    })
  }
  /**
   * @description 解冻按钮提交
   */
  thawBtnSubmit = () => {
    const { thawButtons, config, thawbtnlist } = this.state
    // 三级菜单解除冻结
    if (this.refs.trawmenu.state.targetKeys.length === 0) {
      notification.warning({
        top: 92,
        message: this.state.dict['form.required.select'] + this.state.dict['header.form.thawbutton'],
        duration: 5
      })
    } else {
      thawbtnlist.forEach(item => {
        if (this.refs.trawmenu.state.targetKeys.includes(item.key)) {
          config.action.push(item.btnParam)
        }
      })
      this.setState({
        thawButtons: [...thawButtons, ...this.refs.trawmenu.state.targetKeys],
        config: config,
        thawBtnVisible: false
      })
    }
  }
  handleGroup = (index, type) => {
    let config = JSON.parse(JSON.stringify(this.state.config))
    
@@ -2897,38 +2829,21 @@
    this.props.handleView()
  }
  pasteSubmit = () => {
    const { config } = this.state
    this.pasteFormRef.handleConfirm().then(res => {
  updateConfig = (res) => {
    if (res.type === 'thaw') {
      this.setState({
        thawButtons: res.thawButtons,
        config: res.config
      })
    } else if (res.type === 'paste') {
      if (res.copyType === 'action') {
        this.setState({
          modaltype: ''
        }, () => {
          this.handleAction(res, 'copy')
        })
        this.handleAction(res.content, 'copy')
      } else if (res.copyType === 'columns') {
        if (config.columns && config.columns.length > 0) {
          notification.warning({
            top: 92,
            message: '显示列已存在!',
            duration: 5
          })
          return
        }
        this.setState({
          modaltype: '',
          config: {...config, columns: res.columns}
        })
      } else {
        notification.warning({
          top: 92,
          message: '配置信息格式错误!',
          duration: 5
          config: res.config
        })
      }
    })
    }
  }
  render () {
@@ -3026,9 +2941,6 @@
                      {this.state.dict['header.menu.action.configurable']}
                    </p> : null
                  }
                  <div className="thawbutton" title={this.state.dict['header.form.thawbutton']} onClick={this.handleThaw}>
                    <Icon type="unlock" />
                  </div>
                </div>
                {configAction.map((item, index) => {
                  return (
@@ -3090,6 +3002,7 @@
              </div>
            } bordered={false} extra={
              <div>
                <EditComponent dict={this.state.dict} type="maintable" config={this.state.config} MenuID={this.props.menu.MenuID} thawButtons={this.state.thawButtons} refresh={this.updateConfig}/>
                <Switch className="big" checkedChildren="启" unCheckedChildren="停" checked={this.state.config.enabled} onChange={this.onEnabledChange} />
                <Button type="primary" onClick={this.changeTemplate}>{this.state.dict['header.menu.template.change']}</Button>
                <Button type="primary" onClick={this.submitConfig} loading={this.state.menuloading}>{this.state.dict['header.save']}</Button>
@@ -3114,9 +3027,6 @@
                <Tooltip placement="bottomLeft" overlayClassName="middle" title="在左侧工具栏《按钮》中,选择对应类型的按钮拖至此处添加,如选择按钮类型为表单、新标签页等含有配置页面的按钮,可在左侧工具栏-按钮-可配置按钮处,点击按钮完成相关配置。注:当设置按钮显示位置为表格时,显示列会增加操作列。">
                  <Icon type="question-circle" />
                </Tooltip>
                <div className="copybutton" title={this.state.dict['header.form.paste']} onClick={() => {this.setState({modaltype: 'paste'})}}>
                  <Icon type="snippets" />
                </div>
                <DragElement
                  type="action"
                  list={config.action}
@@ -3410,34 +3320,6 @@
          destroyOnClose
        >
          {this.state.dict['header.menu.config.placeholder']}
        </Modal>
        {/* 解冻按钮模态框 */}
        <Modal
          title={this.state.dict['header.form.thawbutton']}
          okText={this.state.dict['header.confirm']}
          cancelText={this.state.dict['header.cancel']}
          visible={this.state.thawBtnVisible}
          onOk={this.thawBtnSubmit}
          onCancel={() => {this.setState({thawBtnVisible: false, thawbtnlist: null})}}
          destroyOnClose
        >
          {!this.state.thawbtnlist && <Spin style={{marginLeft: 'calc(50% - 22px)', marginTop: '70px', marginBottom: '70px'}} size="large" />}
          {this.state.thawbtnlist && <TransferForm ref="trawmenu" menulist={this.state.thawbtnlist}/>}
        </Modal>
        {/* 按钮配置信息粘贴复制 */}
        <Modal
          title={this.state.dict['header.form.paste']}
          visible={modaltype === 'paste'}
          width={600}
          maskClosable={false}
          onOk={this.pasteSubmit}
          onCancel={() => {this.setState({modaltype: ''})}}
          destroyOnClose
        >
          <PasteForm
            dict={this.state.dict}
            wrappedComponentRef={(inst) => this.pasteFormRef = inst}
          />
        </Modal>
        {this.state.loading && <Spin size="large" />}
      </div>
src/templates/comtableconfig/index.scss
@@ -308,17 +308,6 @@
            display: inline-block;
          }
        }
        .copybutton {
          position: absolute;
          right: 10px;
          top: 5px;
          z-index: 2;
          padding: 5px;
          cursor: pointer;
          i {
            font-size: 16px;
          }
        }
      }
      .column-list {
        position: relative;
src/templates/subtableconfig/actionform/index.jsx
@@ -118,9 +118,9 @@
      _options = ['label', 'Ot', 'OpenType', 'icon', 'class', 'position', 'tabType', 'linkTab', 'popClose']
    } else if (_opentype === 'excelOut') {
      if (_intertype === 'outer') {
        _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
        _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
      } else {
        _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
        _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
      }
    } else if (_opentype === 'excelIn') {
      if (_intertype === 'outer') {
@@ -239,9 +239,9 @@
        _options = ['label', 'Ot', 'OpenType', 'icon', 'class', 'position', 'tabType', 'linkTab', 'popClose']
      } else if (value === 'excelOut') {
        if (this.state.interType === 'outer') {
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
        } else {
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
        }
      } else if (value === 'excelIn') {
        if (this.state.interType === 'outer') {
@@ -407,9 +407,9 @@
      
      if (openType === 'excelOut') {
        if (value === 'outer') {
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'sysInterface', 'interface', 'outerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
        } else {
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination']
          _options = ['label', 'OpenType', 'intertype', 'innerFunc', 'icon', 'class', 'execSuccess', 'execError', 'pagination', 'search']
        }
      } else if (openType === 'excelIn') {
        if (value === 'outer') {
src/templates/subtableconfig/index.jsx
@@ -4,7 +4,7 @@
import { is, fromJS } from 'immutable'
import { DndProvider } from 'react-dnd'
import HTML5Backend from 'react-dnd-html5-backend'
import { Button, Card, Modal, Collapse, notification, Spin, Select, List, Icon, Empty, Switch, Tooltip } from 'antd'
import { Button, Card, Modal, Collapse, notification, Spin, Select, List, Icon, Empty, Switch, Tooltip, message } from 'antd'
import moment from 'moment'
import Api from '@/api'
@@ -20,7 +20,6 @@
import SearchForm from '@/templates/zshare/searchform'
import ColumnForm from '@/templates/zshare/columnform'
import DragElement from '@/templates/zshare/dragelement'
import PasteForm from '@/templates/zshare/pasteform'
import ColspanForm from '@/templates/zshare/colspanform'
import GridBtnForm from '@/templates/zshare/gridbtnform'
import EditCard from '@/templates/zshare/editcard'
@@ -29,7 +28,7 @@
import VerifyCardExcelIn from '@/templates/zshare/verifycardexcelin'
import VerifyCardExcelOut from '@/templates/zshare/verifycardexcelout'
import MenuForm from '@/templates/zshare/menuform'
import TransferForm from '@/components/transferform'
import EditComponent from '@/templates/zshare/editcomponent'
import SourceElement from '@/templates/zshare/dragelement/source'
import CreateFunc from '@/templates/zshare/createfunc'
import CreateInterface from '@/templates/zshare/createinterface'
@@ -83,8 +82,6 @@
    tabviews: [],            // 所有标签页
    profileVisible: false,   // 验证信息模态框
    optionLibs: null,        // 自定义下拉选项库
    thawBtnVisible: false,   // 解冻按钮弹窗
    thawbtnlist: null,       // 解冻按钮列表
    thawButtons: [],         // 已选择要解冻的按钮
    activeKey: '0',          // 默认展开基本信息
    sqlVerifing: false       // sql验证
@@ -2106,86 +2103,6 @@
  }
  /**
   * @description 解冻按钮
   */
  handleThaw = () => {
    const { config } = this.state
    this.setState({
      thawBtnVisible: true
    })
    Api.getSystemConfig({
      func: 'sPC_Get_FrozenMenu',
      ParentID: config.uuid,
      TYPE: 40
    }).then(res => {
      if (res.status) {
        let _list = []
        res.data.forEach(menu => {
          let _conf = ''
          if (menu.ParentParam) {
            try {
              _conf = JSON.parse(window.decodeURIComponent(window.atob(menu.ParentParam)))
            } catch (e) {
              console.warn('Parse Failure')
              _conf = ''
            }
          }
          if (_conf) {
            _list.push({
              key: menu.MenuID,
              title: menu.MenuName,
              btnParam: _conf
            })
          }
        })
        this.setState({
          thawbtnlist: _list
        })
      } else {
        notification.warning({
          top: 92,
          message: res.message,
          duration: 5
        })
      }
    })
  }
  /**
   * @description 解冻按钮提交
   */
  thawBtnSubmit = () => {
    const { thawButtons, config, thawbtnlist } = this.state
    // 三级菜单解除冻结
    if (this.refs.trawmenu.state.targetKeys.length === 0) {
      notification.warning({
        top: 92,
        message: this.state.dict['form.required.select'] + this.state.dict['header.form.thawbutton'],
        duration: 5
      })
    } else {
      thawbtnlist.forEach(item => {
        if (this.refs.trawmenu.state.targetKeys.includes(item.key)) {
          config.action.push(item.btnParam)
        }
      })
      this.setState({
        thawButtons: [...thawButtons, ...this.refs.trawmenu.state.targetKeys],
        config: config,
        thawBtnVisible: false
      })
    }
  }
  /**
   * @description 创建按钮接口(写入)
   */
  btnCreatInterface = () => {
@@ -2244,30 +2161,42 @@
    })
  }
  pasteSubmit = () => {
    this.pasteFormRef.handleConfirm().then(res => {
      if (res.copyType !== 'action') {
        notification.warning({
          top: 92,
          message: '配置信息格式错误!',
          duration: 5
        })
        return
      } else if (!['pop', 'prompt', 'exec', 'excelIn', 'excelOut', 'popview'].includes(res.OpenType)) {
        notification.warning({
          top: 92,
          message: '不支持此打开方式!',
          duration: 5
        })
        return
      }
  copycolumn = () => {
    const { config } = this.state
    let oInput = document.createElement('input')
    let val = {
      copyType: 'columns',
      columns: config.columns
    }
    oInput.value = window.btoa(window.encodeURIComponent(JSON.stringify(val)))
    document.body.appendChild(oInput)
    oInput.select()
    document.execCommand('Copy')
    oInput.className = 'oInput'
    oInput.style.display = 'none'
    message.success('复制成功。')
    document.body.removeChild(oInput)
  }
  updateConfig = (res) => {
    if (res.type === 'thaw') {
      this.setState({
        modaltype: ''
      }, () => {
        this.handleAction(res, 'copy')
        thawButtons: res.thawButtons,
        config: res.config
      })
    })
    } else if (res.type === 'paste') {
      if (res.copyType === 'action') {
        this.handleAction(res.content, 'copy')
      } else if (res.copyType === 'columns') {
        this.setState({
          config: res.config
        })
      }
    }
  }
  render () {
@@ -2359,9 +2288,6 @@
                      {this.state.dict['header.menu.action.configurable']}
                    </p> : null
                  }
                  <div className="thawbutton" title={this.state.dict['header.form.thawbutton']} onClick={this.handleThaw}>
                    <Icon type="unlock" />
                  </div>
                </div>
                {configAction.map((item, index) => {
                  return (
@@ -2395,6 +2321,7 @@
              </div>
            } bordered={false} extra={
              <div>
                <EditComponent dict={this.state.dict} type="subtable" config={this.state.config} thawButtons={this.state.thawButtons} refresh={this.updateConfig}/>
                <Switch className="big" checkedChildren="启" unCheckedChildren="停" checked={this.state.config.enabled} onChange={this.onEnabledChange} />
                <Button type="primary" onClick={this.submitConfig} loading={this.state.menuloading}>{this.state.dict['header.save']}</Button>
                <Button onClick={this.cancelConfig}>{this.state.dict['header.return']}</Button>
@@ -2414,13 +2341,24 @@
                  placeholder={this.state.dict['header.form.search.placeholder']}
                />
              </div>
              {/* <div className="action-list">
                <DragElement
                  type="action"
                  list={this.state.config.action}
                  setting={this.state.config.setting}
                  handleList={this.handleList}
                  handleMenu={this.handleAction}
                  copyElement={(val) => this.handleAction(val, 'copy')}
                  deleteMenu={this.deleteElement}
                  profileMenu={this.profileAction}
                  doubleClickCard={this.btnDoubleClick}
                  placeholder={this.state.dict['header.form.action.placeholder']}
                />
              </div> */}
              <div className="action-list">
                <Tooltip placement="bottomLeft" overlayClassName="middle" title="在左侧工具栏《按钮》中,选择对应类型的按钮拖至此处添加,如选择按钮类型为表单、新标签页等含有配置页面的按钮,可在左侧工具栏-按钮-可配置按钮处,点击按钮完成相关配置。注:当设置按钮显示位置为表格时,显示列会增加操作列。">
                  <Icon type="question-circle" />
                </Tooltip>
                <div className="copybutton" title={this.state.dict['header.form.paste']} onClick={() => {this.setState({modaltype: 'paste'})}}>
                  <Icon type="snippets" />
                </div>
                <DragElement
                  type="action"
                  list={this.state.config.action}
@@ -2438,6 +2376,7 @@
                <Tooltip placement="bottomLeft" overlayClassName="middle" title="在左侧工具栏《显示列》中,选择对应类型的显示列拖至此处添加;或点击《添加显示列》按钮批量添加,选择批量添加时,需提前选择使用表。注:添加合并列时,需设置可选列。">
                  <Icon type="question-circle" />
                </Tooltip>
                {config.columns && config.columns.length > 0 ? <Icon className="column-copy" title="copy" type="copy" onClick={this.copycolumn} /> : null}
                <Switch checkedChildren="开" unCheckedChildren="关" defaultChecked={this.state.showColumnName} onChange={this.onColumnNameChange} />
                <DragElement
                  type="columns"
@@ -2668,34 +2607,6 @@
          destroyOnClose
        >
          {this.state.dict['header.menu.config.placeholder']}
        </Modal>
        {/* 解冻按钮模态框 */}
        <Modal
          title={this.state.dict['header.form.thawbutton']}
          okText={this.state.dict['header.confirm']}
          cancelText={this.state.dict['header.cancel']}
          visible={this.state.thawBtnVisible}
          onOk={this.thawBtnSubmit}
          onCancel={() => {this.setState({thawBtnVisible: false, thawbtnlist: null})}}
          destroyOnClose
        >
          {!this.state.thawbtnlist && <Spin style={{marginLeft: 'calc(50% - 22px)', marginTop: '70px', marginBottom: '70px'}} size="large" />}
          {this.state.thawbtnlist && <TransferForm ref="trawmenu" menulist={this.state.thawbtnlist}/>}
        </Modal>
        {/* 按钮配置信息粘贴复制 */}
        <Modal
          title={this.state.dict['header.form.paste']}
          visible={modaltype === 'paste'}
          width={600}
          maskClosable={false}
          onOk={this.pasteSubmit}
          onCancel={() => {this.setState({modaltype: ''})}}
          destroyOnClose
        >
          <PasteForm
            dict={this.state.dict}
            wrappedComponentRef={(inst) => this.pasteFormRef = inst}
          />
        </Modal>
        {this.state.loading && <Spin size="large" />}
      </div>
src/templates/subtableconfig/index.scss
@@ -59,17 +59,6 @@
        color: #1890ff;
        border-bottom: 1px solid #e8e8e8;
      }
      .thawbutton {
        position: absolute;
        right: 10px;
        top: 0px;
        padding: 0px;
        cursor: pointer;
        i {
          font-size: 16px;
          color: #1890ff;
        }
      }
    }
    .tables {
      .ant-select-selection-selected-value {
@@ -302,17 +291,6 @@
            display: inline-block;
          }
        }
        .copybutton {
          position: absolute;
          right: 10px;
          top: 5px;
          z-index: 2;
          padding: 5px;
          cursor: pointer;
          i {
            font-size: 16px;
          }
        }
      }
      .column-list {
        position: relative;
@@ -322,6 +300,13 @@
          right: 20px;
          top: -10px;
        }
        .column-copy {
          position: absolute;
          font-size: 16px;
          right: 75px;
          top: -7px;
          color: #26C281;
        }
        > .ant-row {
          background: #fafafa;
          border-radius: 4px;
src/templates/zshare/editcomponent/index.jsx
New file
@@ -0,0 +1,226 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { Menu, Dropdown, Icon, Modal, Spin, notification } from 'antd'
import Api from '@/api'
import PasteForm from '@/templates/zshare/pasteform'
import TransferForm from '@/components/transferform'
import './index.scss'
class editComponent extends Component {
  static propTpyes = {
    type: PropTypes.string,
    MenuID: PropTypes.any,
    config: PropTypes.object,
    thawButtons: PropTypes.array,
    refresh: PropTypes.func
  }
  state = {
    thawVisible: false,
    thawbtnlist: null,
    pasteVisible: false
  }
  handleMenuClick = e => {
    if (e.key === 'thaw') {
      this.handleThaw()
    } else if (e.key === 'paste') {
      this.setState({pasteVisible: true})
    }
  }
  /**
   * @description 解冻按钮
   */
  handleThaw = () => {
    const { config } = this.props
    this.setState({
      thawVisible: true
    })
    let uuid = config.uuid
    if (this.props.type === 'maintable') {
      uuid = this.props.MenuID
    }
    Api.getSystemConfig({
      func: 'sPC_Get_FrozenMenu',
      ParentID: uuid,
      TYPE: 40
    }).then(res => {
      if (res.status) {
        let _list = []
        res.data.forEach(menu => {
          let _conf = ''
          if (menu.ParentParam) {
            try {
              _conf = JSON.parse(window.decodeURIComponent(window.atob(menu.ParentParam)))
            } catch (e) {
              console.warn('Parse Failure')
              _conf = ''
            }
          }
          if (_conf) {
            _list.push({
              key: menu.MenuID,
              title: menu.MenuName,
              btnParam: _conf
            })
          }
        })
        this.setState({
          thawbtnlist: _list
        })
      } else {
        notification.warning({
          top: 92,
          message: res.message,
          duration: 5
        })
      }
    })
  }
  /**
   * @description 解冻按钮提交
   */
  thawBtnSubmit = () => {
    const { thawButtons } = this.props
    const { thawbtnlist } = this.state
    let config = JSON.parse(JSON.stringify(this.props.config))
    // 三级菜单解除冻结
    if (this.refs.trawmenu.state.targetKeys.length === 0) {
      notification.warning({
        top: 92,
        message: this.props.dict['form.required.select'] + this.props.dict['header.form.thawbutton'],
        duration: 5
      })
    } else {
      thawbtnlist.forEach(item => {
        if (this.refs.trawmenu.state.targetKeys.includes(item.key)) {
          config.action.push(item.btnParam)
        }
      })
      this.props.refresh({
        type: 'thaw',
        thawButtons: [...thawButtons, ...this.refs.trawmenu.state.targetKeys],
        config: config
      })
      this.setState({
        thawVisible: false
      })
    }
  }
  pasteSubmit = () => {
    const { config } = this.props
    this.pasteFormRef.handleConfirm().then(res => {
      if (res.copyType === 'action') {
        if (this.props.type === 'subtable' && !['pop', 'prompt', 'exec', 'excelIn', 'excelOut', 'popview'].includes(res.OpenType)) {
          notification.warning({
            top: 92,
            message: '不支持此打开方式!',
            duration: 5
          })
          return
        }
        this.setState({
          pasteVisible: false
        }, () => {
          this.props.refresh({
            type: 'paste',
            copyType: 'action',
            content: res
          })
        })
      } else if (res.copyType === 'columns') {
        if (config.columns && config.columns.length > 0) {
          notification.warning({
            top: 92,
            message: '显示列已存在!',
            duration: 5
          })
          return
        }
        this.setState({
          pasteVisible: false
        }, () => {
          this.props.refresh({
            type: 'paste',
            copyType: 'columns',
            config: {...config, columns: res.columns}
          })
        })
      } else {
        notification.warning({
          top: 92,
          message: '配置信息格式错误!',
          duration: 5
        })
      }
    })
  }
  render() {
    const menu = (
      <Menu onClick={this.handleMenuClick}>
        <Menu.Item key="thaw"><Icon type="unlock" />{this.props.dict['header.form.thawbutton']}</Menu.Item>
        <Menu.Item key="paste"><Icon type="snippets" />{this.props.dict['header.form.paste']}</Menu.Item>
        <Menu.Item key="replace"><Icon type="retweet" />替换</Menu.Item>
      </Menu>
    )
    return (
      <div style={{display: 'inline-block'}}>
        <Dropdown overlay={menu} overlayClassName="edit-component-box">
          <span style={{color: '#1890ff', display: 'inline-block', height: 25}}>
            编辑 <Icon type="down" />
          </span>
        </Dropdown>
        {/* 解冻按钮模态框 */}
        <Modal
          title={this.props.dict['header.form.thawbutton']}
          okText={this.props.dict['header.confirm']}
          cancelText={this.props.dict['header.cancel']}
          visible={this.state.thawVisible}
          onOk={this.thawBtnSubmit}
          onCancel={() => {this.setState({thawVisible: false, thawbtnlist: null})}}
          destroyOnClose
        >
          {!this.state.thawbtnlist && <Spin style={{marginLeft: 'calc(50% - 22px)', marginTop: '70px', marginBottom: '70px'}} size="large" />}
          {this.state.thawbtnlist && <TransferForm ref="trawmenu" menulist={this.state.thawbtnlist}/>}
        </Modal>
        {/* 按钮配置信息粘贴复制 */}
        <Modal
          title={this.props.dict['header.form.paste']}
          visible={this.state.pasteVisible}
          width={600}
          maskClosable={false}
          onOk={this.pasteSubmit}
          onCancel={() => {this.setState({pasteVisible: false})}}
          destroyOnClose
        >
          <PasteForm
            dict={this.props.dict}
            wrappedComponentRef={(inst) => this.pasteFormRef = inst}
          />
        </Modal>
      </div>
    )
  }
}
export default editComponent
src/templates/zshare/editcomponent/index.scss
New file
@@ -0,0 +1,5 @@
.edit-component-box {
  .ant-dropdown-menu-item {
    min-width: 120px;;
  }
}
src/templates/zshare/formconfig.jsx
@@ -600,6 +600,20 @@
        value: 'false',
        text: Formdict['header.form.false']
      }]
    },
    {
      type: 'radio',
      key: 'search',
      label: '搜索条件',
      initVal: card.search || 'false',
      required: false,
      options: [{
        value: 'true',
        text: '必填'
      }, {
        value: 'false',
        text: '非必填'
      }]
    }
  ]
}
src/templates/zshare/tabform/index.jsx
@@ -1,6 +1,6 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { Form, Row, Col, Input, Select, Icon, Tooltip } from 'antd'
import { Form, Row, Col, Input, Select, Icon, Tooltip, Radio } from 'antd'
import { formRule } from '@/utils/option.js'
import Utils from '@/utils/utils.js'
import './index.scss'
@@ -201,6 +201,37 @@
            </Form.Item>
          </Col>
        )
      } else if (item.type === 'radio') {
        fields.push(
          <Col span={12} key={index}>
            <Form.Item label={item.tooltip ?
              <Tooltip placement="topLeft" title={item.tooltip}>
                <Icon type="question-circle" />
                {item.label}
              </Tooltip> : item.label
            }>
              {getFieldDecorator(item.key, {
                initialValue: item.initVal,
                rules: [
                  {
                    required: !!item.required,
                    message: this.props.dict['form.required.select'] + item.label + '!'
                  }
                ]
              })(
                <Radio.Group>
                  {
                    item.options.map(option => {
                      return (
                        <Radio key={option.value} value={option.value}>{option.text}</Radio>
                      )
                    })
                  }
                </Radio.Group>
              )}
            </Form.Item>
          </Col>
        )
      }
    })
src/utils/utils.js
@@ -58,19 +58,19 @@
  static verifySql (sql, type) {
    if (!sql) return ''
    let chars = [
      {key: 'create', reg: '(^|\\s)create\\s'},
      {key: 'insert', reg: '(^|\\s)insert\\s'},
      {key: 'delete', reg: '(^|\\s)delete\\s'},
      {key: 'update', reg: '(^|\\s)update\\s'},
      {key: 'set', reg: '(^|\\s)set\\s'},
      {key: 'drop', reg: '(^|\\s)drop\\s'},
      {key: 'alter', reg: '(^|\\s)alter\\s'},
      {key: 'truncate', reg: '(^|\\s)truncate\\s'},
      {key: 'if', reg: '(^|\\s)if\\s'},
      {key: 'exec', reg: 'exec'},
      {key: 'OBJECT', reg: 'OBJECT'},
      {key: 'sys.', reg: 'sys.'},
      {key: 'kill', reg: 'kill'},
      {key: 'create', reg: /(^|\s)create\s/ig},
      {key: 'insert', reg: /(^|\s)insert\s/ig},
      {key: 'delete', reg: /(^|\s)delete\s/ig},
      {key: 'update', reg: /(^|\s)update\s/ig},
      {key: 'set', reg: /(^|\s)set\s/ig},
      {key: 'drop', reg: /(^|\s)drop\s/ig},
      {key: 'alter', reg: /(^|\s)alter\s/ig},
      {key: 'truncate', reg: /(^|\s)truncate\s/ig},
      {key: 'if', reg: /(^|\s)if\s/ig},
      {key: 'exec', reg: /exec/ig},
      {key: 'OBJECT', reg: /object/ig},
      {key: 'sys.', reg: /sys\./ig},
      {key: 'kill', reg: /kill/ig}
    ]
    if (type === 'customscript') {
@@ -79,7 +79,7 @@
    let error = ''
    chars.forEach(char => {
      if (!error && new RegExp(char.reg, 'ig').test(sql)) {
      if (!error && char.reg.test(sql)) {
        error = char.key
      }
    })