From f868ff46ef4fb25a01364f3c5d0fe220d32b7ad0 Mon Sep 17 00:00:00 2001 From: whyczyk <525500596@qq.com> Date: 星期二, 01 三月 2022 14:25:16 +0800 Subject: [PATCH] 大屏对接新平台 --- src/components/charts/chinaMap.vue | 12 +++++++++--- 1 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/components/charts/chinaMap.vue b/src/components/charts/chinaMap.vue index 83e625d..e18a559 100644 --- a/src/components/charts/chinaMap.vue +++ b/src/components/charts/chinaMap.vue @@ -1,5 +1,6 @@ <template> - <div class="echarts-wrapper" @dblclick="dblclick"> + <new-china-map v-if="newPlatform==1"></new-china-map> + <div class="echarts-wrapper" @dblclick="dblclick" v-else> <div class="echarts-content" ref="chart" id="cityChart"> </div> @@ -43,6 +44,7 @@ // 鏀剧數鍥炬爣 import HomeDischargeImage from '@/assets/images/home-discharge.png'; import InfoPanel from '../indexPanel/InfoPanel.vue'; +import newChinaMap from './newChinaMap.vue'; let homeDischargeImage = new Image(); homeDischargeImage.src = HomeDischargeImage; let chartData = []; //chart鏁版嵁 @@ -51,12 +53,13 @@ let chart, chartLng, chartLat; export default { - components: { InfoPanel }, + components: { InfoPanel, newChinaMap }, name: "chinaMap", chart: "", chartData: "", data() { return { + newPlatform: 0, parentsStyle: {}, isAllScreen: false, timers: null, @@ -128,7 +131,9 @@ this.organizeData(sendData) } else { // 鍒濆鍖栭〉闈� - this.getAllMapOutlineAction(); + this.$nextTick(() => { + this.getAllMapOutlineAction(); + }) } }, organizeData(data) { @@ -570,6 +575,7 @@ this.mapInfoY = poit[1] - 190; }, 300); }); + this.newPlatform = sessionStorage.getItem('newPlatform') }, destroyed() { window.removeEventListener('resize', this.resize); -- Gitblit v1.9.1