From 3f2264decb491297837210eebb56474e1366482a Mon Sep 17 00:00:00 2001 From: wisonic-s Date: Sun, 7 Apr 2024 18:59:07 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E5=9B=BE=E8=A1=A8):=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E5=9C=B0=E5=9B=BE=E4=BB=8E=E4=B8=96=E7=95=8C=E4=B8=8B=E9=92=BB?= =?UTF-8?q?=E5=88=B0=E5=9B=BD=E5=AE=B6=E6=98=BE=E7=A4=BA=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../views/components/ChartComponentG2Plot.vue | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/core/core-frontend/src/views/chart/components/views/components/ChartComponentG2Plot.vue b/core/core-frontend/src/views/chart/components/views/components/ChartComponentG2Plot.vue index 39b125fb80..85abab443b 100644 --- a/core/core-frontend/src/views/chart/components/views/components/ChartComponentG2Plot.vue +++ b/core/core-frontend/src/views/chart/components/views/components/ChartComponentG2Plot.vue @@ -151,12 +151,18 @@ const appStore = useAppStoreWithOut() const isDataEaseBi = computed(() => appStore.getIsDataEaseBi) const chartContainer = ref(null) let mapTimer: number -const renderL7Plot = async (chart, chartView: L7PlotChartView, callback) => { +const renderL7Plot = async (chart: ChartObj, chartView: L7PlotChartView, callback) => { const map = parseJson(chart.customAttr).map let areaId = map.id country.value = areaId.slice(0, 3) if (dynamicAreaId.value) { - areaId = dynamicAreaId.value + // 世界下钻到国家,切换路径 + if (country.value === '000' && dynamicAreaId.value.startsWith('000')) { + country.value = dynamicAreaId.value.slice(3) + areaId = country.value + } else { + areaId = dynamicAreaId.value + } } mapTimer && clearTimeout(mapTimer) mapTimer = setTimeout(async () => {