import ProCard from '@ant-design/pro-card';
import { PageHeaderWrapper } from '@ant-design/pro-layout';
import AdminPage from './components/AdminPage';
import BasicPage from './components/BasicPage';
export default (props) => {
  const { history } = props;
  const { id } = history.location.query;
  return (
    <PageHeaderWrapper>
      <ProCard tabs={{ type: 'card' }} style={{ minHeight: '700px' }}>
        <ProCard.TabPane key={1} tab="基本信息">
          <BasicPage id={id} />
        </ProCard.TabPane>
        <ProCard.TabPane disabled={!id} key={2} tab='管理员'>
          <AdminPage id={id} />
        </ProCard.TabPane>
      </ProCard>
    </PageHeaderWrapper>
  )
}