Skip to content

Commit a5eaf84

Browse files
kokorolisendya
authored andcommitted
fix: s-table pagination #285
1 parent 0dce4f8 commit a5eaf84

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/components/Table/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ export default {
172172
// 这里用于判断接口是否有返回 r.totalCount 且 this.showPagination = true 且 pageNo 和 pageSize 存在 且 totalCount 小于等于 pageNo * pageSize 的大小
173173
// 当情况满足时,表示数据不满足分页大小,关闭 table 分页功能
174174
try {
175-
if ((['auto', true].includes(this.showPagination) && r.totalCount <= (r.pageNo * pagination.pageSize))) {
175+
if ((['auto', true].includes(this.showPagination) && r.totalCount <= (r.pageNo * this.localPagination.pageSize))) {
176176
this.localPagination.hideOnSinglePage = true
177177
}
178178
} catch (e) {

src/views/list/TableList.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@
8484
:data="loadData"
8585
:alert="options.alert"
8686
:rowSelection="options.rowSelection"
87-
:show-pagination="false"
87+
showPagination="auto"
8888
>
8989
<span slot="serial" slot-scope="text, record, index">
9090
{{ index + 1 }}

0 commit comments

Comments
 (0)