| | |
| | | |
| | | componentDidMount () { |
| | | MKEmitter.addListener('plusSearch', this.plusSearch) |
| | | // MKEmitter.addListener('revert', this.revert) |
| | | MKEmitter.addListener('revert', this.revert) |
| | | } |
| | | |
| | | // revert = () => { |
| | | // this.setState({searchlist: fromJS(this.props.config.search).toJS()}) |
| | | // } |
| | | // dms-trans |
| | | revert = (id, type) => { |
| | | if (id !== this.props.config.uuid || type !== 'search') return |
| | | |
| | | this.setState({searchlist: fromJS(this.props.config.search).toJS()}) |
| | | } |
| | | |
| | | plusSearch = (MenuId, item, type) => { |
| | | const { config } = this.props |
| | |
| | | this.setState = () => { |
| | | return |
| | | } |
| | | // MKEmitter.removeListener('revert', this.revert) |
| | | MKEmitter.removeListener('revert', this.revert) |
| | | MKEmitter.removeListener('plusSearch', this.plusSearch) |
| | | } |
| | | |