From 34d7d5c9db44ad347fc015f17b0160ecfbd91df4 Mon Sep 17 00:00:00 2001 From: zx <604444282@qq.com> Date: Tue, 11 Jan 2022 11:00:48 +0800 Subject: [PATCH] zx --- src/components/v-echars/index.vue | 16 +++++++++++++--- src/views/BrandInsight/titsopo/index.vue | 16 +++++++++++----- src/views/BrandInsight/titsopo/opt.js | 10 +++++++++- 3 files changed, 33 insertions(+), 9 deletions(-) diff --git a/src/components/v-echars/index.vue b/src/components/v-echars/index.vue index fe62346..3be21bf 100644 --- a/src/components/v-echars/index.vue +++ b/src/components/v-echars/index.vue @@ -50,10 +50,19 @@ export default { } this.$emit("getData", o); } - }) + if(params.componentType === 'markPoint') { + let o = { + key: params.data.name, + value: params.value, + mark: params.componentType + } + this.$emit("getData", o); + } + }); // this.myChart.off("click"); // 给图像加点击事件 - this.myChart.getZr().on("click", (params) => { + + this.myChart.getZr().on("dblclick", (params) => { //param.name x轴值,param.data y轴值 let pointInPixel = [params.offsetX, params.offsetY]; if ( @@ -75,8 +84,9 @@ export default { if(ex && ex.componentSubType === 'line') { this.$emit("getData", obj); } - } + }; }); + // 将鼠标变成小手 this.myChart.getZr().on("mousemove", () => { this.myChart.getZr().setCursorStyle("pointer"); diff --git a/src/views/BrandInsight/titsopo/index.vue b/src/views/BrandInsight/titsopo/index.vue index 847a84c..dbb4262 100644 --- a/src/views/BrandInsight/titsopo/index.vue +++ b/src/views/BrandInsight/titsopo/index.vue @@ -15,7 +15,7 @@