| | |
| | | profileVisible: false, // 验证信息模态框 |
| | | editgroup: null, // 当前编辑组 |
| | | groupVisible: false, // 编辑组模态框 |
| | | optionLibs: null // 自定义下拉选项库 |
| | | optionLibs: null, // 自定义下拉选项库 |
| | | activeKey: '0' // 默认展开基本信息 |
| | | } |
| | | |
| | | /** |
| | |
| | | |
| | | this.setState({ |
| | | config: _config, |
| | | activeKey: btnTab.activeKey || '0', |
| | | optionLibs: optionLibs, |
| | | columns: columns, |
| | | originMenu: JSON.parse(JSON.stringify(_config)), |
| | |
| | | */ |
| | | tableCreatFunc = () => { |
| | | const { menu } = this.props |
| | | let config = JSON.parse(JSON.stringify(this.state.config)) |
| | | const { config } = this.state |
| | | |
| | | this.settingRef.handleConfirm().then(res => { |
| | | const setting = res |
| | | this.settingRef.handleConfirm().then(setting => { |
| | | |
| | | if (!(setting.interType === 'inner') || !setting.innerFunc) { |
| | | notification.warning({ |
| | | top: 92, |
| | |
| | | Api.getLocalConfig(param) |
| | | } |
| | | |
| | | let newLText = Utils.formatOptions(Utils.getTableFunc(setting, menu, config)) // 创建存储过程sql |
| | | let _config = {...config, setting: setting} |
| | | let newLText = Utils.formatOptions(Utils.getTableFunc(setting, menu, _config)) // 创建存储过程sql |
| | | let DelText = Utils.formatOptions(Utils.dropfunc(setting.innerFunc)) // 删除存储过程sql |
| | | |
| | | this.refs.tableCreatFunc.exec(setting.innerFunc, newLText, DelText).then(result => { |
| | | if (result === 'success') { |
| | | this.setState({ |
| | | config: {...config, setting: setting} |
| | | config: _config |
| | | }) |
| | | } |
| | | }) |
| | |
| | | */ |
| | | setSubConfig = (btn) => { |
| | | const {menu, btnTab} = this.props |
| | | const { config, originMenu } = this.state |
| | | const { config, originMenu, activeKey } = this.state |
| | | |
| | | if (config.isAdd) { |
| | | notification.warning({ |
| | |
| | | this.setState({ |
| | | loading: true |
| | | }) |
| | | |
| | | // 保存当前打开页签 |
| | | btnTab.activeKey = activeKey |
| | | |
| | | let param = { |
| | | editMenu: menu, |
| | |
| | | } |
| | | |
| | | render () { |
| | | const { config, modaltype } = this.state |
| | | const { config, modaltype, activeKey } = this.state |
| | | let _length = config.groups.length |
| | | |
| | | let configTabs = [] |
| | |
| | | <DndProvider backend={HTML5Backend}> |
| | | {/* 工具栏 */} |
| | | <div className="tools"> |
| | | <Collapse accordion defaultActiveKey="0" bordered={false}> |
| | | <Collapse accordion defaultActiveKey={activeKey} bordered={false} onChange={(key) => this.setState({activeKey: key})}> |
| | | {/* 基本信息 */} |
| | | <Panel header={this.state.dict['header.menu.basedata']} key="0" id="common-basedata"> |
| | | <Panel forceRender={true} header={this.state.dict['header.menu.basedata']} key="0" id="common-basedata"> |
| | | {/* 菜单信息 */} |
| | | <MenuForm |
| | | dict={this.state.dict} |