修复生产监控分页和设备监控筛选
Some checks failed
Release pipeline / publish (push) Has been cancelled
Release pipeline / Always run job (push) Has been cancelled

This commit is contained in:
sheng
2026-06-25 00:49:52 +08:00
parent 22ccc9c219
commit c2db61dad9
5 changed files with 131 additions and 8 deletions

View File

@@ -169,9 +169,9 @@
-->
<div ref="footer" class="page-table__footer" v-if="pagination">
<el-pagination
:current-page="pagination.current"
:page-size="pagination.size || 10"
:total="pagination.total"
:current-page="paginationCurrent"
:page-size="paginationSize"
:total="paginationTotal"
:page-sizes="[10, 25, 50, 100, 250, 500]"
:disabled="loading"
layout="total, sizes, prev, pager, next, jumper"
@@ -361,6 +361,21 @@ export default {
return this.tableSelected.length
},
paginationCurrent () {
if (!this.pagination) return 1
return Number(this.pagination.current || this.pagination.currentPage || 1)
},
paginationSize () {
if (!this.pagination) return 10
return Number(this.pagination.size || this.pagination.pageSize || 10)
},
paginationTotal () {
if (!this.pagination) return 0
return Number(this.pagination.total || 0)
},
/**
* 表头样式:浅灰背景 + 黑色加粗文字
*/
@@ -424,16 +439,20 @@ export default {
onSizeChange (size) {
this.$emit('page-change', {
current: 1,
currentPage: 1,
size,
total: this.pagination.total
pageSize: size,
total: this.paginationTotal
})
},
onCurrentChange (current) {
this.$emit('page-change', {
current,
size: this.pagination.size,
total: this.pagination.total
currentPage: current,
size: this.paginationSize,
pageSize: this.paginationSize,
total: this.paginationTotal
})
},