| | |
| | | data: '', |
| | | tempId: '', |
| | | config: null, |
| | | urlParam: null, |
| | | auto: true |
| | | } |
| | | |
| | |
| | | sessionStorage.setItem('localDataM', param.dataM || '') |
| | | this.setState({ |
| | | BID: param.id || '', |
| | | tempId: param.tempId |
| | | tempId: param.tempId, |
| | | urlParam: param |
| | | }, () => { |
| | | this.getMenuParam() |
| | | }) |
| | |
| | | } |
| | | |
| | | getMenuParam = () => { |
| | | const { tempId, BID } = this.state |
| | | const { tempId, BID, urlParam } = this.state |
| | | |
| | | let _param = { |
| | | func: 'sPC_Get_LongParam', |
| | |
| | | }) |
| | | } |
| | | |
| | | if (config.urlFields) { |
| | | config.urlFields.forEach(field => { |
| | | let val = `'${urlParam ? (urlParam[field] || '') : ''}'` |
| | | regs.push({ |
| | | reg: new RegExp('@' + field + '@', 'ig'), |
| | | value: val |
| | | }) |
| | | }) |
| | | } |
| | | |
| | | config.components = config.components.map(component => { |
| | | if (component.action) component.action = [] |
| | | if (component.search) component.search = [] |