import {
	WeaTop,
	WeaRightMenu,
} from 'ecCom';
import {
	observer
} from 'mobx-react';
import Table from './Table';
import Search from './Search';

@observer
export default class Top extends React.Component {
	constructor(props) {
		super(props);
	}

	render() {
		const {
			store
		} = this.props, {
			TOP,
			top,
			topButtons,
			dropMenuDatas
		} = store;

		return (
			<WeaTop ecId={`${this && this.props && this.props.ecId || ''}_WeaTop@8rs7ky`} 
               {...TOP}
               {...top}
               buttons={topButtons}
               dropMenuDatas={dropMenuDatas}
            >
            	<WeaRightMenu ecId={`${this && this.props && this.props.ecId || ''}_WeaRightMenu@ohdsk2`} datas={dropMenuDatas}>
            		<Search ecId={`${this && this.props && this.props.ecId || ''}_Search@xys11o`} store={store}/>
            		<Table ecId={`${this && this.props && this.props.ecId || ''}_Table@t9rsn2`} store={store}/>
            	</WeaRightMenu>
            </WeaTop>
		);
	}
}