| | |
| | | import { Form, Row, Col, Input, Select, Icon, Radio, notification, Tooltip, InputNumber, Cascader } from 'antd' |
| | | import { btnIcons, btnCustomClasses, formRule } from '@/utils/option.js' |
| | | |
| | | import Api from '@/api' |
| | | import options from '@/store/options.js' |
| | | import './index.scss' |
| | | |
| | | const { TextArea } = Input |
| | |
| | | _options.push('execMode', 'intertype', 'innerFunc', 'Ot', 'execSuccess', 'execError') |
| | | } |
| | | } |
| | | } else { |
| | | } else if (_opentype === 'popview' && _opentype === 'tab') { |
| | | if (_intertype === 'outer') { |
| | | _options.push('innerFunc', 'sysInterface', 'interface', 'outerFunc', 'callbackFunc') |
| | | } else if (_intertype === 'inner') { |
| | |
| | | })( |
| | | <Cascader |
| | | options={this.state.menulist} |
| | | loadData={this.loadData} |
| | | placeholder="" |
| | | /> |
| | | )} |
| | |
| | | } |
| | | }) |
| | | return fields |
| | | } |
| | | |
| | | loadData = selectedOptions => { |
| | | const { MenuID } = this.props |
| | | const targetOption = selectedOptions[selectedOptions.length - 1] |
| | | targetOption.loading = true |
| | | |
| | | let _param = { |
| | | func: 'sPC_Get_FunMenu', |
| | | ParentID: targetOption.value, |
| | | systemType: options.sysType, |
| | | debug: 'Y' |
| | | } |
| | | |
| | | Api.getSystemConfig(_param).then(result => { |
| | | if (result.status) { |
| | | targetOption.loading = false |
| | | targetOption.children = result.data.map(item => { |
| | | let submenu = { |
| | | value: item.ParentID, |
| | | label: item.MenuNameP, |
| | | children: item.FunMenu.map(cell => { |
| | | return { |
| | | value: cell.MenuID, |
| | | label: cell.MenuName, |
| | | MenuID: cell.MenuID, |
| | | MenuName: cell.MenuName, |
| | | MenuNo: cell.MenuNo, |
| | | Ot: cell.Ot, |
| | | PageParam: cell.PageParam, |
| | | LinkUrl: cell.LinkUrl, |
| | | disabled: cell.MenuID === MenuID |
| | | } |
| | | }) |
| | | } |
| | | |
| | | return submenu |
| | | }) |
| | | |
| | | this.setState({ |
| | | menulist: [...this.state.menulist] |
| | | }) |
| | | } else { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: result.message, |
| | | duration: 5 |
| | | }) |
| | | targetOption.loading = false |
| | | } |
| | | }) |
| | | } |
| | | |
| | | handleConfirm = () => { |