king
2020-05-22 523cec6c87d88b43954a4409a8dfde6aade095a1
src/tabviews/zshare/actionList/index.jsx
@@ -192,7 +192,8 @@
        })
      }
    } else if (item.OpenType === 'popview' && this.props.type !== 'subtab') {
      this.props.triggerPopview(item, data)
      // 弹窗标签设置为不选则行时,不传递数据
      this.props.triggerPopview(item, item.Ot === 'notRequired' ? [] : data)
    } else if (item.OpenType === 'popview' && this.props.type === 'subtab') {
      notification.warning({
        top: 92,
@@ -447,8 +448,10 @@
    let _list = []
    return new Promise(resolve => {
      let params = []
      let param = {
        BID: this.props.BID
      let param = {}
      if (this.props.BID) {
        param.BID = this.props.BID
      }
      if (btn.Ot === 'notRequired') {
@@ -545,7 +548,7 @@
            // 使用处理后的数据调用外部接口
            let keys = Object.keys(res) // 提交外部接口前,添加BID
            if (keys.filter(key => key.toLowerCase() === 'bid').length === 0) {
            if (this.props.BID && keys.filter(key => key.toLowerCase() === 'bid').length === 0) {
              res.BID = this.props.BID
            }
            
@@ -1027,8 +1030,11 @@
    let _this = this
    let param = {
      BID: this.props.BID,
      func: 'webapi_ChangeUser'
    }
    if (this.props.BID) {
      param.BID = this.props.BID
    }
    if (window.GLOB.mainSystemApi) {
@@ -1114,8 +1120,11 @@
        }
        let param = { // 系统存储过程
          func: 'sPC_TableData_InUpDe',
          BID: this.props.BID
          func: 'sPC_TableData_InUpDe'
        }
        if (this.props.BID) {
          param.BID = this.props.BID
        }
        
        let primaryId = ''
@@ -1191,9 +1200,13 @@
        let _params = data.map((cell, index) => {
          let param = {
            func: 'sPC_TableData_InUpDe',
            BID: this.props.BID
            func: 'sPC_TableData_InUpDe'
          }
          if (this.props.BID) {
            param.BID = this.props.BID
          }
          let primaryId = setting.primaryKey ? cell[setting.primaryKey] : ''
          if (btn.OpenType === 'prompt' || btn.OpenType === 'exec') { // 是否弹框或直接执行
@@ -1210,15 +1223,20 @@
              param.secretkey = Utils.encrypt(param.LText, param.timestamp)
            }
          } else if (btn.OpenType === 'pop') { // 表单
            if (index !== 0) {
              formdata = formdata.map(_data => {
                if (_data.readin && cell.hasOwnProperty(_data.key)) {
                  _data.value = cell[_data.key]
                }
                return _data
              })
            }
            if (btn.innerFunc) {
              param.func = btn.innerFunc
              formdata.forEach(_data => {
                if (index !== 0 && _data.readin && cell.hasOwnProperty(_data.key)) {
                  param[_data.key] = cell[_data.key]
                } else {
                  param[_data.key] = _data.value
                }
                param[_data.key] = _data.value
              })
              if (setting.primaryKey) {
@@ -1230,15 +1248,6 @@
              param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000'
              param.secretkey = Utils.encrypt(param.LText, param.timestamp)
            } else if (btn.sql) {
              if (index !== 0) {
                formdata = formdata.map(_data => {
                  if (_data.readin && cell.hasOwnProperty(_data.key)) {
                    _data.value = cell[_data.key]
                  }
                  return _data
                })
              }
              param.ID = primaryId
              param.LText = Utils.formatOptions(Utils.getSysDefaultSql(btn, setting, formdata, param, cell, logcolumns, this.props.Tab)) // 数据源
              param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') + '.000'
@@ -1294,8 +1303,10 @@
      let _params = [] // 请求参数数组
      if (btn.Ot === 'notRequired' || btn.Ot === 'requiredSgl' || btn.Ot === 'requiredOnce') {
        let param = {
          BID: this.props.BID
        let param = {}
        if (this.props.BID) {
          param.BID = this.props.BID
        }
        if (btn.OpenType === 'pop' && formdata) { // 表单
@@ -1318,8 +1329,10 @@
      } else if (btn.Ot === 'required') {
        // 选择多行,循环调用
        _params = data.map((cell, index) => {
          let _cell = {
            BID: this.props.BID,
          let _cell = {}
          if (this.props.BID) {
            _cell.BID = this.props.BID
          }
          let _formparam = {}
@@ -1413,7 +1426,7 @@
            // 使用处理后的数据调用外部接口
            let keys = Object.keys(res) // 提交外部接口前,添加BID
            if (keys.filter(key => key.toLowerCase() === 'bid').length === 0) {
            if (this.props.BID && keys.filter(key => key.toLowerCase() === 'bid').length === 0) {
              res.BID = this.props.BID
            }
            
@@ -1848,8 +1861,11 @@
    }
    let param = {
      BID: this.props.BID,
      ID: primaryId
    }
    if (this.props.BID) {
      param.BID = this.props.BID
    }
    param.LText = Utils.formatOptions(result.sql)
@@ -1895,7 +1911,7 @@
              // 使用处理后的数据调用外部接口
              let keys = Object.keys(res) // 提交外部接口前,添加BID
              if (keys.filter(key => key.toLowerCase() === 'bid').length === 0) {
              if (this.props.BID && keys.filter(key => key.toLowerCase() === 'bid').length === 0) {
                res.BID = this.props.BID
              }
              resolve(res)