index.tsx
1.87 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
import { EllipsisOutlined } from '@ant-design/icons';
import { PageContainer, ProCard } from '@ant-design/pro-components';
import { Avatar, Button, Dropdown, Space, Tag } from 'antd';
import OrderDualAxes from './components/OrderDualAxes';
import OrderStatisticCard from './components/OrderStatisticCard';
import OrderStatisticSearch from './components/OrderStatisticSearch';
const userInfo = JSON.parse(localStorage.getItem('userInfo'));
const OrderReportPage = () => {
return (
<PageContainer
className="order-page-container"
header={{
title: '订单汇总',
extra: [
<Avatar key="0" style={{ verticalAlign: 'middle' }} size="large">
{userInfo?.username}
</Avatar>,
<Tag key="nickName">{userInfo?.nickName}</Tag>,
<Dropdown
key="dropdown"
trigger={['click']}
menu={{
items: [
{
label: '退出登录',
key: '1',
onClick: () => {
localStorage.removeItem('token');
history.push('/login');
},
},
// {
// label: '修改密码',
// key: '2',
// },
],
}}
>
<Button key="4" style={{ padding: '0 8px' }}>
<EllipsisOutlined />
</Button>
</Dropdown>,
],
}}
>
<Space direction="vertical" size="middle" className="flex">
<OrderStatisticCard />
<ProCard tooltip="这是提示" bordered>
<OrderStatisticSearch />
</ProCard>
<ProCard title="带卡片阴影" extra="extra" tooltip="这是提示" bordered>
<OrderDualAxes />
</ProCard>
</Space>
</PageContainer>
);
};
export default OrderReportPage;