You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
363 B
Markdown
25 lines
363 B
Markdown
9 years ago
|
# 总数
|
||
|
|
||
|
- order: 9
|
||
|
|
||
|
通过设置 `showTotal` 展示总共有多少数据。
|
||
|
|
||
|
---
|
||
|
|
||
|
````jsx
|
||
|
import { Pagination, Select } from 'antd';
|
||
|
|
||
|
function showTotal(total) {
|
||
|
return `共 ${total} 条`;
|
||
|
}
|
||
|
|
||
|
ReactDOM.render(
|
||
|
<Pagination
|
||
|
selectComponentClass={Select}
|
||
|
total={80}
|
||
|
showTotal={showTotal}
|
||
|
pageSize={20} defaultCurrent={1} />,
|
||
|
mountNode
|
||
|
);
|
||
|
````
|