fix(视图): 修复 AntV 表格表头排序后点击获取的单元格数据错误 #8888

This commit is contained in:
wisonic-s 2024-04-03 15:21:32 +08:00
parent 4eb351f281
commit 590ce08afd

View File

@ -331,11 +331,8 @@ export default {
if (this.chart.type === 'table-pivot') { if (this.chart.type === 'table-pivot') {
rowData = { ...meta.rowQuery, ...meta.colQuery } rowData = { ...meta.rowQuery, ...meta.colQuery }
rowData[meta.valueField] = meta.fieldValue rowData[meta.valueField] = meta.fieldValue
} else if (this.showPage && (this.chart.datasetMode === 1 || (this.chart.datasetMode === 0 && this.not_support_page_dataset.includes(this.chart.datasourceType)))) {
const rowIndex = (this.currentPage.page - 1) * this.currentPage.pageSize + meta.rowIndex
rowData = this.chart.data.tableRow[rowIndex]
} else { } else {
rowData = this.chart.data.tableRow[meta.rowIndex] rowData = this.myChart.dataSet.getRowData(meta)
} }
const dimensionList = [] const dimensionList = []
for (const key in rowData) { for (const key in rowData) {