king
2022-10-28 aa41be24e83653077d85860cb70882551912af24
2022-10-28
42个文件已修改
2个文件已添加
451 ■■■■ 已修改文件
src/menu/components/card/balcony/options.jsx 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/card/data-card/options.jsx 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/form/simple-form/options.jsx 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/form/step-form/options.jsx 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/module/voucher/options.jsx 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/tabs/antv-tabs/options.jsx 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/datasource/verifycard/index.jsx 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/datasource/verifycard/settingform/index.jsx 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/modalconfig/index.jsx 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/versions/index.jsx 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/mob/components/tabs/antv-tabs/options.jsx 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/calendar/index.jsx 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/commontable/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/card/balcony/index.jsx 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/card/data-card/index.jsx 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/card/prop-card/index.jsx 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/card/table-card/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/carousel/data-card/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/carousel/prop-card/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/chart/antv-bar-line/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/chart/antv-dashboard/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/chart/antv-pie/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/chart/antv-scatter/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/form/simple-form/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/form/step-form/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/form/tab-form/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/interfaces/interItem/index.jsx 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/table/base-table/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/table/edit-table/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/table/normal-table/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/timeline/normal-timeline/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/tree/antd-tree/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/subtable/index.jsx 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/subtabtable/index.jsx 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/treepage/index.jsx 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/comtableconfig/index.jsx 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/comtableconfig/updatetable/index.jsx 56 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/comtableconfig/updatetable/index.scss 30 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/modalconfig/index.jsx 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/sharecomponent/settingcomponent/settingform/index.jsx 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/zshare/codemirror/index.jsx 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/templates/zshare/verifycard/index.jsx 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/utils-custom.js 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/tabledesign/menuform/index.jsx 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/menu/components/card/balcony/options.jsx
@@ -1,15 +1,14 @@
import React from 'react'
import { fromJS } from 'immutable'
import MenuUtils from '@/utils/utils-custom.js'
/**
 * @description Wrap表单配置信息
 */
export default function (wrap) {
  let menu = fromJS(window.GLOB.customMenu).toJS()
  let menu = window.GLOB.customMenu
  let modules = MenuUtils.getLinkModules(menu.components) || []
  let supmodules = MenuUtils.getSupModules(menu.components, '')
  let supmodules = MenuUtils.getSupModules(menu.components, '', menu.interfaces)
  let roleList = sessionStorage.getItem('sysRoles')
  let appType = sessionStorage.getItem('appType')
src/menu/components/card/data-card/options.jsx
@@ -1,4 +1,3 @@
import { fromJS } from 'immutable'
import MenuUtils from '@/utils/utils-custom.js'
/**
@@ -7,7 +6,7 @@
export default function (wrap, subtype, columns = [], id = '', supNodes = [], setting) {
  let appType = sessionStorage.getItem('appType')
  let MenuType = ''
  let menu = fromJS(window.GLOB.customMenu).toJS()
  let menu = window.GLOB.customMenu
  let laypage = setting && setting.laypage !== 'false'
  let interfaces = []
  if (subtype === 'propcard' && menu.interfaces) {
@@ -26,7 +25,7 @@
  }
  let modules = []
  if (subtype === 'propcard' || subtype === 'datacard') {
    modules = MenuUtils.getSupModules(menu.components, id)
    modules = MenuUtils.getSupModules(menu.components, id, menu.interfaces)
  }
  let roleList = sessionStorage.getItem('sysRoles')
src/menu/components/form/simple-form/options.jsx
@@ -1,4 +1,3 @@
import { fromJS } from 'immutable'
import MenuUtils from '@/utils/utils-custom.js'
/**
@@ -36,8 +35,8 @@
  }
  let modules = []
  let menu = fromJS(window.GLOB.customMenu).toJS()
  modules = MenuUtils.getSupModules(menu.components, config.uuid)
  let menu = window.GLOB.customMenu
  modules = MenuUtils.getSupModules(menu.components, config.uuid, menu.interfaces)
  const wrapForm = [
    {
src/menu/components/form/step-form/options.jsx
@@ -1,4 +1,3 @@
import { fromJS } from 'immutable'
import MenuUtils from '@/utils/utils-custom.js'
/**
@@ -20,8 +19,8 @@
  }
  let modules = []
  let menu = fromJS(window.GLOB.customMenu).toJS()
  modules = MenuUtils.getSupModules(menu.components, config.uuid)
  let menu = window.GLOB.customMenu
  modules = MenuUtils.getSupModules(menu.components, config.uuid, menu.interfaces)
  const wrapForm = [
    {
src/menu/components/module/voucher/options.jsx
@@ -1,4 +1,3 @@
import { fromJS } from 'immutable'
import MenuUtils from '@/utils/utils-custom.js'
/**
@@ -8,8 +7,8 @@
  let roleList = sessionStorage.getItem('sysRoles')
  let appType = sessionStorage.getItem('appType')
  let menu = fromJS(window.GLOB.customMenu).toJS()
  let modules = MenuUtils.getSupModules(menu.components, id)
  let menu = window.GLOB.customMenu
  let modules = MenuUtils.getSupModules(menu.components, id, menu.interfaces)
  if (roleList) {
    try {
src/menu/components/tabs/antv-tabs/options.jsx
@@ -89,7 +89,7 @@
  let appType = sessionStorage.getItem('appType')
  let roleList = sessionStorage.getItem('sysRoles')
  let modules = MenuUtils.getSupModules(window.GLOB.customMenu.components, uuid)
  let modules = MenuUtils.getSupModules(window.GLOB.customMenu.components, uuid, window.GLOB.customMenu.interfaces)
  modules.push({
    value: 'preview',
    label: '上一页(url参数)'
src/menu/datasource/verifycard/index.jsx
@@ -912,6 +912,23 @@
              title = title && title[0] ? title[0] : ''
              let _text = title ? item.sql.replace(title, '') : item.sql
              if (item.status === 'false') {
                return (
                  <div className="script-item" key={item.uuid}>
                    <div style={{cursor: 'not-allowed'}}>
                      {title ? <div style={{color: '#a50', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis'}}>{title}</div> : null}
                      <Paragraph copyable={{ text: item.sql }} ellipsis={{ rows: 4 }}>{_text}</Paragraph>
                      <div>
                        <span style={{color: '#ff4d4f', marginLeft: '20px'}}>
                          禁用
                          <StopOutlined style={{marginLeft: '5px'}} />
                        </span>
                      </div>
                    </div>
                    <div style={{height: '24px'}}></div>
                  </div>
                )
              } else {
              return (
                <div className={'script-item ' + (script && script.uuid === item.uuid ? 'active' : '') } key={item.uuid}>
                  <div style={{cursor: 'pointer'}} onClick={() => {
@@ -919,15 +936,11 @@
                  }}>
                    {title ? <div style={{color: '#a50', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis'}}>{title}</div> : null}
                    <Paragraph copyable={{ text: item.sql }} ellipsis={{ rows: 4 }}>{_text}</Paragraph>
                    <div>{item.status === 'false' ?
                      <span style={{color: '#ff4d4f', marginLeft: '20px'}}>
                        禁用
                        <StopOutlined style={{marginLeft: '5px'}} />
                      </span> :
                      <div>
                      <span style={{color: '#26C281', marginLeft: '20px'}}>
                        启用
                        <CheckCircleOutlined style={{marginLeft: '5px'}}/>
                      </span>}
                        </span>
                    </div>
                  </div>
                  <div style={{textAlign: 'right'}}>
@@ -942,6 +955,7 @@
                  </div>
                </div>
              )
              }
            })}
          </div>
          <div className="script-button">
src/menu/datasource/verifycard/settingform/index.jsx
@@ -32,7 +32,7 @@
  UNSAFE_componentWillMount () {
    const { config, setting } = this.props
    let modules = MenuUtils.getSupModules(window.GLOB.customMenu.components, config.uuid)
    let modules = MenuUtils.getSupModules(window.GLOB.customMenu.components, config.uuid, window.GLOB.customMenu.interfaces)
    let ismain = false
    if (window.GLOB.customMenu.Template === 'BaseTable') {
src/menu/modalconfig/index.jsx
@@ -200,6 +200,9 @@
    if (!card.span && standardform && standardform.span) {
      card.span = standardform.span
      card.labelwidth = standardform.labelwidth
    } else if (!card.span) {
      card.span = 12
      card.labelwidth = 33.3
    }
    this.setState({
src/menu/versions/index.jsx
@@ -6,7 +6,6 @@
import moment from 'moment'
import Api from '@/api'
// import options from '@/store/options.js'
import Utils from '@/utils/utils.js'
import './index.scss'
src/mob/components/tabs/antv-tabs/options.jsx
@@ -86,7 +86,7 @@
 * @description tabs表单配置信息
 */
export function getTabsSetForm(setting, uuid) {
  let modules = MenuUtils.getSupModules(window.GLOB.customMenu.components, uuid)
  let modules = MenuUtils.getSupModules(window.GLOB.customMenu.components, uuid, window.GLOB.customMenu.interfaces)
  modules.push({
    value: 'preview',
    label: '上一页(url参数)'
src/tabviews/calendar/index.jsx
@@ -269,6 +269,11 @@
      this.setState({
        loading: false
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -276,6 +281,7 @@
      })
    }
  }
  }
  /**
   * @description 获取用户自定义存储过程传参
src/tabviews/commontable/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { notification, Spin, Tabs, Switch, Row, Col } from 'antd'
import { notification, Spin, Tabs, Switch, Row, Col, Modal } from 'antd'
import Api from '@/api'
import zhCN from '@/locales/zh-CN/main.js'
@@ -791,6 +791,12 @@
      if (autoMatic) {
        MKEmitter.emit('autoMaticError', this.props.MenuID)
      }
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -798,6 +804,7 @@
      })
    }
  }
  }
  /**
   * @description 获取单行数据
src/tabviews/custom/components/card/balcony/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, notification, Checkbox } from 'antd'
import { Spin, notification, Checkbox, Modal } from 'antd'
import Api from '@/api'
import UtilsDM from '@/utils/utils-datamanage.js'
@@ -347,6 +347,11 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -354,6 +359,7 @@
      })
    }
  }
  }
  checkAll = (e) => {
    const { syncConfig } = this.state
src/tabviews/custom/components/card/data-card/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, Empty, notification, message, Row, Col, Pagination } from 'antd'
import { Spin, Empty, notification, message, Row, Col, Pagination, Modal } from 'antd'
import { DownOutlined } from '@ant-design/icons'
import Api from '@/api'
@@ -604,6 +604,11 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -611,6 +616,7 @@
      })
    }
  }
  }
  /**
   * @description 获取单行数据
src/tabviews/custom/components/card/prop-card/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, notification, Col, Row } from 'antd'
import { Spin, notification, Col, Row, Modal } from 'antd'
import Api from '@/api'
import UtilsDM from '@/utils/utils-datamanage.js'
@@ -397,6 +397,11 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -404,6 +409,7 @@
      })
    }
  }
  }
  changeCard = (index, item) => {
    const { config, data, activeKey } = this.state
src/tabviews/custom/components/card/table-card/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, notification, Row, Col, Empty, Pagination } from 'antd'
import { Spin, notification, Row, Col, Empty, Pagination, Modal } from 'antd'
import { DownOutlined } from '@ant-design/icons'
import Api from '@/api'
@@ -330,6 +330,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -337,6 +343,7 @@
      })
    }
  }
  }
  changePageIndex = (page) => {
    this.setState({
src/tabviews/custom/components/carousel/data-card/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, Empty, notification, Carousel } from 'antd'
import { Spin, Empty, notification, Carousel, Modal } from 'antd'
import Api from '@/api'
import UtilsDM from '@/utils/utils-datamanage.js'
@@ -259,6 +259,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -266,6 +272,7 @@
      })
    }
  }
  }
  render() {
    const { config, loading, data, card } = this.state
src/tabviews/custom/components/carousel/prop-card/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, notification, Carousel } from 'antd'
import { Spin, notification, Carousel, Modal } from 'antd'
import asyncComponent from '@/utils/asyncComponent'
import Api from '@/api'
@@ -277,6 +277,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -284,6 +290,7 @@
      })
    }
  }
  }
  render() {
    const { config, loading, data } = this.state
src/tabviews/custom/components/chart/antv-bar-line/index.jsx
@@ -3,7 +3,7 @@
import { is, fromJS } from 'immutable'
import { Chart } from '@antv/g2'
import DataSet from '@antv/data-set'
import { Spin, Empty, notification } from 'antd'
import { Spin, Empty, notification, Modal } from 'antd'
import { DownloadOutlined } from '@ant-design/icons'
import moment from 'moment'
@@ -534,6 +534,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -541,6 +547,7 @@
      })
    }
  }
  }
  /**
   * @description 数据预处理,统计数据需要重置
src/tabviews/custom/components/chart/antv-dashboard/index.jsx
@@ -2,7 +2,7 @@
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Chart, registerShape } from '@antv/g2'
import { Spin, notification } from 'antd'
import { Spin, notification, Modal } from 'antd'
import { DownloadOutlined } from '@ant-design/icons'
import moment from 'moment'
@@ -278,6 +278,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -285,6 +291,7 @@
      })
    }
  }
  }
  viewrender = () => {
    const { config } = this.state
src/tabviews/custom/components/chart/antv-pie/index.jsx
@@ -3,7 +3,7 @@
import { is, fromJS } from 'immutable'
import { Chart } from '@antv/g2'
import DataSet, { DataView } from '@antv/data-set'
import { Spin, Empty, notification } from 'antd'
import { Spin, Empty, notification, Modal } from 'antd'
import { DownloadOutlined } from '@ant-design/icons'
import moment from 'moment'
@@ -239,6 +239,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -246,6 +252,7 @@
      })
    }
  }
  }
  /**
   * @description 图表数据预处理
src/tabviews/custom/components/chart/antv-scatter/index.jsx
@@ -2,7 +2,7 @@
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Chart } from '@antv/g2'
import { Spin, Empty, notification } from 'antd'
import { Spin, Empty, notification, Modal } from 'antd'
import { DownloadOutlined } from '@ant-design/icons'
import moment from 'moment'
@@ -273,6 +273,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -280,6 +286,7 @@
      })
    }
  }
  }
  /**
   * @description 数据预处理,统计数据需要重置
src/tabviews/custom/components/form/simple-form/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, notification } from 'antd'
import { Spin, notification, Modal } from 'antd'
import Api from '@/api'
import UtilsDM from '@/utils/utils-datamanage.js'
@@ -258,6 +258,12 @@
      this.setState({
        loading: false,
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -265,6 +271,7 @@
      })
    }
  }
  }
  mkFormSubmit = (btnId) => {
    const { group } = this.state
src/tabviews/custom/components/form/step-form/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, notification, Button } from 'antd'
import { Spin, notification, Button, Modal } from 'antd'
import Api from '@/api'
import UtilsDM from '@/utils/utils-datamanage.js'
@@ -326,6 +326,12 @@
      this.setState({
        loading: false,
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -333,6 +339,7 @@
      })
    }
  }
  }
  mkFormSubmit = (btnId) => {
    const { group } = this.state
src/tabviews/custom/components/form/tab-form/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, notification } from 'antd'
import { Spin, notification, Modal } from 'antd'
import Api from '@/api'
import UtilsDM from '@/utils/utils-datamanage.js'
@@ -268,6 +268,12 @@
      this.setState({
        loading: false,
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -275,6 +281,7 @@
      })
    }
  }
  }
  mkFormSubmit = (btnId) => {
    const { group } = this.state
src/tabviews/custom/components/interfaces/interItem/index.jsx
@@ -1,6 +1,6 @@
import {Component} from 'react'
import PropTypes from 'prop-types'
import { notification } from 'antd'
import { notification, Modal } from 'antd'
import Api from '@/api'
import UtilsDM from '@/utils/utils-datamanage.js'
@@ -64,10 +64,11 @@
    let result = await Api.genericInterface(param)
    if (result.status) {
      this.loading = false
      let _data = { $$empty: true }
      let _data = { $$empty: true, $$uuid: '' }
      if (result.data && result.data[0]) {
        _data = result.data[0]
        _data.$$uuid = _data[config.setting.primaryKey] || ''
      }
      
      _data.$$loaded = true
@@ -75,9 +76,16 @@
      window.GLOB.CacheData.set(config.uuid, _data)
      MKEmitter.emit('mkPublicData', config.uuid, _data)
      MKEmitter.emit('resetSelectLine', config.uuid, _data.$$uuid, _data)
    } else {
      this.loading = false
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -85,6 +93,7 @@
      })
    }
  }
  }
  render() {return null}
}
src/tabviews/custom/components/table/base-table/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { notification } from 'antd'
import { notification, Modal } from 'antd'
import Api from '@/api'
import Utils from '@/utils/utils.js'
@@ -210,6 +210,12 @@
      this.setState({
        loading: false
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -217,6 +223,7 @@
      })
    }
  }
  }
  /**
   * @description 获取单行数据
src/tabviews/custom/components/table/edit-table/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { notification } from 'antd'
import { notification, Modal } from 'antd'
import Api from '@/api'
import Utils from '@/utils/utils.js'
@@ -252,6 +252,12 @@
      this.setState({
        loading: false
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -259,6 +265,7 @@
      })
    }
  }
  }
  /**
   * @description 获取单行数据
src/tabviews/custom/components/table/normal-table/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { notification, Collapse } from 'antd'
import { notification, Collapse, Modal } from 'antd'
import Api from '@/api'
import Utils from '@/utils/utils.js'
@@ -289,6 +289,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -296,6 +302,7 @@
      })
    }
  }
  }
  /**
   * @description 获取单行数据
src/tabviews/custom/components/timeline/normal-timeline/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, notification, Timeline, Empty } from 'antd'
import { Spin, notification, Timeline, Empty, Modal } from 'antd'
import Api from '@/api'
import MkIcon from '@/components/mk-icon'
@@ -296,6 +296,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -303,6 +309,7 @@
      })
    }
  }
  }
  getExpress = () => {
    const { BData } = this.state
src/tabviews/custom/components/tree/antd-tree/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { Spin, Empty, notification, Input, Tree } from 'antd'
import { Spin, Empty, notification, Input, Tree, Modal } from 'antd'
import { FolderOpenOutlined, FolderOutlined, FileOutlined } from '@ant-design/icons'
import Api from '@/api'
@@ -197,6 +197,12 @@
        loading: false
      })
      this.timer && this.timer.stop()
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -204,6 +210,7 @@
      })
    }
  }
  }
  handleData = () => {
    const { data, searchkey, config, selectedKeys, selected } = this.state
src/tabviews/subtable/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { notification, Spin, Switch, Row, Col, Tabs} from 'antd'
import { notification, Spin, Switch, Row, Col, Tabs, Modal } from 'antd'
import Api from '@/api'
import zhCN from '@/locales/zh-CN/main.js'
@@ -668,6 +668,11 @@
        loading: false
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: prex + result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: prex + result.message,
@@ -675,6 +680,7 @@
      })
    }
  }
  }
  /**
   * @description 获取单行数据
src/tabviews/subtabtable/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { notification, Spin} from 'antd'
import { notification, Spin, Modal } from 'antd'
import Api from '@/api'
import zhCN from '@/locales/zh-CN/main.js'
@@ -600,6 +600,11 @@
      this.setState({
        loading: false
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -607,6 +612,7 @@
      })
    }
  }
  }
  /**
   * @description 获取合计字段值
src/tabviews/treepage/index.jsx
@@ -1,7 +1,7 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
import { notification, Spin, Tabs, Tree, Row, Col, Card, Input, Empty } from 'antd'
import { notification, Spin, Tabs, Tree, Row, Col, Card, Input, Empty, Modal } from 'antd'
import { FolderOpenOutlined, FolderOutlined, FileOutlined } from '@ant-design/icons'
import Api from '@/api'
@@ -323,6 +323,11 @@
        treeNodes: [],
        treedata: []
      })
      if (result.ErrCode === 'N') {
        Modal.error({
          title: result.message,
        })
      } else {
      notification.error({
        top: 92,
        message: result.message,
@@ -330,6 +335,7 @@
      })
    }
  }
  }
  /**
   * @description 获取结构树信息
src/templates/comtableconfig/index.jsx
@@ -28,6 +28,7 @@
const Versions = asyncComponent(() => import('@/menu/versions'))
const UrlFieldComponent = asyncComponent(() => import('@/menu/urlfieldcomponent'))
const ReplaceField = asyncComponent(() => import('@/menu/replaceField'))
// const UpdateTable = asyncComponent(() => import('./updatetable'))
const Unattended = asyncComponent(() => import('@/templates/zshare/unattended'))
const EditComponent = asyncComponent(() => import('@/templates/zshare/editcomponent'))
const SettingComponent = asyncComponent(() => import('@/templates/sharecomponent/settingcomponent'))
@@ -1267,6 +1268,7 @@
                <Versions MenuId={menu.MenuID} open_edition={openEdition} updateConfig={this.refreshConfig}/>
                <ReplaceField type="table" config={config} updateConfig={this.updateconfig}/>
                <EditComponent type="table" options={['search', 'form', 'action', 'columns']} config={this.state.config} MenuID={this.props.menu.MenuID} thawButtons={this.state.thawButtons} refresh={this.editConfig}/>
                {/* <UpdateTable config={config}/> */}
                <Switch className="big" checkedChildren="启" unCheckedChildren="停" checked={this.state.config.enabled} onChange={this.onEnabledChange} />
                <Button type="primary" id="save-config" onClick={this.submitConfig} loading={this.state.menuloading}>保存</Button>
                <Button onClick={this.cancelConfig}>关闭</Button>
src/templates/comtableconfig/updatetable/index.jsx
New file
@@ -0,0 +1,56 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { is, fromJS } from 'immutable'
// import { Modal, Button, notification } from 'antd'
import { Modal, Button } from 'antd'
import { ArrowUpOutlined } from '@ant-design/icons'
// import moment from 'moment'
// import Api from '@/api'
// import Utils from '@/utils/utils.js'
import './index.scss'
const { confirm } = Modal
class UpdateTable extends Component {
  static propTpyes = {
    config: PropTypes.object
  }
  state = {}
  shouldComponentUpdate (nextProps, nextState) {
    return !is(fromJS(this.state), fromJS(nextState))
  }
  trigger = () => {
    const _this = this
    confirm({
      title: '确定升级当前菜单吗?',
      content: '',
      onOk() {
        return new Promise(resolve => {
          _this.execUpdate(resolve)
        })
      },
      onCancel() {}
    })
  }
  execUpdate = (_resolve) => {
    // const { config } = this.props
    setTimeout(() => {
      _resolve()
    }, 5000)
  }
  render() {
    return (
      <div style={{display: 'inline-block'}}>
        <Button className="mk-border-purple" onClick={this.trigger}><ArrowUpOutlined /> 升级</Button>
      </div>
    )
  }
}
export default UpdateTable
src/templates/comtableconfig/updatetable/index.scss
New file
@@ -0,0 +1,30 @@
.version-modal {
  .ant-modal-body {
    padding: 32px 32px 24px;
  }
  .ant-modal-footer {
    display: none;
  }
  .header {
    color: rgba(0, 0, 0, 0.85);
    font-weight: 500;
    font-size: 16px;
    .anticon {
      color: #faad14;
      margin-right: 16px;
      font-size: 22px;
    }
  }
  .detail {
    margin-top: 8px;
    margin-bottom: 24px;
    color: rgba(0, 0, 0, 0.5);
    font-size: 14px;
  }
  .footer {
    text-align: right;
    .ant-btn + .ant-btn {
      margin-left: 15px;
    }
  }
}
src/templates/modalconfig/index.jsx
@@ -357,6 +357,9 @@
    if (!card.span && standardform && standardform.span) {
      card.span = standardform.span
      card.labelwidth = standardform.labelwidth
    } else if (!card.span) {
      card.span = 12
      card.labelwidth = 33.3
    }
    this.setState({
src/templates/sharecomponent/settingcomponent/settingform/index.jsx
@@ -557,6 +557,23 @@
              title = title && title[0] ? title[0] : ''
              let _text = title ? item.sql.replace(title, '') : item.sql
              if (item.status === 'false') {
                return (
                  <div className="script-item" key={item.uuid}>
                    <div style={{cursor: 'not-allowed'}}>
                      {title ? <div style={{color: '#a50', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis'}}>{title}</div> : null}
                      <Paragraph copyable={{ text: item.sql }} ellipsis={{ rows: 4 }}>{_text}</Paragraph>
                      <div>
                        <span style={{color: '#ff4d4f', marginLeft: '20px'}}>
                          禁用
                          <StopOutlined style={{marginLeft: '5px'}} />
                        </span>
                      </div>
                    </div>
                    <div style={{height: '24px'}}></div>
                  </div>
                )
              } else {
              return (
                <div className={'script-item ' + (script && script.uuid === item.uuid ? 'active' : '') } key={item.uuid}>
                  <div style={{cursor: 'pointer'}} onClick={() => {
@@ -564,15 +581,11 @@
                  }}>
                    {title ? <div style={{color: '#a50', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis'}}>{title}</div> : null}
                    <Paragraph copyable={{ text: item.sql }} ellipsis={{ rows: 4 }}>{_text}</Paragraph>
                    <div>{item.status === 'false' ?
                      <span style={{color: '#ff4d4f', marginLeft: '20px'}}>
                        禁用
                        <StopOutlined style={{marginLeft: '5px'}} />
                      </span> :
                      <div>
                      <span style={{color: '#26C281', marginLeft: '20px'}}>
                        启用
                        <CheckCircleOutlined style={{marginLeft: '5px'}}/>
                      </span>}
                        </span>
                    </div>
                  </div>
                  <div style={{textAlign: 'right'}}>
@@ -587,6 +600,7 @@
                  </div>
                </div>
              )
              }
            })}
          </div>
          <div className="script-button">
src/templates/zshare/codemirror/index.jsx
@@ -111,6 +111,9 @@
    if (!_sql) return
    
    _sql = sqlFormatter.format(_sql.replace(/\s{2,}/g, ' '))
    // _sql = _sql.replace(/case\n\s+when\s/ig, (word) => {
    //   return word.replace(/case/, '').replace(/when/, 'case when')
    // })
    this.setState({display: false, editor: null, defaultVal: _sql}, () => {
      this.setState({display: true})
src/templates/zshare/verifycard/index.jsx
@@ -1763,6 +1763,23 @@
                position = <span style={{color: '#1890ff'}}>sql后</span>
              }
              if (item.status === 'false') {
                return (
                  <div className="script-item" key={item.uuid}>
                    <div style={{cursor: 'not-allowed'}}>
                      {title ? <div style={{color: '#a50', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis'}}>{title}</div> : null}
                      <Paragraph copyable={{ text: item.sql }} ellipsis={{ rows: 4 }}>{_text}</Paragraph>
                      <div>{position}
                        <span style={{color: '#ff4d4f', marginLeft: '20px'}}>
                          禁用
                          <StopOutlined style={{marginLeft: '5px'}} />
                        </span>
                      </div>
                    </div>
                    <div style={{height: '24px'}}></div>
                  </div>
                )
              } else {
              return (
                <div className={'script-item ' + (this.state.scriptId === item.uuid ? 'active' : '') } key={item.uuid}>
                  <div style={{cursor: 'pointer'}} onClick={() => {
@@ -1771,15 +1788,11 @@
                  }}>
                    {title ? <div style={{color: '#a50', whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis'}}>{title}</div> : null}
                    <Paragraph copyable={{ text: item.sql }} ellipsis={{ rows: 4 }}>{_text}</Paragraph>
                    <div>{position}{item.status === 'false' ?
                      <span style={{color: '#ff4d4f', marginLeft: '20px'}}>
                        禁用
                        <StopOutlined style={{marginLeft: '5px'}} />
                      </span> :
                      <div>{position}
                      <span style={{color: '#26C281', marginLeft: '20px'}}>
                        启用
                        <CheckCircleOutlined style={{marginLeft: '5px'}}/>
                      </span>}
                        </span>
                    </div>
                  </div>
                  <div style={{textAlign: 'right'}}>
@@ -1794,6 +1807,7 @@
                  </div>
                </div>
              )
              }
            })}
          </div>
          <CustomScript
src/utils/utils-custom.js
@@ -171,7 +171,7 @@
   * @description 获取上级模块
   * @return {String}  selfId  当前组件id
   */
  static getSupModules (components, selfId) {
  static getSupModules (components, selfId, interfaces) {
    let modules = []
    components.forEach(item => {
      if (item.uuid === selfId) {
@@ -264,6 +264,15 @@
      }
    })
    if (interfaces && interfaces.length > 0) {
      interfaces.forEach(item => {
        modules.push({
          value: item.uuid,
          label: item.name
        })
      })
    }
    return modules
  }
src/views/tabledesign/menuform/index.jsx
@@ -1,7 +1,6 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { Form, Row, Col, Input, Select, notification, Radio, Tooltip, Switch } from 'antd'
import { QuestionCircleOutlined } from '@ant-design/icons'
import { Form, Row, Col, Input, Select, notification, Radio, Switch } from 'antd'
import Api from '@/api'
import options from '@/store/options.js'
@@ -201,8 +200,6 @@
      this.props.updateConfig({...config, OpenType: value})
    } else if (key === 'hidden') {
      this.props.updateConfig({...config, hidden: value})
    } else if (key === 'permission') {
      this.props.updateConfig({...config, permission: value})
    }
  }
@@ -332,23 +329,6 @@
                <Radio.Group onChange={(e) => {this.selectChange('OpenType', e.target.value)}}>
                  <Radio value="newtab">标签页</Radio>
                  <Radio value="newpage">新页面</Radio>
                </Radio.Group>
              )}
            </Form.Item>
          </Col>
          <Col span={24}>
            <Form.Item label={
              <Tooltip placement="topLeft" title="跳过权限验证时,页面中组件及按钮不在进行权限控制。">
                <QuestionCircleOutlined className="mk-form-tip" />
                权限验证
              </Tooltip>
            }>
              {getFieldDecorator('permission', {
                initialValue: config.permission || 'true'
              })(
                <Radio.Group onChange={(e) => {this.selectChange('permission', e.target.value)}}>
                  <Radio value="true">使用</Radio>
                  <Radio value="false">不使用</Radio>
                </Radio.Group>
              )}
            </Form.Item>