NEZ-2614 fix:project topology bug 修改

This commit is contained in:
zhangyu
2023-03-01 17:21:29 +08:00
parent ddd15b0572
commit fbb6f8de9f
5 changed files with 10 additions and 5 deletions

View File

@@ -3,6 +3,7 @@
:class="legendPlacement" :class="legendPlacement"
class="nz-chart__component nz-chart__component--time-series" @mouseenter="mouseEnterChart" class="nz-chart__component nz-chart__component--time-series" @mouseenter="mouseEnterChart"
@mouseleave="mouseLeaveChart" @mouseleave="mouseLeaveChart"
v-my-loading="chartLoading"
> >
<div class="chart__canvas" style="position:relative"> <div class="chart__canvas" style="position:relative">
<div :id="`chart-canvas-${chartId}`"></div> <div :id="`chart-canvas-${chartId}`"></div>
@@ -52,7 +53,8 @@ export default {
stackTotalColor: null, stackTotalColor: null,
stackTotalColorRight: null, stackTotalColorRight: null,
isStack: false, isStack: false,
hasRightYAxis: false hasRightYAxis: false,
chartLoading: false
} }
}, },
computed: { computed: {
@@ -197,6 +199,7 @@ export default {
} }
}) })
} }
this.chartLoading = false
this.isInit = false this.isInit = false
}, 200) }, 200)
}, },

View File

@@ -218,7 +218,6 @@ export default {
this.timer3 = null this.timer3 = null
} }
this.position.show = false this.position.show = false
console.log(pen)
if (!pen.type && pen.data.enable.tooltip) { if (!pen.type && pen.data.enable.tooltip) {
if (!pen.data.tooltip.legends.length) { if (!pen.data.tooltip.legends.length) {
return return
@@ -230,7 +229,7 @@ export default {
} }
}) })
if (!positionShow) { if (!positionShow) {
return; return
} }
this.chartParams = { this.chartParams = {
...pen.data.tooltip, ...pen.data.tooltip,
@@ -259,6 +258,7 @@ export default {
boxHeight = null boxHeight = null
}) })
this.position.show = true this.position.show = true
// this.$refs.meta2dTooltip.$refs.panelChart && (this.$refs.meta2dTooltip.$refs.panelChart.loading = false)
clearTimeout(this.timer3) clearTimeout(this.timer3)
}, 100) }, 100)
} }

View File

@@ -202,7 +202,7 @@
@blur="inputBlur" @blur="inputBlur"
:step="1" :step="1"
:min="0" :min="0"
:precision="0" :precision="1"
controls-position="right" controls-position="right"
size="small" size="small"
name="globalAlpha" name="globalAlpha"

View File

@@ -36,6 +36,7 @@
}" }"
> >
<meta2dTooltip <meta2dTooltip
ref="meta2dTooltip"
:params="chartParams" :params="chartParams"
/> />
</div> </div>

View File

@@ -85,6 +85,7 @@ export default {
this.$refs.panelChart.chartData = chartData this.$refs.panelChart.chartData = chartData
this.$refs.panelChart.loading = false this.$refs.panelChart.loading = false
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.panelChart.$refs.chart.$refs['chart' + this.chartInfo.id].chartLoading = true
this.$refs.panelChart.$refs.chart.$refs['chart' + this.chartInfo.id].initChart() this.$refs.panelChart.$refs.chart.$refs['chart' + this.chartInfo.id].initChart()
this.$refs.panelChart.$refs.chart.$refs['chart' + this.chartInfo.id].resize() this.$refs.panelChart.$refs.chart.$refs['chart' + this.chartInfo.id].resize()
}) })