| | |
| | | import { Modal } from 'antd' |
| | | import { SettingOutlined } from '@ant-design/icons' |
| | | |
| | | import zhCN from '@/locales/zh-CN/model.js' |
| | | import enUS from '@/locales/en-US/model.js' |
| | | import SettingForm from './settingform' |
| | | import MKEmitter from '@/utils/events.js' |
| | | |
| | |
| | | } |
| | | |
| | | state = { |
| | | dict: sessionStorage.getItem('lang') !== 'en-US' ? zhCN : enUS, |
| | | menu: null, // 菜单信息 |
| | | visible: false, // 模态框控制 |
| | | loading: false // 设置信息验证保存中 |
| | |
| | | |
| | | render() { |
| | | const { config } = this.props |
| | | const { dict, visible, loading } = this.state |
| | | const { visible, loading } = this.state |
| | | |
| | | return ( |
| | | <div className="model-tree-menu-setting"> |
| | | <SettingOutlined onClick={this.changeSetting} /> |
| | | {/* 设置全局配置及列表数据源 */} |
| | | <Modal |
| | | wrapClassName="model-tree-setting-verify-modal" |
| | | title="数据源配置" |
| | | wrapClassName="mk-pop-modal" |
| | | visible={visible} |
| | | width={900} |
| | | width={'75vw'} |
| | | maskClosable={false} |
| | | onCancel={() => { MKEmitter.emit('modalStatus', false); this.setState({ visible: false })}} |
| | | confirmLoading={loading} |
| | |
| | | destroyOnClose |
| | | > |
| | | <SettingForm |
| | | dict={dict} |
| | | config={config} |
| | | menu={this.state.menu} |
| | | inputSubmit={this.settingSave} |