king
2021-08-02 27a03ffac131c044ac347b6236856bff2ee1e51f
2021-08-02
8个文件已修改
94 ■■■■■ 已修改文件
src/tabviews/commontable/index.jsx 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/card/data-card/index.jsx 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/components/table/normal-table/index.jsx 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/custom/index.jsx 18 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/subtable/index.jsx 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/subtabtable/index.jsx 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/treepage/index.jsx 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/utils/utils-datamanage.js 20 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/tabviews/commontable/index.jsx
@@ -90,6 +90,7 @@
        config.MenuID = this.props.MenuID
        config.MenuName = MenuName
        config.setting.MenuName = MenuName
        config.setting.$name = MenuName
      } catch (e) {
        console.warn('Parse Failure')
        config = ''
@@ -665,10 +666,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getQueryDataParams(setting, arr_field, search, _orderBy, pageIndex, pageSize, BID, this.props.menuType)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = this.props.MenuName || ''
    }
    let result = await Api.genericInterface(param)
    this.getStatFieldsValue()
@@ -725,10 +722,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getQueryDataParams(setting, arr_field, search, _orderBy, pageIndex, pageSize, BID, this.props.menuType, id)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = this.props.MenuName || ''
    }
    let result = await Api.genericInterface(param)
    if (result.status) {
@@ -796,10 +789,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getStatQueryDataParams(setting, statFields, search, _orderBy, BID, this.props.menuType)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = this.props.MenuName || ''
    }
    Api.genericInterface(param).then(res => {
      if (res.status) {
src/tabviews/custom/components/card/data-card/index.jsx
@@ -382,10 +382,6 @@
    let _orderBy = config.setting.order || ''
    let param = UtilsDM.getQueryDataParams(config.setting, arr_field, searches, _orderBy, pageIndex, config.setting.pageSize, BID, menuType, id)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = config.name || ''
    }
    let result = await Api.genericInterface(param)
    if (result.status) {
      let data = fromJS(this.state.data).toJS()
src/tabviews/custom/components/table/normal-table/index.jsx
@@ -173,10 +173,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getQueryDataParams(setting, arr_field, searches, _orderBy, pageIndex, pageSize, BID, this.props.menuType)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = config.name || ''
    }
    let result = await Api.genericInterface(param)
    if (result.status) {
      MKEmitter.emit('resetSelectLine', config.uuid, '', '') // 广播数据切换
@@ -234,10 +230,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getQueryDataParams(setting, arr_field, searches, _orderBy, pageIndex, pageSize, BID, this.props.menuType, id)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = config.name || ''
    }
    let result = await Api.genericInterface(param)
    if (result.status) {
@@ -317,10 +309,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getStatQueryDataParams(setting, config.statFields, searches, _orderBy, BID, this.props.menuType)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = config.name || ''
    }
    Api.genericInterface(param).then(res => {
      if (res.status) {
src/tabviews/custom/index.jsx
@@ -281,6 +281,8 @@
        return
      }
      item.MenuName = config.MenuName || ''
      inters.push(item)
    })
    
@@ -447,6 +449,8 @@
        delete item.style.shadowColor
      }
      item.$menuname = this.props.MenuName + '-' + (item.name || '')
      if (item.type === 'tabs') {
        if (
          item.setting.blacklist && item.setting.blacklist.length > 0 &&
@@ -556,7 +560,7 @@
      let tabId = this.props.Tab ? this.props.Tab.uuid : '' // 弹窗标签按钮Id
      if (item.action && item.action.length > 0) {
        item.action = item.action.filter(cell => {
          cell.logLabel = item.name + '-' + cell.label
          cell.logLabel = item.$menuname + '-' + cell.label
          cell.ContainerId = this.state.ContainerId
          cell.syncComponentId = cell.syncComponent ? (cell.syncComponent.pop() || '') : ''
          cell.$menuId = item.uuid
@@ -589,7 +593,7 @@
          card.elements = card.elements.filter(cell => {
            if (cell.eleType === 'button') {
              cell.logLabel = item.name + '-' + cell.label
              cell.logLabel = item.$menuname + '-' + cell.label
              cell.Ot = 'requiredSgl'
              cell.ContainerId = this.state.ContainerId
              cell.syncComponentId = cell.syncComponent ? (cell.syncComponent.pop() || '') : ''
@@ -612,7 +616,7 @@
          })
          card.backElements = card.backElements.filter(cell => {
            if (cell.eleType === 'button') {
              cell.logLabel = item.name + '-' + cell.label
              cell.logLabel = item.$menuname + '-' + cell.label
              cell.Ot = 'requiredSgl'
              cell.ContainerId = this.state.ContainerId
              cell.syncComponentId = cell.syncComponent ? (cell.syncComponent.pop() || '') : ''
@@ -636,7 +640,7 @@
      } else if (item.type === 'balcony') {
        item.elements = item.elements.filter(cell => {
          if (cell.eleType === 'button') {
            cell.logLabel = item.name + '-' + cell.label
            cell.logLabel = item.$menuname + '-' + cell.label
            cell.ContainerId = this.state.ContainerId
            cell.syncComponentId = cell.syncComponent ? (cell.syncComponent.pop() || '') : ''
            cell.$menuId = item.uuid
@@ -657,7 +661,7 @@
          let _hasheight = card.style.height && card.style.height !== 'auto'
          card.elements = card.elements.filter(cell => {
            if (cell.eleType === 'button') {
              cell.logLabel = item.name + '-' + cell.label
              cell.logLabel = item.$menuname + '-' + cell.label
              cell.Ot = 'requiredSgl'
              cell.ContainerId = this.state.ContainerId
              cell.syncComponentId = cell.syncComponent ? (cell.syncComponent.pop() || '') : ''
@@ -683,7 +687,7 @@
        item.cols = item.cols.filter(col => {
          if (col.type !== 'action') return true
          col.elements = col.elements.filter(cell => {
            cell.logLabel = item.name + '-' + cell.label
            cell.logLabel = item.$menuname + '-' + cell.label
            cell.Ot = 'requiredSgl'
            cell.ContainerId = this.state.ContainerId
            cell.syncComponentId = cell.syncComponent ? (cell.syncComponent.pop() || '') : ''
@@ -787,7 +791,7 @@
        }
      })
      delete component.scripts
      component.setting.$name = component.name || ''
      component.setting.$name = component.$menuname || ''
      component.setting.execute = component.setting.execute !== 'false'  // 默认sql是否执行,转为boolean 统一格式
      component.setting.laypage = component.setting.laypage === 'true'   // 是否分页,转为boolean 统一格式
src/tabviews/subtable/index.jsx
@@ -102,6 +102,7 @@
      try { // 配置信息解析
        config = JSON.parse(window.decodeURIComponent(window.atob(result.LongParam)))
        config.setting.MenuName = Tab.label
        config.setting.$name = Tab.label
      } catch (e) {
        console.warn('Parse Failure')
        config = ''
@@ -595,10 +596,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getQueryDataParams(setting, arr_field, searches, _orderBy, pageIndex, pageSize, BID, this.props.menuType)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = this.props.Tab.label || ''
    }
    let result = await Api.genericInterface(param)
    this.getStatFieldsValue(searches)
@@ -662,10 +659,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getQueryDataParams(setting, arr_field, searches, _orderBy, pageIndex, pageSize, BID, this.props.menuType, id)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = this.props.Tab.label || ''
    }
    let result = await Api.genericInterface(param)
    if (result.status) {
@@ -736,10 +729,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getStatQueryDataParams(setting, statFields, searches, _orderBy, BID, this.props.menuType)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = this.props.Tab.label || ''
    }
    Api.genericInterface(param).then(res => {
      if (res.status) {
        let _data = res.data[0]
src/tabviews/subtabtable/index.jsx
@@ -79,6 +79,7 @@
      try { // 配置信息解析
        config = JSON.parse(window.decodeURIComponent(window.atob(result.LongParam)))
        config.setting.MenuName = Tab.label
        config.setting.$name = Tab.label
      } catch (e) {
        console.warn('Parse Failure')
        config = ''
@@ -557,10 +558,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getQueryDataParams(setting, arr_field, searches, _orderBy, pageIndex, pageSize, BID, this.props.menuType)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = this.props.Tab.label || ''
    }
    let result = await Api.genericInterface(param)
    this.getStatFieldsValue(searches)
@@ -615,10 +612,6 @@
    let _orderBy = orderBy || setting.order
    let param = UtilsDM.getStatQueryDataParams(setting, statFields, searches, _orderBy, BID, this.props.menuType)
    if (param.func === 'sPC_Get_TableData') {
      param.menuname = this.props.Tab.label || ''
    }
    Api.genericInterface(param).then(res => {
      if (res.status) {
        let _data = res.data[0]
src/tabviews/treepage/index.jsx
@@ -56,7 +56,7 @@
   * @description 获取页面配置信息
   */
  async loadconfig () {
    const { permAction, param } = this.props
    const { permAction, param, MenuName } = this.props
    let _param = {
      func: 'sPC_Get_LongParam',
@@ -71,7 +71,8 @@
      try { // 配置信息解析
        config = JSON.parse(window.decodeURIComponent(window.atob(result.LongParam)))
        config.MenuID = this.props.MenuID
        config.MenuName = this.props.MenuName
        config.MenuName = MenuName
        config.setting.$name = MenuName
      } catch (e) {
        console.warn('Parse Failure')
        config = ''
src/utils/utils-datamanage.js
@@ -189,8 +189,12 @@
    // 测试系统打印查询语句
    if ((options.sysType === 'local' && !window.GLOB.systemType) || window.debugger === true) {
      _customScript &&  console.info(`${setting.$name ? `/*组件-${setting.$name} 自定义脚本*/\n` : ''}${LText ? '' : '/*不执行默认sql*/\n'}${_customScript}`)
      LText &&  console.info(`${setting.$name ? `/*组件-${setting.$name} 数据源*/\n` : ''}` + LText)
      _customScript &&  console.info(`${setting.$name ? `/*${setting.$name} 自定义脚本*/\n` : ''}${LText ? '' : '/*不执行默认sql*/\n'}${_customScript}`)
      LText &&  console.info(`${setting.$name ? `/*${setting.$name} 数据源*/\n` : ''}` + LText)
    }
    if (setting.$name) {
      param.menuname = setting.$name
    }
    param.custom_script = Utils.formatOptions(_customScript)
@@ -298,8 +302,12 @@
    // 测试系统打印查询语句
    if ((options.sysType === 'local' && !window.GLOB.systemType) || window.debugger === true) {
      _customScript &&  console.info(`${setting.$name ? `/*组件-${setting.$name} 自定义脚本 统计查询*/\n` : ''}${LText ? '' : '/*不执行默认sql*/\n'}${_customScript}`)
      LText &&  console.info(`${setting.$name ? `/*组件-${setting.$name} 数据源 统计查询*/\n` : ''}` + LText)
      _customScript &&  console.info(`${setting.$name ? `/*${setting.$name} 自定义脚本 统计查询*/\n` : ''}${LText ? '' : '/*不执行默认sql*/\n'}${_customScript}`)
      LText &&  console.info(`${setting.$name ? `/*${setting.$name} 数据源 统计查询*/\n` : ''}` + LText)
    }
    if (setting.$name) {
      param.menuname = setting.$name
    }
    
    param.custom_script = Utils.formatOptions(_customScript)
@@ -626,8 +634,8 @@
  // 测试系统打印查询语句
  if ((options.sysType === 'local' && !window.GLOB.systemType) || window.debugger === true) {
    _customScript &&  console.info(`${setting.$name ? `/*组件-${setting.$name} 自定义脚本*/\n` : ''}${_dataresource ? '' : '/*不执行默认sql*/\n'}${_customScript}`)
    _dataresource &&  console.info(`${setting.$name ? `/*组件-${setting.$name} 数据源*/\n` : ''}` + _dataresource)
    _customScript &&  console.info(`${setting.$name ? `/*${setting.$name} 自定义脚本*/\n` : ''}${_dataresource ? '' : '/*不执行默认sql*/\n'}${_customScript}`)
    _dataresource &&  console.info(`${setting.$name ? `/*${setting.$name} 数据源*/\n` : ''}` + _dataresource)
  }
  return {