| | |
| | | } |
| | | |
| | | handleConfirm = () => { |
| | | const { card } = this.props |
| | | // 表单提交时检查输入值是否正确 |
| | | return new Promise((resolve, reject) => { |
| | | this.props.form.validateFieldsAndScroll((err, values) => { |
| | | if (!err) { |
| | | if (values.urls) { |
| | | values.linkurl = values.urls |
| | | } else if (card.typecharone === 'color' && /^[0-9a-f]{6}$/.test(values.linkurl)) { |
| | | values.linkurl = '#' + values.linkurl |
| | | } |
| | | resolve(values) |
| | | } else { |
| | |
| | | background: rgba(0, 0, 0, 0); |
| | | } |
| | | } |
| | | .normal-custom-table.fixed-height { |
| | | .ant-table-body { |
| | | border-bottom: 1px solid rgba(0, 0, 0, .05); |
| | | .ant-table-fixed { |
| | | border-bottom: 0; |
| | | } |
| | | } |
| | | } |
| | | .normal-custom-table.hidden { |
| | | thead { |
| | | display: none; |
| | |
| | | border: 1px solid rgba(0, 0, 0, 0.07); |
| | | background: rgba(0, 0, 0, 0); |
| | | } |
| | | } |
| | | .normal-data-table.fixed-height { |
| | | .ant-table-body { |
| | | border-bottom: 1px solid rgba(0, 0, 0, .05); |
| | | .ant-table-fixed { |
| | | border-bottom: 0; |
| | | } |
| | | } |
| | | } |
| | |
| | | if (window.GLOB.systemType === 'production' || sysType !== 'local') { |
| | | sysType = '' |
| | | } |
| | | |
| | | |
| | | let param = { |
| | | func: 's_get_sversions_sys_epc', |
| | | edition_int: edition_int, |
| | |
| | | closable={false} |
| | | maskClosable={false} |
| | | footer={[ |
| | | error && version && versions && versions.length > (version.index + 1) ? <Button key="close" onClick={this.skip}>跳过</Button> : null, |
| | | error && version ? <Button key="close" onClick={this.reset}>重新执行</Button> : null, |
| | | error && version && versions && versions.length > (version.index + 1) ? <Button key="skip" className="mk-orange" onClick={this.skip}>跳过</Button> : null, |
| | | error && version ? <Button key="reset" type="primary" onClick={this.reset}>重新执行</Button> : null, |
| | | <Button key="close" onClick={this.stop}>关闭</Button>, |
| | | ]} |
| | | destroyOnClose |
| | |
| | | }) |
| | | } |
| | | |
| | | setLoginView = () => { |
| | | const { oriConfig, config } = this.state |
| | | |
| | | if (!oriConfig || !is(fromJS(oriConfig), fromJS(config))) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '配置信息未保存!', |
| | | duration: 5 |
| | | }) |
| | | return |
| | | } |
| | | |
| | | let param = { |
| | | func: 's_kei_link_keyids_addupt', |
| | | BID: sessionStorage.getItem('appId'), |
| | | exec_type: 'y', |
| | | LText: '' |
| | | } |
| | | |
| | | let appViewList = sessionStorage.getItem('appViewList') |
| | | appViewList = appViewList ? JSON.parse(appViewList) : [] |
| | | appViewList = appViewList.filter(item => item.keys_type !== 'login') |
| | | |
| | | appViewList.unshift({ |
| | | appkey: window.GLOB.appkey || '', |
| | | bid: sessionStorage.getItem('appId') || '', |
| | | kei_no: sessionStorage.getItem('kei_no') || '', |
| | | keys_id: config.MenuID, |
| | | keys_type: 'login', |
| | | remark: config.MenuName |
| | | }) |
| | | |
| | | param.LText = appViewList.map(item => `select '${item.keys_id}','${item.keys_type}','${item.kei_no}','${item.appkey}','${item.bid}','${sessionStorage.getItem('CloudUserID')}','${item.remark}'`) |
| | | param.LText = param.LText.join(' union all ') |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') |
| | | param.secretkey = Utils.encrypt('', param.timestamp) |
| | | |
| | | let hasLogin = config.components.findIndex(item => item.type === 'login') > -1 |
| | | |
| | | confirm({ |
| | | title: '确定设置本页面为登录页吗?', |
| | | content: hasLogin ? '' : '当前页面尚未添加登录组件。', |
| | | onOk() { |
| | | Api.getSystemConfig(param).then(result => { |
| | | if (!result.status) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: result.message, |
| | | duration: 5 |
| | | }) |
| | | } else { |
| | | sessionStorage.setItem('appViewList', JSON.stringify(appViewList)) |
| | | } |
| | | }) |
| | | }, |
| | | onCancel() {} |
| | | }) |
| | | } |
| | | |
| | | changeView = (val) => { |
| | | if (val !== 'vertical') { |
| | | window.GLOB.winWidth = 992 |
| | |
| | | <PictureController/> |
| | | <Quotecomponent config={config} updateConfig={this.updateConfig}/> |
| | | <Button className="mk-border-green" icon="home" onClick={this.setHomeView}>设为首页</Button> |
| | | <Button className="mk-border-purple" icon="login" onClick={this.setLoginView}>设为登录页</Button> |
| | | <ReplaceField type="custom" config={config} updateConfig={this.resetConfig}/> |
| | | <Transfer MenuID={MenuId} /> |
| | | <Versions MenuId={MenuId} open_edition={config ? config.open_edition : ''}/> |
| | |
| | | .ant-radio-group { |
| | | white-space: nowrap; |
| | | } |
| | | .mk-source-wrap .mk-source-item-info .anticon-delete { |
| | | color: #ff4d4f; |
| | | } |
| | | } |
| | |
| | | }) |
| | | } |
| | | |
| | | setLoginView = () => { |
| | | const { oriConfig, config } = this.state |
| | | |
| | | if (!oriConfig || !is(fromJS(oriConfig), fromJS(config))) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '配置信息未保存!', |
| | | duration: 5 |
| | | }) |
| | | return |
| | | } |
| | | |
| | | let param = { |
| | | func: 's_kei_link_keyids_addupt', |
| | | BID: sessionStorage.getItem('appId'), |
| | | exec_type: 'y', |
| | | LText: '' |
| | | } |
| | | |
| | | let appViewList = sessionStorage.getItem('appViewList') |
| | | appViewList = appViewList ? JSON.parse(appViewList) : [] |
| | | appViewList = appViewList.filter(item => item.keys_type !== 'login') |
| | | |
| | | appViewList.unshift({ |
| | | appkey: window.GLOB.appkey || '', |
| | | bid: sessionStorage.getItem('appId') || '', |
| | | kei_no: sessionStorage.getItem('kei_no') || '', |
| | | keys_id: config.MenuID, |
| | | keys_type: 'login', |
| | | remark: config.MenuName |
| | | }) |
| | | |
| | | param.LText = appViewList.map(item => `select '${item.keys_id}','${item.keys_type}','${item.kei_no}','${item.appkey}','${item.bid}','${sessionStorage.getItem('CloudUserID')}','${item.remark}'`) |
| | | param.LText = param.LText.join(' union all ') |
| | | param.LText = Utils.formatOptions(param.LText) |
| | | |
| | | param.timestamp = moment().format('YYYY-MM-DD HH:mm:ss') |
| | | param.secretkey = Utils.encrypt('', param.timestamp) |
| | | |
| | | let hasLogin = config.components.findIndex(item => item.type === 'login') > -1 |
| | | |
| | | confirm({ |
| | | title: '确定设置本页面为登录页吗?', |
| | | content: hasLogin ? '' : '当前页面尚未添加登录组件。', |
| | | onOk() { |
| | | Api.getSystemConfig(param).then(result => { |
| | | if (!result.status) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: result.message, |
| | | duration: 5 |
| | | }) |
| | | } else { |
| | | sessionStorage.setItem('appViewList', JSON.stringify(appViewList)) |
| | | } |
| | | }) |
| | | }, |
| | | onCancel() {} |
| | | }) |
| | | } |
| | | |
| | | render () { |
| | | const { localedict, loading, visible, popBtn, comloading, activeKey, settingshow, controlshow, dict, MenuId, config, menuloading, customComponents } = this.state |
| | | |
| | |
| | | <PictureController/> |
| | | <Quotecomponent config={config} updateConfig={this.updateConfig}/> |
| | | <Button className="mk-border-green" icon="home" onClick={this.setHomeView}>设为首页</Button> |
| | | <Button className="mk-border-purple" icon="login" onClick={this.setLoginView}>设为登录页</Button> |
| | | <ReplaceField type="custom" config={config} updateConfig={this.resetConfig}/> |
| | | <Transfer MenuID={MenuId} /> |
| | | <Versions MenuId={MenuId} open_edition={config ? config.open_edition : ''}/> |