diff --git a/core/frontend/src/views/chart/view/ChartEdit.vue b/core/frontend/src/views/chart/view/ChartEdit.vue index 60a7f1637c..0fa7b8e4d4 100644 --- a/core/frontend/src/views/chart/view/ChartEdit.vue +++ b/core/frontend/src/views/chart/view/ChartEdit.vue @@ -2175,6 +2175,12 @@ export default { x.sort = 'none' }) } + if ((newVal.type !== 'scatter' || newVal.type === 'scatter' && newVal.render === 'echarts') && (oldVal.type === 'scatter' && oldVal.render === 'antv')) { + // 针对横轴内有指标的情况 + if (this.view.xaxis && this.view.xaxis.length > 0 && this.view.xaxis[0] && this.view.xaxis[0].groupType === 'q') { + this.view.xaxis = [] + } + } if (newVal.type !== oldVal.type || newVal.render !== oldVal.render) { this.setChartDefaultOptions() this.calcData(true, 'chart', true, newVal.type !== oldVal.type, newVal.render !== oldVal.render)