SubPageHead.js 1.1 KB
import React,{PropTypes} from 'react';
import ReactDOM from 'react-dom';  
import cx from 'classnames';
import s from './header.scss'; 


class SubPageHead extends React.Component {
    constructor(props) {
        super(props); 
    }
    static propTypes = {    
        title:PropTypes.string,
        close:PropTypes.func,
        backUrl:PropTypes.string
    } 
    static defaultProps={  
        title:'员工基本信息', 
        backUrl:'#/user/hrboard/staffs', 
        close:()=>{

        }
    }  
    componentDidMount(){  
    }  
    componentWillReceiveProps(nextProps){   
    }
    componentDidUpdate(prevProps,prevState){  
    }
    componentWillUnmount() {  
        
    }  
    render(){      
        const {title,backUrl}=this.props;
        return (
            <div className={cx(s.header)} > 
                <div className={cx(s.head_back_btn)}><a  href={backUrl}><i className={cx('kr_icon')}>&#xe613;</i></a></div>
                <div className={cx(s.title_3,s.center)}><span>{title}</span></div>
            </div>
        ) 
    }
}



export default SubPageHead;