From 3d4bc79a80eb9cff0f8ef7c53f9685c9ff9fbd2d Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 02 九月 2021 23:17:36 +0800 Subject: [PATCH] 2021-09-02 --- src/views/appmanage/index.scss | 8 ++ src/components/qrcode/index.scss | 3 src/tabviews/verupmanage/actionList/index.jsx | 11 +- src/views/pcdesign/index.jsx | 8 +- src/menu/components/share/actioncomponent/formconfig.jsx | 2 src/components/qrcode/index.jsx | 6 + src/tabviews/zshare/actionList/printbutton/index.jsx | 90 +++++++++++----------- src/views/appmanage/scriptform/index.jsx | 12 ++- src/views/rolemanage/index.jsx | 12 +++ src/menu/components/share/actioncomponent/actionform/index.jsx | 2 src/templates/sharecomponent/actioncomponent/verifyexcelin/customscript/index.jsx | 9 - src/menu/modalconfig/index.jsx | 14 +++ src/views/appmanage/index.jsx | 11 +- src/views/appmanage/submutilform/index.scss | 3 src/views/appmanage/submutilform/index.jsx | 14 +++ src/views/mobdesign/index.jsx | 8 +- 16 files changed, 136 insertions(+), 77 deletions(-) diff --git a/src/components/qrcode/index.jsx b/src/components/qrcode/index.jsx index 122a9b1..0fbc0cc 100644 --- a/src/components/qrcode/index.jsx +++ b/src/components/qrcode/index.jsx @@ -29,13 +29,17 @@ const { value, card } = this.props let color = card.color let size = card.qrWidth || 50 + let width = size + 'px' if (/rgb/ig.test(color)) { color = this.hexify(color) } + if (size < 640) { + size = 640 + } return ( - <div className="qrcode-box"> + <div className="qrcode-box" style={{width: width, height: width}}> <QrCode value={value} size={size} diff --git a/src/components/qrcode/index.scss b/src/components/qrcode/index.scss index efe8352..6b05972 100644 --- a/src/components/qrcode/index.scss +++ b/src/components/qrcode/index.scss @@ -1,5 +1,8 @@ .qrcode-box { + display: inline-block; canvas { vertical-align: top; + max-width: 100%; + max-height: 100%; } } \ No newline at end of file diff --git a/src/menu/components/share/actioncomponent/actionform/index.jsx b/src/menu/components/share/actioncomponent/actionform/index.jsx index 8fdc523..c5ebebb 100644 --- a/src/menu/components/share/actioncomponent/actionform/index.jsx +++ b/src/menu/components/share/actioncomponent/actionform/index.jsx @@ -177,8 +177,6 @@ } } else if (_funcType === 'mkBinding' || _funcType === 'mkUnBinding') { _options.push('execSuccess', 'execError') - } else if (_funcType === 'scan') { - _options.push('openmenu') } else if (_funcType === 'closetab') { _options.push('refreshTab') } diff --git a/src/menu/components/share/actioncomponent/formconfig.jsx b/src/menu/components/share/actioncomponent/formconfig.jsx index 99bdf90..6eb2dad 100644 --- a/src/menu/components/share/actioncomponent/formconfig.jsx +++ b/src/menu/components/share/actioncomponent/formconfig.jsx @@ -87,7 +87,7 @@ funTypes = [ { value: 'mkBinding', text: '寮�閫氭壂鐮佺櫥褰�' }, { value: 'mkUnBinding', text: '鐢ㄦ埛瑙g粦' }, - { value: 'scan', text: '鎵竴鎵�' }, + // { value: 'scan', text: '鎵竴鎵�' }, { value: 'reAuth', text: '閲嶆柊鎺堟潈' }, ] } else { diff --git a/src/menu/modalconfig/index.jsx b/src/menu/modalconfig/index.jsx index 7aed763..fc2a91e 100644 --- a/src/menu/modalconfig/index.jsx +++ b/src/menu/modalconfig/index.jsx @@ -303,6 +303,19 @@ }, 100) } + clearConfig = () => { + const _this = this + let _config = {...this.state.config, fields: []} + + confirm({ + content: '纭畾娓呯┖琛ㄥ崟鍚楋紵', + onOk() { + _this.setState({ config: _config }) + }, + onCancel() {} + }) + } + completeSave = () => { this.setState({saving: false}) } @@ -434,6 +447,7 @@ <div className="setting"> <Card title={dict['header.menu.form.configurable']} bordered={false} extra={ <div> + <Button type="danger" onClick={this.clearConfig}>娓呯┖</Button> <EditComponent dict={dict} options={['form']} config={this.state.config} refresh={(res) => this.updateConfig(res.config)}/> <Button type="primary" loading={saving} onClick={this.submitConfig}>淇濆瓨</Button> <Button onClick={this.cancelConfig}>杩斿洖</Button> diff --git a/src/tabviews/verupmanage/actionList/index.jsx b/src/tabviews/verupmanage/actionList/index.jsx index 6947633..23dd7ef 100644 --- a/src/tabviews/verupmanage/actionList/index.jsx +++ b/src/tabviews/verupmanage/actionList/index.jsx @@ -440,6 +440,7 @@ let param = params.shift() let _outParam = null let _localParam = null + let errRes = null if (widthNumber) { this.setState({ @@ -543,9 +544,11 @@ } }).then(res => { if (!res) return - + if (_localParam) { - + if (!res.status) { + errRes = res + } return Api.getLocalConfig(_localParam) } else if (res.status) { if (params.length === 0) { @@ -561,7 +564,7 @@ }).then(res => { if (!res) return - if (res.status) { + if (res.status && !errRes) { if (params.length === 0) { this.execSuccess(btn, res) _resolve() @@ -569,7 +572,7 @@ this.outerLoopRequest(params, btn, _resolve, widthNumber) } } else { - this.execError(res, btn) + this.execError(errRes || res, btn) _resolve() } }) diff --git a/src/tabviews/zshare/actionList/printbutton/index.jsx b/src/tabviews/zshare/actionList/printbutton/index.jsx index 2902392..e1ae252 100644 --- a/src/tabviews/zshare/actionList/printbutton/index.jsx +++ b/src/tabviews/zshare/actionList/printbutton/index.jsx @@ -211,17 +211,17 @@ let printlist = [] let templates = [] - let printCount = 1 + let printCount = +(formdata.printCount || formdata.PrintCount || formdata.printcount || formdata.Printcount || 1) - if (formdata.printCount && typeof(formdata.printCount) === 'number' && formdata.printCount >= 1) { - printCount = formdata.printCount + if (isNaN(printCount) || printCount < 1) { + printCount = 1 } new Promise(resolve => { if (btn.intertype === 'system') { // 浣跨敤绯荤粺鏃讹紝鐩存帴浠庤〃鏍兼垨琛ㄥ崟涓�夊彇鏁版嵁 let printcell = {} - printcell.printType = formdata.printType || '' + printcell.printType = formdata.printType || formdata.PrintType || formdata.printtype || formdata.Printtype || '' printcell.printCount = printCount printcell.templateID = btn.verify.Template || '' @@ -245,12 +245,13 @@ // 绯荤粺鎵撳嵃鏁版嵁锛屾牎楠宒ata瀛楁 if (btn.verify.printMode !== 'custom' && (!cell.data || cell.data.length === 0)) return - cell.templateID = cell.templateID || btn.verify.Template - cell.printType = cell.printType || formdata.printType || '' + cell.templateID = cell.templateID || cell.TemplateID || cell.Templateid || cell.templateid || btn.verify.Template + cell.printType = cell.printType || cell.PrintType || cell.printtype || cell.Printtype || formdata.printType || formdata.PrintType || formdata.printtype || formdata.Printtype || '' - let _printCount = printCount - if (cell.printCount && typeof(cell.printCount) === 'number' && cell.printCount >= 1) { - _printCount = cell.printCount + let _printCount = +(cell.printCount || cell.PrintCount || cell.printcount || cell.Printcount || 0) + + if (isNaN(_printCount) || _printCount < 1) { + _printCount = printCount } cell.printCount = _printCount @@ -1031,7 +1032,7 @@ task: { taskID: Utils.getuuid(), preview: false, - printer: printer, + printer: printer === 'lackprinter' ? '' : printer, documents: [_cell] } }) @@ -1078,19 +1079,19 @@ return } - let lackItems = printerList.filter(cell => cell.task.printer === 'lackprinter')[0] + // let lackItems = printerList.filter(cell => cell.task.printer === 'lackprinter')[0] if (!socket || socket.readyState !== 1 || socket.url !== 'ws://' + btn.verify.linkUrl) { socket = new WebSocket('ws://' + btn.verify.linkUrl) } else { - if (lackItems) { - let request = { - requestID: '', - version: '', - cmd: 'getPrinters' - } - socket.send(JSON.stringify(request)) - } else { + // if (lackItems) { + // let request = { + // requestID: '', + // version: '', + // cmd: 'getPrinters' + // } + // socket.send(JSON.stringify(request)) + // } else { this.syncMessageSend(printerList) this.execSuccess({ @@ -1099,19 +1100,19 @@ ErrMesg: '鎵撳嵃璇锋眰宸插彂鍑恒��', status: true }) - } + // } } // 鎵撳紑Socket socket.onopen = () =>{ - if (lackItems) { - let request = { - requestID: '', - version: '', - cmd: 'getPrinters' - } - socket.send(JSON.stringify(request)) - } else { + // if (lackItems) { + // let request = { + // requestID: '', + // version: '', + // cmd: 'getPrinters' + // } + // socket.send(JSON.stringify(request)) + // } else { this.syncMessageSend(printerList) this.execSuccess({ @@ -1120,7 +1121,7 @@ ErrMesg: '鎵撳嵃璇锋眰宸插彂鍑恒��', status: true }) - } + // } } // 鐩戝惉娑堟伅 socket.onmessage = (event) => { @@ -1141,23 +1142,24 @@ } } - if (data && data.cmd === 'getPrinters' && data.status) { - printerList = printerList.map(cell => { - if (cell.task.printer === 'lackprinter') { - cell.task.printer = data.defaultPrinter - } - return cell - }) + // if (data && data.cmd === 'getPrinters' && data.status) { + // printerList = printerList.map(cell => { + // if (cell.task.printer === 'lackprinter') { + // cell.task.printer = data.defaultPrinter + // } + // return cell + // }) - this.syncMessageSend(printerList) + // this.syncMessageSend(printerList) - this.execSuccess({ - ErrCode: 'S', - message: '', - ErrMesg: '鎵撳嵃璇锋眰宸插彂鍑恒��', - status: true - }) - } else if (data && data.message && !data.status) { + // this.execSuccess({ + // ErrCode: 'S', + // message: '', + // ErrMesg: '鎵撳嵃璇锋眰宸插彂鍑恒��', + // status: true + // }) + // } else if (data && data.message && !data.status) { + if (data && data.message && !data.status) { this.execError({ ErrCode: 'N', message: data.message, diff --git a/src/templates/sharecomponent/actioncomponent/verifyexcelin/customscript/index.jsx b/src/templates/sharecomponent/actioncomponent/verifyexcelin/customscript/index.jsx index fc73196..2f6e6e5 100644 --- a/src/templates/sharecomponent/actioncomponent/verifyexcelin/customscript/index.jsx +++ b/src/templates/sharecomponent/actioncomponent/verifyexcelin/customscript/index.jsx @@ -41,12 +41,7 @@ columns = columns.filter(item => item.import !== 'false') let fields = columns.map(item => item.Column) - if (!fields.includes('ID')) { - fields.unshift('ID') - } - if (!fields.includes('BID')) { - fields.unshift('BID') - } + fields.push('jskey') let _sql = `Declare @${btn.sheet} table (${columns.map(item => item.Column + ' ' + item.type).join(',')},jskey nvarchar(50) ) Declare @UserName nvarchar(50),@FullName nvarchar(50),@RoleID nvarchar(512),@departmentcode nvarchar(50),@organization nvarchar(50),@login_city nvarchar(50),@ErrorCode nvarchar(50), @retmsg nvarchar(4000),@tbid Nvarchar(512) @@ -287,7 +282,7 @@ </Col> {usefulfields ? <Col span={24} className="sqlfield"> <Form.Item label={'鍙敤瀛楁'}> - {usefulfields}, jskey + BID, ID, LoginUID, SessionUid, UserID, Appkey, UserName, FullName, RoleID, departmentcode, organization, login_city, {usefulfields} </Form.Item> </Col> : null} <Col span={8} style={{whiteSpace: 'nowrap'}}> diff --git a/src/views/appmanage/index.jsx b/src/views/appmanage/index.jsx index 0440218..be63af1 100644 --- a/src/views/appmanage/index.jsx +++ b/src/views/appmanage/index.jsx @@ -313,8 +313,8 @@ }) let kei_no = res.appId.split(',')[1] - let lang = res.subAppId.split(',')[1] - let kei_no_detail = res.subAppId.split(',')[2] + let lang = res.subAppId ? res.subAppId.split(',')[1] : '' + let kei_no_detail = res.subAppId ? res.subAppId.split(',')[2] : '' let param = { func: 's_sVersionDetail_CloudAdd', @@ -469,6 +469,7 @@ cell.copyright = _param.copyright || '' cell.logo = _param.logo || '' cell.apptype = _param.apptype || '' + cell.delay = _param.delay || 0 } return cell @@ -601,7 +602,7 @@ sublist = sublist.filter(item => item.ID !== record.ID) // param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','${item.link_type || 'true'}','${item.role_type || 'true'}','${item.lang || 'zh-CN'}'`) - param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','false','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}','${window.btoa(window.encodeURIComponent(JSON.stringify({copyright: item.copyright || '', logo: item.logo || '', apptype: item.apptype || ''})))}'`) + param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','false','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}','${window.btoa(window.encodeURIComponent(JSON.stringify({copyright: item.copyright || '', logo: item.logo || '', apptype: item.apptype || '', delay: item.delay || 0})))}'`) param.LText = param.LText.join(' union all ') param.LText = Utils.formatOptions(param.LText) @@ -825,7 +826,7 @@ if (visible === 'edit') { // param.LText = selectApp.sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','${item.link_type || 'true'}','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}'`) - param.LText = selectApp.sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','false','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}','${window.btoa(window.encodeURIComponent(JSON.stringify({copyright: item.copyright || '', logo: item.logo || '', apptype: item.apptype || ''})))}'`) + param.LText = selectApp.sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','false','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}','${window.btoa(window.encodeURIComponent(JSON.stringify({copyright: item.copyright || '', logo: item.logo || '', apptype: item.apptype || '', delay: item.delay || 0})))}'`) param.LText = param.LText.join(' union all ') param.LText = Utils.formatOptions(param.LText) } @@ -911,7 +912,7 @@ } // param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','${item.login_types || 'true'}','${item.link_type || 'true'}','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}'`) - param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','false','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}','${window.btoa(window.encodeURIComponent(JSON.stringify({copyright: item.copyright || '', logo: item.logo || '', apptype: item.apptype || ''})))}'`) + param.LText = sublist.map(item => `select '${item.ID}','${item.typename}','${selectApp.ID}','${sessionStorage.getItem('CloudUserID') || ''}','${window.GLOB.appkey || ''}','false','false','${item.role_type || 'true'}','${item.lang || 'zh-CN'}','${item.css || ''}','${item.title || ''}','${item.favicon || ''}','${item.user_binding || ''}','${item.sms_id || ''}','${window.btoa(window.encodeURIComponent(JSON.stringify({copyright: item.copyright || '', logo: item.logo || '', apptype: item.apptype || '', delay: item.delay || 0})))}'`) param.LText = param.LText.join(' union all ') param.LText = Utils.formatOptions(param.LText) diff --git a/src/views/appmanage/index.scss b/src/views/appmanage/index.scss index e9858f7..ca21047 100644 --- a/src/views/appmanage/index.scss +++ b/src/views/appmanage/index.scss @@ -23,6 +23,14 @@ position: relative; display: flex; + .ant-table { + th { + white-space: nowrap; + } + td { + word-break: break-all; + } + } .left-view { flex: 1; width: 60%; diff --git a/src/views/appmanage/scriptform/index.jsx b/src/views/appmanage/scriptform/index.jsx index 50b392e..4fc324c 100644 --- a/src/views/appmanage/scriptform/index.jsx +++ b/src/views/appmanage/scriptform/index.jsx @@ -66,6 +66,7 @@ changeApp = (val) => { const { applist } = this.props + const { type } = this.state let app = applist.filter(item => `${item.ID},${item.kei_no}` === val)[0] @@ -84,7 +85,10 @@ this.setState({sublist, subAppId, appId}, () => { this.getViews() }) - this.props.form.setFieldsValue({subAppId}) + + if (type !== 'app') { + this.props.form.setFieldsValue({subAppId}) + } } changeSubApp = (val) => { @@ -164,7 +168,7 @@ }] })( <Select onChange={this.changeType}> - <Select.Option value="app">搴旂敤</Select.Option> + <Select.Option value="app">搴旂敤锛堝熀鏈俊鎭級</Select.Option> <Select.Option value="subapp">瀛愬簲鐢�</Select.Option> <Select.Option value="view">椤甸潰</Select.Option> <Select.Option value="role">鏉冮檺鏍�</Select.Option> @@ -189,7 +193,7 @@ )} </Form.Item> </Col> - <Col span={12}> + {type !== 'app' ? <Col span={12}> <Form.Item label="瀛愬簲鐢�"> {getFieldDecorator('subAppId', { initialValue: subAppId, @@ -205,7 +209,7 @@ </Select> )} </Form.Item> - </Col> + </Col> : null} {type === 'view' ? <Col span={12}> <Form.Item label="椤甸潰"> {getFieldDecorator('viewId', { diff --git a/src/views/appmanage/submutilform/index.jsx b/src/views/appmanage/submutilform/index.jsx index e61f347..c374caf 100644 --- a/src/views/appmanage/submutilform/index.jsx +++ b/src/views/appmanage/submutilform/index.jsx @@ -1,6 +1,6 @@ import React, {Component} from 'react' import PropTypes from 'prop-types' -import { Form, Row, Col, Select, Radio, Input, Tooltip, Icon, notification } from 'antd' +import { Form, Row, Col, Select, Radio, Input, Tooltip, Icon, notification, InputNumber } from 'antd' import asyncComponent from '@/utils/asyncComponent' import './index.scss' @@ -240,6 +240,18 @@ )} </Form.Item> </Col> : null} + {typename !== 'pc' ? <Col span={12}> + <Form.Item label={ + <Tooltip placement="topLeft" title="鍦ㄤ娇鐢ㄦ槑绉戜簯APP鏃讹紝涓斿湪app妯″紡涓棤鏁�"> + <Icon type="question-circle" /> + 寤惰繜鍔犺浇 + </Tooltip> + }> + {getFieldDecorator('delay', { + initialValue: card ? card.delay || 0 : 0 + })(<InputNumber min={0} max={5000} precision={0} onPressEnter={this.handleSubmit}/>)} + </Form.Item> + </Col> : null} </Row> </Form> ) diff --git a/src/views/appmanage/submutilform/index.scss b/src/views/appmanage/submutilform/index.scss index f6ceb5b..6aee97d 100644 --- a/src/views/appmanage/submutilform/index.scss +++ b/src/views/appmanage/submutilform/index.scss @@ -13,4 +13,7 @@ border-radius: 0 4px 4px 0; } } + .ant-input-number { + width: 100%; + } } \ No newline at end of file diff --git a/src/views/mobdesign/index.jsx b/src/views/mobdesign/index.jsx index 36f4c49..b981866 100644 --- a/src/views/mobdesign/index.jsx +++ b/src/views/mobdesign/index.jsx @@ -88,7 +88,7 @@ localedict: sessionStorage.getItem('lang') !== 'en-US' ? antdZhCN : antdEnUS, dict: sessionStorage.getItem('lang') !== 'en-US' ? zhCN : enUS }) - this.getAppMessage() + this.getAppMessage(param.MenuID) } else if (param.type === 'view') { window.GLOB.winWidth = 420 window.GLOB.winHeight = 738 @@ -218,7 +218,7 @@ this.props.history.push('/mobdesign/' + param) } - getAppMessage = () => { + getAppMessage = (MenuID) => { Api.getSystemConfig({ func: 's_get_keyids', bid: sessionStorage.getItem('appId') @@ -232,9 +232,9 @@ return } - let homeId = '' + let homeId = MenuID || '' let appViewList = [] - if (res.data && res.data.length > 0) { + if (!homeId && res.data && res.data.length > 0) { appViewList = res.data appViewList.forEach(item => { if (item.keys_type === 'index') { diff --git a/src/views/pcdesign/index.jsx b/src/views/pcdesign/index.jsx index 3b64363..463841e 100644 --- a/src/views/pcdesign/index.jsx +++ b/src/views/pcdesign/index.jsx @@ -91,7 +91,7 @@ localedict: sessionStorage.getItem('lang') !== 'en-US' ? antdZhCN : antdEnUS, dict: sessionStorage.getItem('lang') !== 'en-US' ? zhCN : enUS }) - this.getAppMessage() + this.getAppMessage(param.MenuID) } else if (param.type === 'view') { this.setState({ MenuId: param.MenuID @@ -193,7 +193,7 @@ this.props.history.push('/pcdesign/' + param) } - getAppMessage = () => { + getAppMessage = (MenuID) => { Api.getSystemConfig({ func: 's_get_keyids', bid: sessionStorage.getItem('appId') @@ -207,9 +207,9 @@ return } - let homeId = '' + let homeId = MenuID || '' let appViewList = [] - if (res.data && res.data.length > 0) { + if (!homeId && res.data && res.data.length > 0) { appViewList = res.data appViewList.forEach(item => { if (item.keys_type === 'index') { diff --git a/src/views/rolemanage/index.jsx b/src/views/rolemanage/index.jsx index 459e949..26dd053 100644 --- a/src/views/rolemanage/index.jsx +++ b/src/views/rolemanage/index.jsx @@ -35,6 +35,7 @@ render: (text, record) => ( <div> <Button type="link" onClick={() => this.deleteMenu(record)} style={{color: '#ff4d4f'}}>鍒犻櫎</Button> + <Button type="link" onClick={() => this.jumpApp(record)} style={{color: '#1890ff', marginLeft: '5px'}}>缂栬緫</Button> </div> ), }, @@ -741,6 +742,17 @@ this.setState({ visible: true, targetKeys: [] }) } + jumpApp = (item) => { + const { app } = this.state + + let route = 'mobdesign' + if (app.typename === 'pc') { + route = 'pcdesign' + } + + window.open(window.location.href.replace(/#.+/ig, `#/${route}/${window.btoa(window.encodeURIComponent(JSON.stringify({...app, MenuID: item.MenuID, type: 'app'})))}`)) + } + render () { const { app, loading, columns, menulist, trees, searchkey } = this.state let _menulist = menulist -- Gitblit v1.8.0