Browse Source

fix:[情绪探底雷达]去除控制台输出、销毁图表

aiEmotion
yangchunyan 4 weeks ago
parent
commit
38d23e4beb
  1. 11
      src/views/components/emotionalBottomRadar.vue

11
src/views/components/emotionalBottomRadar.vue

@ -6,10 +6,10 @@
import { ref } from 'vue'
import * as echarts from 'echarts'
const bottomRadarRef = ref(null)
let bottomRadarChart = null
function initEmotionalBottomRadar(KlineData, barAndLineData) {
console.log('KlineData, barAndLineData---', KlineData, barAndLineData)
let bottomRadarChartDom = document.getElementById('bottomRadarChart')
let bottomRadarChart = echarts.init(bottomRadarChartDom)
bottomRadarChart = echarts.init(bottomRadarChartDom)
// -x
let dateArray = KlineData.map(subArray => subArray[0])
@ -543,6 +543,13 @@ function initEmotionalBottomRadar(KlineData, barAndLineData) {
defineExpose({
initEmotionalBottomRadar
})
onBeforeUnmount(() => {
//
if (bottomRadarChart) {
bottomRadarChart.dispose()
}
})
</script>
<style>

Loading…
Cancel
Save