fix: 修复 table 分页问题

This commit is contained in:
@changcode
2022-04-28 10:51:54 +08:00
parent 27656d5eb9
commit 31ef8a276b
2 changed files with 4 additions and 4 deletions

View File

@@ -400,9 +400,9 @@ export default {
const dateRangeValue = 60
const { startTime, endTime } = getNowTime(dateRangeValue)
const chartTimeFilter = ref({ startTime, endTime, dateRangeValue })
let table = {}
let table = ref( '')
if (isBasicTable(props.chartInfo.type)) {
table = {
table.value = {
pageSize: chartTableDefaultPageSize,
limit: chartTableTopOptions[0], // top-n
orderBy: props.chartInfo.params.columns.order[0],

View File

@@ -155,7 +155,7 @@ export default {
})
}, 100)
},
chartHeightData (e) {
changeChartRowHeight (e) {
const width = e.currentTarget.innerWidth
if (width < 1440) {
this.rowHeight = 25
@@ -169,7 +169,7 @@ export default {
}
},
mounted () {
this.debounceFunc = this.$_.debounce(this.chartHeightData, 100)
this.debounceFunc = this.$_.debounce(this.changeChartRowHeight, 100)
window.addEventListener('resize', this.debounceFunc)
},
beforeUnmount () {