feat: 更换Pagination组件

This commit is contained in:
renxiaodong
2025-09-04 23:30:41 +08:00
parent 3f5249c731
commit 8b42a67e9f
21 changed files with 183 additions and 215 deletions

View File

@ -35,16 +35,15 @@
@selectionChange="handleSelectionChange"
/>
<div v-if="pageInfo.total > 0" class="pagination-row">
<a-pagination
<Pagination
:total="pageInfo.total"
size="mini"
show-total
show-jumper
show-page-size
size="small"
:showTotal="(total, range) => `共 ${total} 条`"
showSizeChanger
showQuickJumper
:current="pageInfo.page"
:page-size="pageInfo.page_size"
:pageSize="pageInfo.page_size"
@change="onPageChange"
@page-size-change="onPageSizeChange"
/>
</div>
</div>
@ -54,7 +53,7 @@
</template>
<script setup>
import { Button, Tabs } from 'ant-design-vue';
import { Button, Tabs, Pagination } from 'ant-design-vue';
const { TabPane } = Tabs;
import FilterBlock from './components/filter-block';
import BoardTable from './components/board-table';
@ -113,8 +112,9 @@ const getData = async () => {
}
};
const onPageChange = (current) => {
const onPageChange = (current, pageSize) => {
pageInfo.value.page = current;
pageInfo.value.page_size = pageSize;
getData();
};