import React from 'react' import { inject, observer } from 'mobx-react' import { WeaAlertPage, WeaLocaleProvider } from 'ecCom' import { Spin } from 'antd' import Top from './Top'; import MainDialog from './MainDialog'; const getLabel = WeaLocaleProvider.getLabel; @inject('hrmApplicant') //todo @observer export default class Applicant extends React.Component { //todo constructor(props) { super(props); } componentWillMount() { if (window.location.href.indexOf('/spa/hrm/engine.html') > -1) { document.title = getLabel('391168', "应聘人员"); } } componentWillReceiveProps(nextProps) { if (this.props.location && (this.props.location.key !== nextProps.location.key)) { this.props.hrmApplicant.refresh(); } } componentDidMount() { this.init(); } init() { const { hrmApplicant } = this.props, { getAuth, onresize } = hrmApplicant; getAuth(); window.addEventListener('resize', onresize); } componentWillUnmount() { const { hrmApplicant } = this.props, { onresize } = hrmApplicant; window.removeEventListener('resize', onresize); } render() { const { hrmApplicant } = this.props, { main, } = hrmApplicant, { loading, authorized } = main; if (!authorized) { return (