| | |
| | | } |
| | | } |
| | | |
| | | getSyncData = (syncModule, btnId) => { |
| | | const { config, selectedData } = this.state |
| | | |
| | | if (config.uuid !== syncModule) return |
| | | |
| | | MKEmitter.emit('triggerBtnId', btnId, (selectedData || [])) |
| | | } |
| | | |
| | | UNSAFE_componentWillReceiveProps(nextProps) { |
| | | const { sync, config, BID } = this.state |
| | | |
| | |
| | | |
| | | componentDidMount () { |
| | | MKEmitter.addListener('reloadData', this.reloadData) |
| | | MKEmitter.addListener('getSyncData', this.getSyncData) |
| | | MKEmitter.addListener('resetSelectLine', this.resetParentParam) |
| | | MKEmitter.addListener('queryModuleParam', this.queryModuleParam) |
| | | MKEmitter.addListener('refreshByButtonResult', this.refreshByButtonResult) |
| | |
| | | return |
| | | } |
| | | MKEmitter.removeListener('reloadData', this.reloadData) |
| | | MKEmitter.removeListener('getSyncData', this.getSyncData) |
| | | MKEmitter.removeListener('resetSelectLine', this.resetParentParam) |
| | | MKEmitter.removeListener('queryModuleParam', this.queryModuleParam) |
| | | MKEmitter.removeListener('refreshByButtonResult', this.refreshByButtonResult) |