| | |
| | | btn: PropTypes.object, // 按钮 |
| | | columns: PropTypes.any, // 字段列 |
| | | setting: PropTypes.any, // 页面通用设置 |
| | | ContainerId: PropTypes.any, // tab页面ID,用于弹窗控制 |
| | | disabled: PropTypes.any, // 行按钮禁用 |
| | | } |
| | | |
| | |
| | | result.open_key = Utils.encryptOpenKey(result.secretkey, result.timestamp) |
| | | } |
| | | } else { |
| | | if (btn.sysInterface === 'true' && window.GLOB.mainSystemApi) { |
| | | if (btn.sysInterface === 'true') { |
| | | if (window.GLOB.mainSystemApi) { |
| | | result.rduri = window.GLOB.mainSystemApi |
| | | } else if (btn.sysInterface !== 'true') { |
| | | } |
| | | } else if (btn.sysInterface === 'external') { |
| | | if (window.GLOB.systemType === 'production') { |
| | | result.$token = btn.exProInterface || '' |
| | | } else { |
| | | result.$token = btn.exInterface || '' |
| | | } |
| | | } else { |
| | | if (window.GLOB.systemType === 'production' && btn.proInterface) { |
| | | result.rduri = btn.proInterface |
| | | } else { |
| | |
| | | node && node.scrollIntoView({behavior: 'smooth', block: 'center', inline: 'nearest'}) |
| | | } |
| | | |
| | | if (btn.MenuID && Array.isArray(btn.openmenu) && btn.openmenu.length > 0) { |
| | | let newtab = { |
| | | if (btn.openmenu && Array.isArray(btn.openmenu) && btn.openmenu.length > 0) { |
| | | let menuId = btn.openmenu.slice(-1)[0] |
| | | let newtab = window.GLOB.mkThdMenus.filter(m => m.MenuID === menuId)[0] |
| | | |
| | | if (!newtab && btn.MenuID) { |
| | | newtab = { |
| | | MenuID: btn.MenuID, |
| | | MenuName: btn.MenuName, |
| | | MenuNo: btn.MenuNo, |
| | | type: btn.tabType, |
| | | param: { |
| | | $BID: id |
| | | type: btn.tabType |
| | | } |
| | | } else if (!newtab) { |
| | | return |
| | | } |
| | | |
| | | newtab = {...newtab, param: { $BID: id }} |
| | | |
| | | if (['linkage_navigation', 'linkage', 'menu_board'].includes(window.GLOB.navBar)) { |
| | | MKEmitter.emit('modifyTabs', newtab, 'replace') |
| | |
| | | * @description 显示模态框 |
| | | */ |
| | | getModels = () => { |
| | | const { setting, BID, btn, BData } = this.props |
| | | const { BID, btn, BData } = this.props |
| | | const { btnconfig, visible } = this.state |
| | | |
| | | if (!btnconfig || !btnconfig.setting) return null |
| | |
| | | } else { |
| | | let container = document.body |
| | | |
| | | if ( |
| | | (setting.tabType === 'main' && btnconfig.setting.container === 'tab' && this.props.ContainerId) || |
| | | (btnconfig.setting.container === 'tab' && btn.ContainerId) |
| | | ) { |
| | | if (btnconfig.setting.container === 'tab' && btn.ContainerId) { |
| | | width = btnconfig.setting.width > 100 ? btnconfig.setting.width : btnconfig.setting.width + '%' |
| | | container = () => document.getElementById(this.props.ContainerId || btn.ContainerId) |
| | | container = () => document.getElementById(btn.ContainerId) |
| | | } |
| | | return ( |
| | | <Modal |