diff --git a/sgzb-screen/src/components/home/materialAnalysisDialog.vue b/sgzb-screen/src/components/home/materialAnalysisDialog.vue new file mode 100644 index 00000000..37c5cdd2 --- /dev/null +++ b/sgzb-screen/src/components/home/materialAnalysisDialog.vue @@ -0,0 +1,201 @@ + + + + + \ No newline at end of file diff --git a/sgzb-screen/src/components/home/rightOne.vue b/sgzb-screen/src/components/home/rightOne.vue index 47bf367d..5c000fc8 100644 --- a/sgzb-screen/src/components/home/rightOne.vue +++ b/sgzb-screen/src/components/home/rightOne.vue @@ -10,6 +10,7 @@
+ @@ -25,7 +26,12 @@ import * as echarts from 'echarts'; import 'echarts-gl' // 3d图表库 import { getPickingAnalysisByMonthApi } from "../../api/screen"; +import materialAnalysisDialog from "./materialAnalysisDialog"; + export default { + components: { + materialAnalysisDialog + }, data() { return { data: [], @@ -421,6 +427,11 @@ export default { if (option && typeof option === "object") { myChart.setOption(option); } + myChart.off('click'); + myChart.on('click', (params) => { + console.log('🚀 ~ myChart.on ~ params:', params); + this.$refs.materialAnalysisDialog.setOpen({open: true, maType: this.maType}) + }); }, }, }; @@ -428,7 +439,7 @@ export default {