| | |
| | | defaultLang -- 打开的子应用语言类型,默认为zh-CN |
| | | WXAppID -- 使用公众号时,绑定的公众号ID |
| | | WXminiAppID -- 使用微信小程序时,绑定的小程序ID |
| | | WXMerchID -- 使用微信支付时,绑定的商户ID |
| | | WXNotice -- 是否开启明科云公众号消息提醒,值为 true 时开启,可通过明科云发送模板消息 |
| | | WXApps -- 存在多个公众号或小程序时可使用微信APP列表,注意填写默认公众号或小程序,[{"appId": "", "appName": "", "appType": "public/miniProgram"}] |
| | | WXApps -- 存在多个公众号、小程序或商户时可使用微信APP列表,注意填写默认公众号、小程序与商户号,格式 [{"appId": "", "appName": "", "appType": "public/miniProgram/merchant"}] |
| | | nginx -- 是否开启了nginx服务,值为 true 时开启,如需使用微信模板消息等服务,请先设置nginx服务并开启此配置 |
| | | debugger -- 值为 true 时开启调试模式,开启后移动端子应用中会有控制台 |
| | | licenseKey -- 许可密钥,在内部网络中使用系统时,会跳过epc验证 |
| | |
| | | "defaultLang": "zh-CN", |
| | | "WXAppID": "wx4d8a34c8d4494872", |
| | | "WXminiAppID": "", |
| | | "WXMerchID": "", |
| | | "WXNotice": "true", |
| | | "nginx": "true", |
| | | "debugger": false, |
| | |
| | | pop: ['label', 'OpenType', 'intertype', 'Ot', 'show', 'hover', 'swipe', 'icon', 'class', 'color', 'execSuccess', 'execError', 'syncComponent', 'switchTab', 'anchors', 'width', 'openmenu', 'refreshTab', 'position', 'hoverTitle', 'hidden', 'preButton'], |
| | | prompt: ['label', 'OpenType', 'intertype', 'Ot', 'show', 'hover', 'swipe', 'icon', 'class', 'color', 'execSuccess', 'execError', 'syncComponent', 'switchTab', 'anchors', 'width', 'openmenu', 'refreshTab', 'position', 'tipTitle', 'hoverTitle', 'hidden', 'preButton'], |
| | | exec: ['label', 'OpenType', 'intertype', 'Ot', 'show', 'hover', 'swipe', 'icon', 'class', 'color', 'execSuccess', 'execError', 'syncComponent', 'switchTab', 'anchors', 'width', 'openmenu', 'refreshTab', 'hoverTitle', 'hidden', 'preButton'], |
| | | excelIn: ['label', 'Ot', 'OpenType', 'intertype', 'show', 'hover', 'icon', 'class', 'color', 'sheet', 'execSuccess', 'execError', 'syncComponent', 'switchTab', 'width', 'hidden'], |
| | | excelOut: ['label', 'Ot', 'OpenType', 'intertype', 'show', 'hover', 'icon', 'class', 'color', 'execSuccess', 'execError', 'syncComponent', 'switchTab', 'pagination', 'search', 'width', 'hidden'], |
| | | excelIn: ['label', 'Ot', 'OpenType', 'intertype', 'show', 'hover', 'icon', 'class', 'color', 'sheet', 'execSuccess', 'execError', 'syncComponent', 'switchTab', 'width', 'hidden', 'refreshTab'], |
| | | excelOut: ['label', 'Ot', 'OpenType', 'intertype', 'show', 'hover', 'icon', 'class', 'color', 'execSuccess', 'execError', 'syncComponent', 'switchTab', 'pagination', 'search', 'width', 'hidden', 'refreshTab'], |
| | | popview: ['label', 'Ot', 'OpenType', 'show', 'hover', 'icon', 'class', 'color', 'popClose', 'width', 'display', 'ratio', 'syncComponent', 'clickouter', 'maskStyle', 'closeButton', 'hidden'], |
| | | tab: ['label', 'Ot', 'OpenType', 'show', 'hover', 'icon', 'class', 'color', 'linkmenu', 'width', 'hidden', 'openTab'], |
| | | innerpage: ['label', 'Ot', 'OpenType', 'pageTemplate', 'show', 'hover', 'swipe', 'icon', 'class', 'color', 'width', 'hidden'], |
| | |
| | | shows.push('output') |
| | | } |
| | | } else if (_funcType === 'refund') { |
| | | shows.push('Ot', 'wxApp', 'execSuccess', 'execError', 'syncComponent', 'openmenu', 'tipTitle') |
| | | shows.push('Ot', 'execSuccess', 'execError', 'syncComponent', 'openmenu', 'tipTitle') |
| | | reOptions.Ot = requireOptions.filter(op => ['requiredSgl'].includes(op.value)) |
| | | |
| | | shows.push('payMode') |
| | |
| | | options: modules.length ? [...modules, {value: 'multiComponent', label: '多组件'}] : [] |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | key: 'pagination', |
| | | label: '分页', |
| | | initVal: card.pagination || 'false', |
| | | tooltip: '导出数据量较大时(1000+),可设置分页请求数据。', |
| | | required: false, |
| | | options: [{ |
| | | value: 'true', |
| | | text: '是' |
| | | }, { |
| | | value: 'false', |
| | | text: '否' |
| | | }], |
| | | forbid: appType === 'mob' |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | key: 'search', |
| | | label: '搜索条件', |
| | | initVal: card.search || 'false', |
| | | required: false, |
| | | options: [{ |
| | | value: 'true', |
| | | text: '必填' |
| | | }, { |
| | | value: 'false', |
| | | text: '非必填' |
| | | }], |
| | | forbid: appType === 'mob' |
| | | }, |
| | | { |
| | | type: 'cascader', |
| | | key: 'refreshTab', |
| | | label: '刷新菜单', |
| | |
| | | tooltip: '执行成功后,需要跳转的锚点。' + (appType === 'mob' ? '注:小程序中无效' : ''), |
| | | required: false, |
| | | options: anchors |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | key: 'pagination', |
| | | label: '分页', |
| | | initVal: card.pagination || 'false', |
| | | tooltip: '导出数据量较大时(1000+),可设置分页请求数据。', |
| | | required: false, |
| | | options: [{ |
| | | value: 'true', |
| | | text: '是' |
| | | }, { |
| | | value: 'false', |
| | | text: '否' |
| | | }], |
| | | forbid: appType === 'mob' |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | key: 'search', |
| | | label: '搜索条件', |
| | | initVal: card.search || 'false', |
| | | required: false, |
| | | options: [{ |
| | | value: 'true', |
| | | text: '必填' |
| | | }, { |
| | | value: 'false', |
| | | text: '非必填' |
| | | }], |
| | | forbid: appType === 'mob' |
| | | }, |
| | | { |
| | | type: 'select', |
| | |
| | | options: modules.length ? [...modules, {value: 'multiComponent', label: '多组件'}] : [] |
| | | }, |
| | | { |
| | | type: 'cascader', |
| | | key: 'refreshTab', |
| | | label: '刷新菜单', |
| | | initVal: card.refreshTab || [], |
| | | tooltip: '执行成功后(或执行失败且存在刷新项时),需要同步刷新的菜单', |
| | | required: false, |
| | | forbid: viewType === 'popview', |
| | | options: menulist |
| | | }, |
| | | { |
| | | type: 'cascader', |
| | | key: 'openmenu', |
| | | label: '打开菜单', |
| | | tooltip: '执行成功后需要打开的菜单。', |
| | | initVal: card.openmenu || [], |
| | | extendName: 'MenuNo', |
| | | required: false, |
| | | allowClear: true, |
| | | options: menulist, |
| | | forbid: viewType === 'popview' |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | key: 'pagination', |
| | | label: '分页', |
| | |
| | | value: 'false', |
| | | text: '非必填' |
| | | }] |
| | | }, |
| | | { |
| | | type: 'cascader', |
| | | key: 'refreshTab', |
| | | label: '刷新菜单', |
| | | initVal: card.refreshTab || [], |
| | | tooltip: '执行成功后(或执行失败且存在刷新项时),需要同步刷新的菜单', |
| | | required: false, |
| | | forbid: viewType === 'popview', |
| | | options: menulist |
| | | }, |
| | | { |
| | | type: 'cascader', |
| | | key: 'openmenu', |
| | | label: '打开菜单', |
| | | tooltip: '执行成功后需要打开的菜单。', |
| | | initVal: card.openmenu || [], |
| | | extendName: 'MenuNo', |
| | | required: false, |
| | | allowClear: true, |
| | | options: menulist, |
| | | forbid: viewType === 'popview' |
| | | }, |
| | | { |
| | | type: 'text', |
| | |
| | | }) |
| | | if (res.status) { |
| | | if (config.billSaveBtn.reTabId) { |
| | | MKEmitter.emit('reloadMenuView', config.billSaveBtn.reTabId, 'table') |
| | | MKEmitter.emit('reloadMenuView', config.billSaveBtn.reTabId) |
| | | } |
| | | if (config.billSaveBtn.syncComId) { |
| | | MKEmitter.emit('reloadData', config.billSaveBtn.syncComId) |
| | |
| | | }) |
| | | if (res.status) { |
| | | if (config.billOutBtn.reTabId) { |
| | | MKEmitter.emit('reloadMenuView', config.billOutBtn.reTabId, 'table') |
| | | MKEmitter.emit('reloadMenuView', config.billOutBtn.reTabId) |
| | | } |
| | | if (config.billOutBtn.syncComId) { |
| | | MKEmitter.emit('reloadData', config.billOutBtn.syncComId) |
| | |
| | | } |
| | | |
| | | if (tabId) { |
| | | MKEmitter.emit('reloadMenuView', tabId, 'table') |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | } |
| | | }) |
| | | } |
| | |
| | | } |
| | | |
| | | if (tabId) { |
| | | MKEmitter.emit('reloadMenuView', tabId, 'table') |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | } |
| | | }) |
| | | } |
| | |
| | | MKEmitter.emit('closeTabView', MenuID || btn.$MenuID) |
| | | |
| | | if (btn.refreshTab && btn.refreshTab.length > 0) { |
| | | MKEmitter.emit('reloadMenuView', btn.refreshTab[btn.refreshTab.length - 1], 'table') |
| | | MKEmitter.emit('reloadMenuView', btn.refreshTab[btn.refreshTab.length - 1]) |
| | | } |
| | | return |
| | | } |
| | |
| | | loading: false |
| | | }) |
| | | |
| | | let tabId = '' |
| | | if (btn.refreshTab && btn.refreshTab.length > 0) { |
| | | tabId = btn.refreshTab[btn.refreshTab.length - 1] |
| | | } |
| | | |
| | | if (tabId && btn.$MenuID === tabId) { // 刷新当前菜单时,停止其他操作 |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | return |
| | | } |
| | | |
| | | if (btn.execSuccess === 'closepoptab') { |
| | | MKEmitter.emit('popclose') |
| | | } else if (btn.execSuccess !== 'never') { |
| | |
| | | } else { |
| | | MKEmitter.emit('reloadData', btn.syncComponentId) |
| | | } |
| | | } |
| | | |
| | | if (tabId) { |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | } |
| | | |
| | | if (btn.switchTab && btn.switchTab.length > 0) { |
| | |
| | | if (btn.execError === 'closepoptab') { |
| | | MKEmitter.emit('popclose') |
| | | } else if (btn.execError !== 'never') { |
| | | let tabId = '' |
| | | if (btn.refreshTab && btn.refreshTab.length > 0) { |
| | | tabId = btn.refreshTab[btn.refreshTab.length - 1] |
| | | } |
| | | if (tabId && btn.$MenuID === tabId) { // 刷新当前菜单时,停止其他操作 |
| | | MKEmitter.emit('reloadMenuView', tabId, 'table') |
| | | return |
| | | } |
| | | |
| | | MKEmitter.emit('refreshByButtonResult', btn.$menuId, btn.execError, btn, '', this.state.selines) |
| | | |
| | | if (btn.syncComponentId) { |
| | |
| | | MKEmitter.emit('reloadData', btn.syncComponentId) |
| | | } |
| | | } |
| | | |
| | | if (tabId) { |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | } |
| | | } |
| | | |
| | | if (btn.execError === 'popclose' && btn.$tabId) { // 标签关闭刷新 |
| | |
| | | loading: false |
| | | }) |
| | | |
| | | let tabId = '' |
| | | if (btn.refreshTab && btn.refreshTab.length > 0) { |
| | | tabId = btn.refreshTab[btn.refreshTab.length - 1] |
| | | } |
| | | |
| | | if (tabId && btn.$MenuID === tabId) { // 刷新当前菜单时,停止其他操作 |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | return |
| | | } |
| | | |
| | | if (btn.execSuccess === 'closepoptab') { |
| | | MKEmitter.emit('popclose') |
| | | } else if (btn.execSuccess !== 'never') { |
| | |
| | | } else { |
| | | MKEmitter.emit('reloadData', btn.syncComponentId) |
| | | } |
| | | } |
| | | |
| | | if (tabId) { |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | } |
| | | |
| | | if (btn.switchTab && btn.switchTab.length > 0) { |
| | |
| | | if (btn.execError === 'closepoptab') { |
| | | MKEmitter.emit('popclose') |
| | | } else if (btn.execError !== 'never') { |
| | | let tabId = '' |
| | | if (btn.refreshTab && btn.refreshTab.length > 0) { |
| | | tabId = btn.refreshTab[btn.refreshTab.length - 1] |
| | | } |
| | | if (tabId && btn.$MenuID === tabId) { // 刷新当前菜单时,停止其他操作 |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | return |
| | | } |
| | | |
| | | MKEmitter.emit('refreshByButtonResult', btn.$menuId, btn.execError, btn, '', []) |
| | | |
| | | if (btn.syncComponentId) { |
| | |
| | | MKEmitter.emit('reloadData', btn.syncComponentId) |
| | | } |
| | | } |
| | | |
| | | if (tabId) { |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | } |
| | | } |
| | | |
| | | if (btn.execError === 'popclose' && btn.$tabId) { // 标签关闭刷新 |
| | |
| | | } |
| | | } |
| | | |
| | | let appId = window.GLOB.WXAppID || window.GLOB.WXminiAppID || '' |
| | | |
| | | if (btn.wxApp && window.GLOB.WXApps && window.GLOB.WXApps.findIndex(item => item.appId === btn.wxApp) > -1) { |
| | | appId = btn.wxApp |
| | | } |
| | | |
| | | if (!appId) { |
| | | notification.warning({ |
| | | top: 10, |
| | | message: '未获取到应用ID!', |
| | | duration: 5 |
| | | }) |
| | | return |
| | | } |
| | | |
| | | this.setState({loading: true}) |
| | | |
| | | if (param) { |
| | |
| | | id = res.mk_b_id || res[btn.output] || orderId |
| | | } |
| | | |
| | | Api.setRefund({out_biz_no: id, app_id: appId}).then(res => { |
| | | Api.setRefund({out_biz_no: id}).then(res => { |
| | | if (!res.status) { |
| | | this.execError({ErrCode: 'E', message: res.message || window.GLOB.dict['exc_fail'] || '执行失败!', ...res}) |
| | | } else { |
| | |
| | | } |
| | | }) |
| | | } else { |
| | | Api.setRefund({out_biz_no: orderId, app_id: appId}).then(res => { |
| | | Api.setRefund({out_biz_no: orderId}).then(res => { |
| | | if (!res.status) { |
| | | this.execError({ErrCode: 'E', message: res.message || window.GLOB.dict['exc_fail'] || '执行失败!', ...res}) |
| | | } else { |
| | |
| | | tabId = btn.refreshTab[btn.refreshTab.length - 1] |
| | | } |
| | | |
| | | // if (btn.formCache === 'clear') { // 清除表单缓存 |
| | | // window.GLOB.CacheMap = new Map() |
| | | // } |
| | | |
| | | if (tabId && btn.$MenuID === tabId) { // 刷新当前菜单时,停止其他操作 |
| | | MKEmitter.emit('reloadMenuView', tabId, 'table') |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | return |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | if (tabId) { |
| | | MKEmitter.emit('reloadMenuView', tabId, 'table') |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | } |
| | | |
| | | if (btn.switchTab && btn.switchTab.length > 0) { |
| | |
| | | tabId = btn.refreshTab[btn.refreshTab.length - 1] |
| | | } |
| | | if (tabId && btn.$MenuID === tabId) { // 刷新当前菜单时,停止其他操作 |
| | | MKEmitter.emit('reloadMenuView', tabId, 'table') |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | return |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | if (tabId) { |
| | | MKEmitter.emit('reloadMenuView', tabId, 'table') |
| | | MKEmitter.emit('reloadMenuView', tabId) |
| | | } |
| | | } |
| | | |