import { inject, observer } from 'mobx-react' import { WeaTab } from 'ecCom' @inject('hrmApplicant') //todo @observer export default class Tab extends React.Component { constructor(props) { super(props); } componentDidMount() { const { hrmApplicant } = this.props, { mainDialog } = hrmApplicant, { type } = mainDialog; type != 'more' && this.props.hrmApplicant.getSearchCondition(); } componentWillUnmount() { this.props.hrmApplicant.resetTab(); } render() { const { hrmApplicant } = this.props, { tab, buttonsAd, changePanelStatus, searchsAd, handleSearch, mainDialog, setSearchBaseValue, } = hrmApplicant, { isPanelShow, conditionCount, form, searchBaseValue, } = tab, { type } = mainDialog; return ( changePanelStatus(b)} hideSearchAd={ () => changePanelStatus(false)} searchsAd= {searchsAd} onSearch={() => handleSearch()} onSearchChange={val => {type=='more' ? setSearchBaseValue(val) : form.updateFields({name: val})}} /> ) } }