| | |
| | | if (data.length > 0) { |
| | | data.forEach(item => { |
| | | let s = item[btn.controlField] !== undefined ? item[btn.controlField] + '' : '' |
| | | if (btn.controlVals.includes(s)) { |
| | | if (btn.controlVals.includes(s) || item.$lock) { |
| | | disabled = true |
| | | } |
| | | }) |
| | |
| | | MKEmitter.emit('refreshByButtonResult', btn.$menuId, btn.execSuccess, btn, '', this.state.selines) |
| | | } |
| | | |
| | | btn.syncComponentId && MKEmitter.emit('reloadData', btn.syncComponentId) |
| | | |
| | | if (btn.syncComponentId) { |
| | | if (btn.syncComponentId === 'multiComponent') { |
| | | btn.syncComponentIds.forEach((id, i) => { |
| | | setTimeout(() => { |
| | | MKEmitter.emit('reloadData', id) |
| | | }, 20 * i) |
| | | }) |
| | | } else { |
| | | MKEmitter.emit('reloadData', btn.syncComponentId) |
| | | } |
| | | } |
| | | |
| | | if (btn.switchTab && btn.switchTab.length > 0) { |
| | | let id = btn.switchTab[btn.switchTab.length - 1] |
| | | let node = document.getElementById('tab' + id) |
| | |
| | | }) |
| | | } |
| | | |
| | | let result = getExcelInSql(btn, data, this.state.dict, (this.props.BID || ''), this.state.primaryId) |
| | | let result = getExcelInSql(btn, data, (this.props.BID || ''), this.state.primaryId) |
| | | |
| | | if (result.errors) { |
| | | notification.warning({ |
| | |
| | | }) |
| | | } else if (btn.intertype === 'outer') { // 外部接口 |
| | | let _outParam = null |
| | | let ver_token = false |
| | | |
| | | new Promise(resolve => { |
| | | // 内部请求 |
| | |
| | | } else { |
| | | param.$token = btn.exInterface || '' |
| | | } |
| | | ver_token = true |
| | | } else { |
| | | if (window.GLOB.systemType === 'production' && btn.proInterface) { |
| | | param.rduri = btn.proInterface |
| | |
| | | }).then(response => { |
| | | if (!response) return |
| | | // 回调请求 |
| | | if (btn.callbackFunc) { |
| | | if (ver_token && response.ErrMesg === 'token_error') { |
| | | this.execError(response) |
| | | } else if (btn.callbackFunc ) { |
| | | // 存在回调函数时,调用 |
| | | delete response.message |
| | | delete response.status |