Commit 1e32cb258181635e7d8952631f803018b6d6186e

Authored by fengwotao
1 parent 963e08ac

feat(src/packages): 图表地图新增echarts gl 3d地图

... ... @@ -30,6 +30,7 @@
30 30 "crypto-js": "^4.1.1",
31 31 "dayjs": "^1.11.7",
32 32 "dom-helpers": "^5.2.1",
  33 + "echarts-gl": "^2.0.9",
33 34 "echarts-liquidfill": "^3.1.0",
34 35 "echarts-stat": "^1.2.0",
35 36 "echarts-wordcloud": "^2.0.0",
... ...
  1 +<script lang="ts" setup name="SelectCity">
  2 +import { onMounted, reactive } from 'vue'
  3 +import { getAreaList } from '@/api/external/common/index'
  4 +import { areaEnum } from '../config'
  5 +
  6 +const props = defineProps({
  7 + drillingIn: {
  8 + type: Boolean,
  9 + default: false
  10 + },
  11 + optionData: {
  12 + type: Object
  13 + }
  14 +})
  15 +
  16 +const emits = defineEmits(['submit'])
  17 +
  18 +const selectOptions = reactive({
  19 + provinceOptions: [],
  20 + cityOptions: [],
  21 + countryOptions: []
  22 +})
  23 +
  24 +const selectValues = reactive({
  25 + provinceValue: 'china',
  26 + cityValue: null,
  27 + countyValue: null
  28 +})
  29 +
  30 +const getAreaLists = async (level = areaEnum.PROVINCE, parentId = 1) => {
  31 + const resp = await getAreaList({
  32 + level,
  33 + parentId
  34 + })
  35 + if (!resp) return []
  36 + return resp.map((item: any) => ({ label: item.name, value: item.code }))
  37 +}
  38 +
  39 +onMounted(async () => {
  40 + selectOptions.provinceOptions = await getAreaLists()
  41 + ;(selectOptions.provinceOptions as never as any).unshift({
  42 + label: '中国',
  43 + value: 'china'
  44 + })
  45 + onHandleSelectProvince(props.optionData?.mapRegion.saveSelect['provinceValue'])
  46 + for (let i in selectValues) Reflect.set(selectValues, i, props.optionData?.mapRegion.saveSelect[i])
  47 +})
  48 +
  49 +const onHandleSelectProvince = async (value: number | string) => {
  50 + selectValues.cityValue = null
  51 + selectValues.countyValue = null
  52 + if (value === 'china') return
  53 + selectOptions.cityOptions = await getAreaLists(areaEnum.CITY, value as any)
  54 +}
  55 +
  56 +const onHandleSelectCity = async (value: number) => {
  57 + selectValues.countyValue = null
  58 + selectOptions.countryOptions = await getAreaLists(areaEnum.COUNTY, value)
  59 +}
  60 +
  61 +const onHandleSubmit = () => {
  62 + emits('submit', selectValues)
  63 +}
  64 +</script>
  65 +
  66 +<template>
  67 + <div class="select-city-content">
  68 + <n-select
  69 + @change="onHandleSelectProvince"
  70 + placeholder="请选择省份"
  71 + v-model:value="selectValues.provinceValue"
  72 + :options="selectOptions.provinceOptions"
  73 + />
  74 + <n-select
  75 + v-if="!props.drillingIn"
  76 + @change="onHandleSelectCity"
  77 + placeholder="请选择城市"
  78 + v-model:value="selectValues.cityValue"
  79 + :options="selectOptions.cityOptions"
  80 + />
  81 + <!-- 保留待用(下钻到区以下) -->
  82 + <!-- <n-select
  83 + v-if="!drillingIn"
  84 + placeholder="请选择区域"
  85 + v-model:value="selectValues.countyValue"
  86 + :options="selectOptions.countryOptions"
  87 + /> -->
  88 + <n-button type="primary" @click="onHandleSubmit">确定</n-button>
  89 + </div>
  90 +</template>
  91 +
  92 +<style lang="scss" scoped>
  93 +.select-city-content {
  94 + display: flex;
  95 + flex-direction: column;
  96 + justify-content: space-between;
  97 + align-items: center;
  98 + gap: 30px;
  99 +}
  100 +</style>
... ...
  1 +import { echartOptionProfixHandle, PublicConfigClass } from '@/packages/public'
  2 +import { AddThreeDimensionalMapConfig } from './index'
  3 +import { chartInitConfig } from '@/settings/designSetting'
  4 +import { CreateComponentType } from '@/packages/index.d'
  5 +import cloneDeep from 'lodash/cloneDeep'
  6 +import { dataMaps } from './mock'
  7 +
  8 +//省市区枚举
  9 +export const enum areaEnum {
  10 + PROVINCE = 'PROVINCE',
  11 + CITY = 'CITY',
  12 + COUNTY = 'COUNTY'
  13 +}
  14 +
  15 +export const includes = []
  16 +
  17 +export const option = {
  18 + iconColor: 'black',
  19 + showIcon: false,
  20 + iconDistanceRight: 20,
  21 + iconDistanceTop: 20,
  22 + drillingIn: false,
  23 + mapRegion: {
  24 + adcode: 'china',
  25 + showHainanIsLands: true,
  26 + saveSelect: {}
  27 + },
  28 + tooltip: {
  29 + show: true
  30 + },
  31 + geo3D: {
  32 + map: 'centerMap',
  33 + roam: true,
  34 + regionHeight: 0,
  35 + },
  36 + series: [
  37 + {
  38 + type: 'map3D',
  39 + map: 'centerMap',
  40 + itemStyle: {
  41 + color: 'red',
  42 + borderWidth: 0.8,
  43 + borderColor: 'green'
  44 + },
  45 + data: []
  46 + }
  47 + ]
  48 +}
  49 +export const MapDefaultConfig = { ...option }
  50 +export default class Config extends PublicConfigClass implements CreateComponentType {
  51 + public key: string = AddThreeDimensionalMapConfig.key
  52 + public attr = { ...chartInitConfig, w: 750, h: 800, zIndex: -1 }
  53 + public chartConfig = cloneDeep(AddThreeDimensionalMapConfig)
  54 + public option = echartOptionProfixHandle(option, includes)
  55 +}
... ...
  1 +<template>
  2 + <!-- Echarts 全局设置 -->
  3 + <global-setting :optionData="optionData"></global-setting>
  4 + <CollapseItem name="地图" :expanded="true">
  5 + <!-- <SettingItemBox name="开启下钻">
  6 + <SettingItem name="">
  7 + <n-switch v-model:value="optionData.drillingIn" size="small"></n-switch>
  8 + </SettingItem>
  9 + </SettingItemBox>
  10 + <SettingItemBox name="返回图标">
  11 + <SettingItem name="">
  12 + <n-switch v-model:value="optionData.drillingIn" size="small"></n-switch>
  13 + </SettingItem>
  14 + </SettingItemBox>
  15 + <SettingItemBox name="图标颜色">
  16 + <SettingItem name="">
  17 + <n-color-picker size="small" :modes="['hex']" v-model:value="optionData.iconColor"></n-color-picker>
  18 + </SettingItem>
  19 + </SettingItemBox>
  20 + <SettingItemBox name="图标距离">
  21 + <SettingItem name="距右">
  22 + <n-input-number
  23 + v-model:value="optionData.iconDistanceRight"
  24 + :min="1"
  25 + size="small"
  26 + placeholder="请输入"
  27 + ></n-input-number>
  28 + </SettingItem>
  29 + <SettingItem name="距上">
  30 + <n-input-number
  31 + v-model:value="optionData.iconDistanceTop"
  32 + :min="1"
  33 + size="small"
  34 + placeholder="请输入"
  35 + ></n-input-number>
  36 + </SettingItem>
  37 + </SettingItemBox> -->
  38 + <SelectCity :optionData="optionData" :drillingIn="optionData.drillingIn" @submit="onHandleSelectValues" />
  39 + <SettingItemBox name="颜色">
  40 + <SettingItem name="区域颜色">
  41 + <n-color-picker size="small" :modes="['hex']" v-model:value="seriesList[0].itemStyle.color"></n-color-picker>
  42 + </SettingItem>
  43 + <SettingItem name="边框颜色">
  44 + <n-color-picker
  45 + size="small"
  46 + :modes="['hex']"
  47 + v-model:value="seriesList[0].itemStyle.borderColor"
  48 + ></n-color-picker>
  49 + </SettingItem>
  50 + <SettingItem name="边框大小">
  51 + <n-input-number
  52 + v-model:value="seriesList[0].itemStyle.borderWidth"
  53 + :min="0"
  54 + size="small"
  55 + placeholder="请输入"
  56 + ></n-input-number>
  57 + </SettingItem>
  58 + </SettingItemBox>
  59 + <!-- <SettingItemBox name="标题">
  60 + <SettingItem name="是否显示">
  61 + <n-switch v-model:value="seriesList[0].label.show" size="small"></n-switch>
  62 + </SettingItem>
  63 + <SettingItem name="颜色">
  64 + <n-color-picker size="small" :modes="['hex']" v-model:value="seriesList[0].label.color"></n-color-picker>
  65 + </SettingItem>
  66 + <SettingItem name="大小">
  67 + <n-input-number
  68 + v-model:value="seriesList[0].label.fontSize"
  69 + :min="0"
  70 + size="small"
  71 + placeholder="请输入"
  72 + ></n-input-number>
  73 + </SettingItem>
  74 + </SettingItemBox> -->
  75 + </CollapseItem>
  76 +</template>
  77 +
  78 +<script setup lang="ts">
  79 +import { PropType, computed } from 'vue'
  80 +import { CollapseItem, SettingItemBox, SettingItem } from '@/components/Pages/ChartItemSetting'
  81 +import { GlobalThemeJsonType } from '@/settings/chartThemes/index'
  82 +import { GlobalSetting } from '@/components/Pages/ChartItemSetting'
  83 +import SelectCity from './components/SelectCity.vue'
  84 +
  85 +const props = defineProps({
  86 + optionData: {
  87 + type: Object as PropType<GlobalThemeJsonType>,
  88 + required: true
  89 + }
  90 +})
  91 +
  92 +const seriesList = computed(() => {
  93 + return props.optionData.series
  94 +})
  95 +
  96 +const onHandleSelectValues = (values: any) => {
  97 + const { cityValue, countyValue, provinceValue } = values
  98 + props.optionData.mapRegion.saveSelect = values
  99 + props.optionData.mapRegion.adcode = countyValue
  100 + ? countyValue
  101 + : cityValue
  102 + ? cityValue
  103 + : provinceValue === 'china'
  104 + ? 'china'
  105 + : provinceValue
  106 +}
  107 +</script>
... ...
  1 +{
  2 + "type": "FeatureCollection",
  3 + "features": [
  4 + {
  5 + "type": "Feature",
  6 + "properties": { "name": "成华区" },
  7 + "geometry": {
  8 + "type": "MultiPolygon",
  9 + "coordinates": [
  10 + [
  11 + [
  12 + [104.153985625, 30.740483625],
  13 + [104.161353789063, 30.7259181953125],
  14 + [104.172735625, 30.7314748359376],
  15 + [104.190704375, 30.717202375],
  16 + [104.219771757813, 30.708813703125],
  17 + [104.227345, 30.693843],
  18 + [104.223260527344, 30.6879274726563],
  19 + [104.161903105469, 30.6721804023438],
  20 + [104.153260527344, 30.6279274726563],
  21 + [104.137345, 30.623843],
  22 + [104.09170046875, 30.65819846875],
  23 + [104.087345, 30.663843],
  24 + [104.087345, 30.6738430000001],
  25 + [104.083260527344, 30.6997585273438],
  26 + [104.070081816406, 30.7088576484376],
  27 + [104.137345, 30.753843],
  28 + [104.140704375, 30.747202375],
  29 + [104.153985625, 30.740483625]
  30 + ]
  31 + ]
  32 + ]
  33 + }
  34 + },
  35 + {
  36 + "type": "Feature",
  37 + "properties": { "name": "崇州市" },
  38 + "geometry": {
  39 + "type": "MultiPolygon",
  40 + "coordinates": [
  41 + [
  42 + [
  43 + [103.637345, 30.523843],
  44 + [103.633922148438, 30.5116506171875],
  45 + [103.625152617188, 30.5204201484375],
  46 + [103.637345, 30.523843]
  47 + ]
  48 + ],
  49 + [
  50 + [
  51 + [103.637345, 30.523843],
  52 + [103.623880644531, 30.5412868476563],
  53 + [103.559073515625, 30.5317092109375],
  54 + [103.563084746094, 30.5588430000001],
  55 + [103.560128203125, 30.578843],
  56 + [103.5652746875, 30.6136721015626],
  57 + [103.55170046875, 30.6481984687501],
  58 + [103.541370878906, 30.685298078125],
  59 + [103.501053496094, 30.7164186835938],
  60 + [103.409039335938, 30.7320485664063],
  61 + [103.381954375, 30.7280471015626],
  62 + [103.362279082031, 30.7399147773438],
  63 + [103.332410917969, 30.7177712226563],
  64 + [103.312345, 30.7298757148438],
  65 + [103.292735625, 30.7180471015626],
  66 + [103.282345, 30.7195827460938],
  67 + [103.271832304688, 30.7180275703125],
  68 + [103.236873808594, 30.7633205390626],
  69 + [103.2027746875, 30.7380397773438],
  70 + [103.183924589844, 30.740825421875],
  71 + [103.135914335938, 30.7697878242188],
  72 + [103.117345, 30.793843],
  73 + [103.128631621094, 30.8025563789063],
  74 + [103.14170046875, 30.81948753125],
  75 + [103.15298953125, 30.82819846875],
  76 + [103.16978640625, 30.8499611640625],
  77 + [103.182345, 30.8481032539063],
  78 + [103.192996855469, 30.8496779609375],
  79 + [103.278631621094, 30.8351296210938],
  80 + [103.298426542969, 30.8094875312501],
  81 + [103.33298953125, 30.82819846875],
  82 + [103.353150664063, 30.8543215156251],
  83 + [103.40298953125, 30.8681984687501],
  84 + [103.427345, 30.883843],
  85 + [103.437838164063, 30.8702468085938],
  86 + [103.452345, 30.8681032539062],
  87 + [103.462735625, 30.8696388984375],
  88 + [103.495345488281, 30.8499684882812],
  89 + [103.53298953125, 30.83948753125],
  90 + [103.54170046875, 30.82819846875],
  91 + [103.59298953125, 30.8139162421875],
  92 + [103.612916289063, 30.7652321601563],
  93 + [103.696712675781, 30.7776174140625],
  94 + [103.71170046875, 30.7581984687501],
  95 + [103.727345, 30.753843],
  96 + [103.731429472656, 30.7379274726563],
  97 + [103.743260527344, 30.7197585273438],
  98 + [103.751429472656, 30.6979274726563],
  99 + [103.763565703125, 30.6792897773438],
  100 + [103.760943632813, 30.6675954414063],
  101 + [103.785513945313, 30.6320119453125],
  102 + [103.797345, 30.623843],
  103 + [103.801158476563, 30.5976564765625],
  104 + [103.820518828125, 30.5700807929688],
  105 + [103.810721464844, 30.5386305976563],
  106 + [103.817345, 30.523843],
  107 + [103.784957304688, 30.5209596992188],
  108 + [103.799732695313, 30.5067263007813],
  109 + [103.767345, 30.503843],
  110 + [103.74298953125, 30.5394875312501],
  111 + [103.716143828125, 30.5681984687501],
  112 + [103.682735625, 30.5480471015625],
  113 + [103.671912871094, 30.5496462226563],
  114 + [103.637345, 30.523843]
  115 + ]
  116 + ]
  117 + ]
  118 + }
  119 + },
  120 + {
  121 + "type": "Feature",
  122 + "properties": { "name": "大邑县" },
  123 + "geometry": {
  124 + "type": "MultiPolygon",
  125 + "coordinates": [
  126 + [
  127 + [
  128 + [103.637345, 30.523843],
  129 + [103.625152617188, 30.5204201484375],
  130 + [103.633922148438, 30.5116506171875],
  131 + [103.671912871094, 30.5496462226563],
  132 + [103.682735625, 30.5480471015625],
  133 + [103.716143828125, 30.5681984687501],
  134 + [103.74298953125, 30.5394875312501],
  135 + [103.767345, 30.503843],
  136 + [103.743990507813, 30.4983425117188],
  137 + [103.730220976563, 30.4579372382812],
  138 + [103.707345, 30.4438430000001],
  139 + [103.646654082031, 30.4724758125001],
  140 + [103.62045046875, 30.4566677070313],
  141 + [103.623175078125, 30.4382228828125],
  142 + [103.55158328125, 30.4294875312501],
  143 + [103.51298953125, 30.47948753125],
  144 + [103.459075957031, 30.4886452460938],
  145 + [103.437913847656, 30.5160622382813],
  146 + [103.388421660156, 30.5504787421876],
  147 + [103.367345, 30.5473659492188],
  148 + [103.347345, 30.5503200507813],
  149 + [103.303482695313, 30.5438381171875],
  150 + [103.292916289063, 30.5180202460938],
  151 + [103.272857695313, 30.5209841132813],
  152 + [103.260809355469, 30.505376203125],
  153 + [103.232345, 30.5095827460938],
  154 + [103.221954375, 30.5080471015625],
  155 + [103.20298953125, 30.51948753125],
  156 + [103.177345, 30.523843],
  157 + [103.156800566406, 30.5291139960938],
  158 + [103.164818144531, 30.5648757148438],
  159 + [103.125250273438, 30.5921950507813],
  160 + [103.133465605469, 30.6288430000001],
  161 + [103.126314726563, 30.660747296875],
  162 + [103.089598417969, 30.6860964179688],
  163 + [103.07033328125, 30.7139968085937],
  164 + [103.032345, 30.7054811835937],
  165 + [103.023260527344, 30.7297585273438],
  166 + [103.001429472656, 30.7579274726563],
  167 + [102.987345, 30.7838430000001],
  168 + [103.00298953125, 30.78819846875],
  169 + [103.073162871094, 30.815786359375],
  170 + [103.11298953125, 30.79948753125],
  171 + [103.117345, 30.793843],
  172 + [103.135914335938, 30.7697878242188],
  173 + [103.183924589844, 30.740825421875],
  174 + [103.2027746875, 30.7380397773438],
  175 + [103.236873808594, 30.7633205390626],
  176 + [103.271832304688, 30.7180275703125],
  177 + [103.282345, 30.7195827460938],
  178 + [103.292735625, 30.7180471015626],
  179 + [103.312345, 30.7298757148438],
  180 + [103.332410917969, 30.7177712226563],
  181 + [103.362279082031, 30.7399147773438],
  182 + [103.381954375, 30.7280471015626],
  183 + [103.409039335938, 30.7320485664063],
  184 + [103.501053496094, 30.7164186835938],
  185 + [103.541370878906, 30.685298078125],
  186 + [103.55170046875, 30.6481984687501],
  187 + [103.5652746875, 30.6136721015626],
  188 + [103.560128203125, 30.578843],
  189 + [103.563084746094, 30.5588430000001],
  190 + [103.559073515625, 30.5317092109375],
  191 + [103.623880644531, 30.5412868476563],
  192 + [103.637345, 30.523843]
  193 + ]
  194 + ]
  195 + ]
  196 + }
  197 + },
  198 + {
  199 + "type": "Feature",
  200 + "properties": { "name": "都江堰市" },
  201 + "geometry": {
  202 + "type": "MultiPolygon",
  203 + "coordinates": [
  204 + [
  205 + [
  206 + [103.695362578125, 31.3499343085938],
  207 + [103.71744265625, 31.2742067695313],
  208 + [103.677205839844, 31.2199343085937],
  209 + [103.706058378906, 31.1825563789063],
  210 + [103.732178984375, 31.1623928046875],
  211 + [103.74170046875, 31.12819846875],
  212 + [103.770584746094, 31.0803151679688],
  213 + [103.729268828125, 31.0688088203125],
  214 + [103.753140898438, 31.029233625],
  215 + [103.751549101563, 31.0184523750001],
  216 + [103.771219511719, 30.9858425117188],
  217 + [103.777345, 30.963843],
  218 + [103.771429472656, 30.9597585273438],
  219 + [103.763260527344, 30.9279274726563],
  220 + [103.751160917969, 30.8991213203126],
  221 + [103.753616972656, 30.8881667304688],
  222 + [103.717345, 30.8638430000001],
  223 + [103.683756132813, 30.8852126289063],
  224 + [103.712899199219, 30.8093971992188],
  225 + [103.721790800781, 30.7682888007813],
  226 + [103.727345, 30.753843],
  227 + [103.71170046875, 30.7581984687501],
  228 + [103.696712675781, 30.7776174140625],
  229 + [103.612916289063, 30.7652321601563],
  230 + [103.59298953125, 30.8139162421875],
  231 + [103.54170046875, 30.82819846875],
  232 + [103.53298953125, 30.83948753125],
  233 + [103.495345488281, 30.8499684882812],
  234 + [103.462735625, 30.8696388984375],
  235 + [103.452345, 30.8681032539062],
  236 + [103.437838164063, 30.8702468085938],
  237 + [103.427345, 30.883843],
  238 + [103.44298953125, 30.88819846875],
  239 + [103.457257109375, 30.9394435859376],
  240 + [103.519862089844, 30.9829787421875],
  241 + [103.509969511719, 31.0499221015625],
  242 + [103.534862089844, 31.1181471992188],
  243 + [103.55298953125, 31.14819846875],
  244 + [103.56170046875, 31.16948753125],
  245 + [103.581451445313, 31.2022267890625],
  246 + [103.570867949219, 31.273843],
  247 + [103.573822050781, 31.293843],
  248 + [103.566370878906, 31.3442653632812],
  249 + [103.607345, 31.3503200507813],
  250 + [103.622486601563, 31.3480837226563],
  251 + [103.67170046875, 31.35948753125],
  252 + [103.677345, 31.363843],
  253 + [103.695362578125, 31.3499343085938]
  254 + ]
  255 + ]
  256 + ]
  257 + }
  258 + },
  259 + {
  260 + "type": "Feature",
  261 + "properties": { "name": "金牛区" },
  262 + "geometry": {
  263 + "type": "MultiPolygon",
  264 + "coordinates": [
  265 + [
  266 + [
  267 + [104.123385039063, 30.7840578437501],
  268 + [104.121795683594, 30.768452375],
  269 + [104.132806425781, 30.7593044257813],
  270 + [104.137345, 30.753843],
  271 + [104.070081816406, 30.7088576484376],
  272 + [104.083260527344, 30.6997585273438],
  273 + [104.087345, 30.6738430000001],
  274 + [104.061929960938, 30.6800856757813],
  275 + [104.042345, 30.6673317695313],
  276 + [104.023260527344, 30.6797585273438],
  277 + [104.001051054688, 30.6880690742188],
  278 + [104.004320097656, 30.7026491523438],
  279 + [103.976312285156, 30.6963698554688],
  280 + [103.957345, 30.723843],
  281 + [103.959888945313, 30.7312990546876],
  282 + [103.994801054688, 30.7363869453125],
  283 + [104.000716582031, 30.7653542304688],
  284 + [104.0341809375, 30.73212425],
  285 + [104.037345, 30.753843],
  286 + [104.06531375, 30.7476174140625],
  287 + [104.093704863281, 30.7505104804688],
  288 + [104.091685820313, 30.7703054023438],
  289 + [104.065233183594, 30.7676076484375],
  290 + [104.058656035156, 30.8083815742188],
  291 + [104.123385039063, 30.7840578437501]
  292 + ]
  293 + ]
  294 + ]
  295 + }
  296 + },
  297 + {
  298 + "type": "Feature",
  299 + "properties": { "name": "金堂县" },
  300 + "geometry": {
  301 + "type": "MultiPolygon",
  302 + "coordinates": [
  303 + [
  304 + [
  305 + [104.437345, 30.653843],
  306 + [104.433292265625, 30.630844953125],
  307 + [104.424647246094, 30.6484084296876],
  308 + [104.437345, 30.653843]
  309 + ]
  310 + ],
  311 + [
  312 + [
  313 + [104.457345, 30.663843],
  314 + [104.447345, 30.663843],
  315 + [104.447345, 30.653843],
  316 + [104.437345, 30.653843],
  317 + [104.437345, 30.6738430000001],
  318 + [104.457345, 30.6738430000001],
  319 + [104.457345, 30.663843]
  320 + ]
  321 + ],
  322 + [
  323 + [
  324 + [104.357345, 30.843843],
  325 + [104.353922148438, 30.8316506171875],
  326 + [104.345152617188, 30.8404201484376],
  327 + [104.357345, 30.843843]
  328 + ]
  329 + ],
  330 + [
  331 + [
  332 + [104.367345, 30.843843],
  333 + [104.357345, 30.843843],
  334 + [104.362345, 30.8566506171875],
  335 + [104.367345, 30.843843]
  336 + ]
  337 + ],
  338 + [
  339 + [
  340 + [104.447345, 30.653843],
  341 + [104.457345, 30.653843],
  342 + [104.457345, 30.663843],
  343 + [104.47298953125, 30.66819846875],
  344 + [104.48170046875, 30.67948753125],
  345 + [104.493822050781, 30.688843],
  346 + [104.481529570313, 30.6983303046876],
  347 + [104.483140898438, 30.7092336250001],
  348 + [104.471549101563, 30.728452375],
  349 + [104.475301542969, 30.753843],
  350 + [104.471302519531, 30.7809059882813],
  351 + [104.452345, 30.7781032539063],
  352 + [104.442345, 30.7795827460938],
  353 + [104.431832304688, 30.7780275703126],
  354 + [104.422857695313, 30.7896584296876],
  355 + [104.377684355469, 30.7829811835938],
  356 + [104.367345, 30.843843],
  357 + [104.373531523438, 30.8476564765625],
  358 + [104.384456816406, 30.8797145820313],
  359 + [104.356300078125, 30.8893117500001],
  360 + [104.347345, 30.9038430000001],
  361 + [104.369691191406, 30.9437599921875],
  362 + [104.382345, 30.9273659492188],
  363 + [104.392689238281, 30.940766828125],
  364 + [104.458592558594, 30.9505055976563],
  365 + [104.487345, 30.9438430000001],
  366 + [104.525235625, 30.9222096992188],
  367 + [104.521790800781, 30.8884133125],
  368 + [104.607623320313, 30.8575759101563],
  369 + [104.69373171875, 30.82022971875],
  370 + [104.711922636719, 30.7782912421876],
  371 + [104.728192167969, 30.7799489570313],
  372 + [104.744151640625, 30.743149640625],
  373 + [104.782806425781, 30.7193044257813],
  374 + [104.791883574219, 30.6983815742188],
  375 + [104.804881621094, 30.687583234375],
  376 + [104.821922636719, 30.6482912421875],
  377 + [104.841685820313, 30.6503054023438],
  378 + [104.84310671875, 30.6363649726563],
  379 + [104.813114042969, 30.5839968085938],
  380 + [104.857345, 30.5938430000001],
  381 + [104.860885039063, 30.5773830390625],
  382 + [104.890797148438, 30.5420412421875],
  383 + [104.877345, 30.5138430000001],
  384 + [104.852386503906, 30.5077126289063],
  385 + [104.815697050781, 30.5159377265625],
  386 + [104.803260527344, 30.4979274726563],
  387 + [104.759598417969, 30.4815895820313],
  388 + [104.763624296875, 30.4995510078125],
  389 + [104.731429472656, 30.5179274726563],
  390 + [104.723260527344, 30.5397585273438],
  391 + [104.68709109375, 30.5604030585937],
  392 + [104.695557890625, 30.5981716132813],
  393 + [104.674525175781, 30.6126955390625],
  394 + [104.651898222656, 30.607622296875],
  395 + [104.633260527344, 30.6197585273438],
  396 + [104.601429472656, 30.6279274726563],
  397 + [104.572623320313, 30.6400270820313],
  398 + [104.532274199219, 30.630981671875],
  399 + [104.523260527344, 30.6179274726563],
  400 + [104.494569121094, 30.5981179023438],
  401 + [104.437069121094, 30.5897585273438],
  402 + [104.427345, 30.603843],
  403 + [104.427345, 30.613843],
  404 + [104.447345, 30.613843],
  405 + [104.447345, 30.653843]
  406 + ]
  407 + ]
  408 + ]
  409 + }
  410 + },
  411 + {
  412 + "type": "Feature",
  413 + "properties": { "name": "锦江区" },
  414 + "geometry": {
  415 + "type": "MultiPolygon",
  416 + "coordinates": [
  417 + [
  418 + [
  419 + [104.163216582031, 30.5891823554688],
  420 + [104.157345, 30.563843],
  421 + [104.131929960938, 30.5700856757812],
  422 + [104.111998320313, 30.55710471875],
  423 + [104.103260527344, 30.5697585273438],
  424 + [104.077345, 30.573843],
  425 + [104.083089628906, 30.6088088203125],
  426 + [104.081605253906, 30.618843],
  427 + [104.084486113281, 30.6383303046875],
  428 + [104.07170046875, 30.6481984687501],
  429 + [104.067345, 30.653843],
  430 + [104.067345, 30.663843],
  431 + [104.087345, 30.663843],
  432 + [104.09170046875, 30.65819846875],
  433 + [104.137345, 30.623843],
  434 + [104.163216582031, 30.5891823554688]
  435 + ]
  436 + ]
  437 + ]
  438 + }
  439 + },
  440 + {
  441 + "type": "Feature",
  442 + "properties": { "name": "龙泉驿区" },
  443 + "geometry": {
  444 + "type": "MultiPolygon",
  445 + "coordinates": [
  446 + [
  447 + [
  448 + [104.437345, 30.653843],
  449 + [104.424647246094, 30.6484084296876],
  450 + [104.433292265625, 30.630844953125],
  451 + [104.447345, 30.653843],
  452 + [104.447345, 30.613843],
  453 + [104.427345, 30.613843],
  454 + [104.427345, 30.603843],
  455 + [104.411429472656, 30.5997585273438],
  456 + [104.400186796875, 30.5834743476562],
  457 + [104.403465605469, 30.568843],
  458 + [104.395250273438, 30.5321950507813],
  459 + [104.414586210938, 30.5188430000001],
  460 + [104.401429472656, 30.5097585273438],
  461 + [104.393260527344, 30.4979274726563],
  462 + [104.342557402344, 30.4849147773438],
  463 + [104.332615996094, 30.51147971875],
  464 + [104.321673613281, 30.495630109375],
  465 + [104.295545683594, 30.5014870429688],
  466 + [104.252349882813, 30.483344953125],
  467 + [104.247345, 30.463843],
  468 + [104.207398710938, 30.4838747382813],
  469 + [104.180657988281, 30.5371071601562],
  470 + [104.160704375, 30.547202375],
  471 + [104.157345, 30.563843],
  472 + [104.163216582031, 30.5891823554688],
  473 + [104.137345, 30.623843],
  474 + [104.153260527344, 30.6279274726563],
  475 + [104.161903105469, 30.6721804023438],
  476 + [104.223260527344, 30.6879274726563],
  477 + [104.227345, 30.693843],
  478 + [104.233531523438, 30.6900295234376],
  479 + [104.244737578125, 30.6718459296876],
  480 + [104.261158476563, 30.7200295234375],
  481 + [104.267345, 30.723843],
  482 + [104.272857695313, 30.7167018867188],
  483 + [104.308175078125, 30.7219216132813],
  484 + [104.380941191406, 30.6921388984376],
  485 + [104.392857695313, 30.6767018867188],
  486 + [104.419906035156, 30.6806984687501],
  487 + [104.437345, 30.6738430000001],
  488 + [104.437345, 30.653843]
  489 + ]
  490 + ]
  491 + ]
  492 + }
  493 + },
  494 + {
  495 + "type": "Feature",
  496 + "properties": { "name": "彭州市" },
  497 + "geometry": {
  498 + "type": "MultiPolygon",
  499 + "coordinates": [
  500 + [
  501 + [
  502 + [103.81298953125, 31.42948753125],
  503 + [103.82490359375, 31.4140480781251],
  504 + [103.862345, 31.4195827460938],
  505 + [103.877345, 31.4173659492188],
  506 + [103.892916289063, 31.4196657539063],
  507 + [103.90170046875, 31.39819846875],
  508 + [103.924615507813, 31.3602126289063],
  509 + [103.887139921875, 31.3138430000001],
  510 + [103.92298953125, 31.2694875312501],
  511 + [103.93170046875, 31.22819846875],
  512 + [103.94298953125, 31.21948753125],
  513 + [103.951832304688, 31.2080275703125],
  514 + [103.968695097656, 31.2105202460938],
  515 + [104.014066191406, 31.1754982734376],
  516 + [104.011363554688, 31.157192609375],
  517 + [104.022850371094, 31.10274925],
  518 + [104.05298953125, 31.0794875312501],
  519 + [104.06170046875, 31.0681984687501],
  520 + [104.07298953125, 31.05948753125],
  521 + [104.089075957031, 31.0386452460938],
  522 + [104.117345, 31.033843],
  523 + [104.124969511719, 31.0214675117188],
  524 + [104.160572539063, 30.9995314765625],
  525 + [104.170816679688, 30.9666481757813],
  526 + [104.140472441406, 30.9291847968751],
  527 + [104.147345, 30.913843],
  528 + [104.079295683594, 30.9183596015626],
  529 + [104.043829375, 30.9643068671875],
  530 + [103.95298953125, 30.92819846875],
  531 + [103.917345, 30.923843],
  532 + [103.907345, 30.923843],
  533 + [103.907345, 30.9338430000001],
  534 + [103.897345, 30.9338430000001],
  535 + [103.852906523438, 30.9411428046876],
  536 + [103.832135039063, 30.9380739570313],
  537 + [103.787100859375, 30.9512038398437],
  538 + [103.777345, 30.963843],
  539 + [103.771219511719, 30.9858425117188],
  540 + [103.751549101563, 31.0184523750001],
  541 + [103.753140898438, 31.029233625],
  542 + [103.729268828125, 31.0688088203125],
  543 + [103.770584746094, 31.0803151679688],
  544 + [103.74170046875, 31.12819846875],
  545 + [103.732178984375, 31.1623928046875],
  546 + [103.706058378906, 31.1825563789063],
  547 + [103.677205839844, 31.2199343085937],
  548 + [103.71744265625, 31.2742067695313],
  549 + [103.695362578125, 31.3499343085938],
  550 + [103.677345, 31.363843],
  551 + [103.691439238281, 31.3867189765625],
  552 + [103.728389921875, 31.39931175],
  553 + [103.737345, 31.413843],
  554 + [103.770704375, 31.430483625],
  555 + [103.797345, 31.4338430000001],
  556 + [103.81298953125, 31.42948753125]
  557 + ]
  558 + ]
  559 + ]
  560 + }
  561 + },
  562 + {
  563 + "type": "Feature",
  564 + "properties": { "name": "蒲江县" },
  565 + "geometry": {
  566 + "type": "MultiPolygon",
  567 + "coordinates": [
  568 + [
  569 + [
  570 + [103.552906523438, 30.3396852851562],
  571 + [103.562916289063, 30.3152321601562],
  572 + [103.614813261719, 30.3229030585938],
  573 + [103.680765410156, 30.304536359375],
  574 + [103.68312625, 30.28855003125],
  575 + [103.677345, 30.273843],
  576 + [103.687345, 30.2538430000001],
  577 + [103.652386503906, 30.236313703125],
  578 + [103.643580351563, 30.2057985664063],
  579 + [103.631954375, 30.2114748359375],
  580 + [103.612735625, 30.1962111640626],
  581 + [103.597345, 30.2037258125],
  582 + [103.582345, 30.19640159375],
  583 + [103.571353789063, 30.2017678046875],
  584 + [103.563336210938, 30.1859181953125],
  585 + [103.552218046875, 30.1913454414063],
  586 + [103.533985625, 30.1809596992188],
  587 + [103.545272246094, 30.1578493476563],
  588 + [103.510704375, 30.140483625],
  589 + [103.507345, 30.1338430000001],
  590 + [103.482003203125, 30.1170973945313],
  591 + [103.473260527344, 30.1297585273438],
  592 + [103.433260527344, 30.1309841132812],
  593 + [103.463260527344, 30.1197585273438],
  594 + [103.463973417969, 30.0897585273438],
  595 + [103.422264433594, 30.116919171875],
  596 + [103.387345, 30.0938430000001],
  597 + [103.383531523438, 30.1100295234375],
  598 + [103.371158476563, 30.1276564765625],
  599 + [103.354764433594, 30.1757595039063],
  600 + [103.375714140625, 30.222524640625],
  601 + [103.345240507813, 30.2413014960938],
  602 + [103.322345, 30.2341701484375],
  603 + [103.313531523438, 30.2600295234375],
  604 + [103.307345, 30.263843],
  605 + [103.312323027344, 30.2702907539063],
  606 + [103.357164335938, 30.3035378242188],
  607 + [103.39298953125, 30.31819846875],
  608 + [103.413922148438, 30.3308254218751],
  609 + [103.442345, 30.326626203125],
  610 + [103.467345, 30.3303200507813],
  611 + [103.482379179688, 30.3280983710938],
  612 + [103.552906523438, 30.3396852851562]
  613 + ]
  614 + ]
  615 + ]
  616 + }
  617 + },
  618 + {
  619 + "type": "Feature",
  620 + "properties": { "name": "青白江区" },
  621 + "geometry": {
  622 + "type": "MultiPolygon",
  623 + "coordinates": [
  624 + [
  625 + [
  626 + [104.457345, 30.663843],
  627 + [104.457345, 30.653843],
  628 + [104.447345, 30.653843],
  629 + [104.447345, 30.663843],
  630 + [104.457345, 30.663843]
  631 + ]
  632 + ],
  633 + [
  634 + [
  635 + [104.367345, 30.843843],
  636 + [104.362345, 30.8566506171875],
  637 + [104.357345, 30.843843],
  638 + [104.345152617188, 30.8404201484376],
  639 + [104.353922148438, 30.8316506171875],
  640 + [104.357345, 30.843843],
  641 + [104.377684355469, 30.7829811835938],
  642 + [104.422857695313, 30.7896584296876],
  643 + [104.431832304688, 30.7780275703126],
  644 + [104.442345, 30.7795827460938],
  645 + [104.452345, 30.7781032539063],
  646 + [104.471302519531, 30.7809059882813],
  647 + [104.475301542969, 30.753843],
  648 + [104.471549101563, 30.728452375],
  649 + [104.483140898438, 30.7092336250001],
  650 + [104.481529570313, 30.6983303046876],
  651 + [104.493822050781, 30.688843],
  652 + [104.48170046875, 30.67948753125],
  653 + [104.47298953125, 30.66819846875],
  654 + [104.457345, 30.663843],
  655 + [104.457345, 30.6738430000001],
  656 + [104.437345, 30.6738430000001],
  657 + [104.419906035156, 30.6806984687501],
  658 + [104.392857695313, 30.6767018867188],
  659 + [104.380941191406, 30.6921388984376],
  660 + [104.308175078125, 30.7219216132813],
  661 + [104.272857695313, 30.7167018867188],
  662 + [104.267345, 30.723843],
  663 + [104.280301542969, 30.733843],
  664 + [104.260203886719, 30.7493556953126],
  665 + [104.263949003906, 30.7747023750001],
  666 + [104.226378203125, 30.8253786445312],
  667 + [104.243519316406, 30.838608625],
  668 + [104.231668730469, 30.8582521796876],
  669 + [104.161151152344, 30.8682765937501],
  670 + [104.177345, 30.9038430000001],
  671 + [104.187345, 30.9038430000001],
  672 + [104.187345, 30.913843],
  673 + [104.226236601563, 30.9053591132813],
  674 + [104.31982546875, 30.8978395820313],
  675 + [104.347345, 30.9038430000001],
  676 + [104.356300078125, 30.8893117500001],
  677 + [104.384456816406, 30.8797145820313],
  678 + [104.373531523438, 30.8476564765625],
  679 + [104.367345, 30.843843]
  680 + ]
  681 + ]
  682 + ]
  683 + }
  684 + },
  685 + {
  686 + "type": "Feature",
  687 + "properties": { "name": "青羊区" },
  688 + "geometry": {
  689 + "type": "MultiPolygon",
  690 + "coordinates": [
  691 + [
  692 + [
  693 + [103.957345, 30.723843],
  694 + [103.976312285156, 30.6963698554688],
  695 + [104.004320097656, 30.7026491523438],
  696 + [104.001051054688, 30.6880690742188],
  697 + [104.023260527344, 30.6797585273438],
  698 + [104.042345, 30.6673317695313],
  699 + [104.061929960938, 30.6800856757813],
  700 + [104.087345, 30.6738430000001],
  701 + [104.087345, 30.663843],
  702 + [104.067345, 30.663843],
  703 + [104.067345, 30.653843],
  704 + [103.991790800781, 30.6582888007813],
  705 + [103.947345, 30.663843],
  706 + [103.927345, 30.663843],
  707 + [103.927345, 30.6738430000001],
  708 + [103.917345, 30.6738430000001],
  709 + [103.907345, 30.6738430000001],
  710 + [103.900531035156, 30.6791042304688],
  711 + [103.93170046875, 30.71948753125],
  712 + [103.947345, 30.723843],
  713 + [103.957345, 30.723843]
  714 + ]
  715 + ]
  716 + ]
  717 + }
  718 + },
  719 + {
  720 + "type": "Feature",
  721 + "properties": { "name": "双流县" },
  722 + "geometry": {
  723 + "type": "MultiPolygon",
  724 + "coordinates": [
  725 + [
  726 + [
  727 + [103.917345, 30.6738430000001],
  728 + [103.917345, 30.663843],
  729 + [103.927345, 30.663843],
  730 + [103.947345, 30.663843],
  731 + [103.951158476563, 30.6376564765625],
  732 + [103.963912382813, 30.5988747382813],
  733 + [103.960787382813, 30.5888430000001],
  734 + [103.965091582031, 30.5750270820313],
  735 + [104.002345, 30.5866310859375],
  736 + [104.036160917969, 30.5760964179688],
  737 + [104.027672148438, 30.548843],
  738 + [104.073079863281, 30.5333693671875],
  739 + [104.077345, 30.573843],
  740 + [104.103260527344, 30.5697585273438],
  741 + [104.111998320313, 30.55710471875],
  742 + [104.131929960938, 30.5700856757812],
  743 + [104.157345, 30.563843],
  744 + [104.160704375, 30.547202375],
  745 + [104.180657988281, 30.5371071601562],
  746 + [104.207398710938, 30.4838747382813],
  747 + [104.247345, 30.463843],
  748 + [104.2682825, 30.458012921875],
  749 + [104.248631621094, 30.4325563789063],
  750 + [104.23170046875, 30.41948753125],
  751 + [104.218631621094, 30.3875563789063],
  752 + [104.20170046875, 30.3594875312501],
  753 + [104.187345, 30.3238430000001],
  754 + [104.182154570313, 30.3190334296876],
  755 + [104.158365507813, 30.2821950507813],
  756 + [104.133433867188, 30.2293654609376],
  757 + [104.042503691406, 30.269048078125],
  758 + [104.032345, 30.2686452460938],
  759 + [104.017345, 30.2692385078126],
  760 + [104.002193632813, 30.2686379218751],
  761 + [103.987345, 30.273843],
  762 + [103.971656523438, 30.312798078125],
  763 + [103.943065214844, 30.3348635078125],
  764 + [103.93298953125, 30.3594875312501],
  765 + [103.917345, 30.3638430000001],
  766 + [103.931698027344, 30.4038430000001],
  767 + [103.912034941406, 30.4586428046875],
  768 + [103.912642851563, 30.468843],
  769 + [103.9116809375, 30.4849684882813],
  770 + [103.882064238281, 30.4985622382813],
  771 + [103.871585722656, 30.5102883125],
  772 + [103.831585722656, 30.5079030585938],
  773 + [103.817345, 30.523843],
  774 + [103.810721464844, 30.5386305976563],
  775 + [103.820518828125, 30.5700807929688],
  776 + [103.801158476563, 30.5976564765625],
  777 + [103.797345, 30.623843],
  778 + [103.832081328125, 30.6098805976563],
  779 + [103.869505644531, 30.6601930976563],
  780 + [103.882345, 30.6579811835938],
  781 + [103.897486601563, 30.6605886054688],
  782 + [103.907345, 30.6738430000001],
  783 + [103.917345, 30.6738430000001]
  784 + ]
  785 + ]
  786 + ]
  787 + }
  788 + },
  789 + {
  790 + "type": "Feature",
  791 + "properties": { "name": "温江区" },
  792 + "geometry": {
  793 + "type": "MultiPolygon",
  794 + "coordinates": [
  795 + [
  796 + [
  797 + [103.927345, 30.663843],
  798 + [103.917345, 30.663843],
  799 + [103.917345, 30.6738430000001],
  800 + [103.927345, 30.6738430000001],
  801 + [103.927345, 30.663843]
  802 + ]
  803 + ],
  804 + [
  805 + [
  806 + [103.801607695313, 30.7860329414063],
  807 + [103.86705203125, 30.747563703125],
  808 + [103.895206328125, 30.7510646796876],
  809 + [103.94099734375, 30.7317702460938],
  810 + [103.947345, 30.723843],
  811 + [103.93170046875, 30.71948753125],
  812 + [103.900531035156, 30.6791042304688],
  813 + [103.907345, 30.6738430000001],
  814 + [103.897486601563, 30.6605886054688],
  815 + [103.882345, 30.6579811835938],
  816 + [103.869505644531, 30.6601930976563],
  817 + [103.832081328125, 30.6098805976563],
  818 + [103.797345, 30.623843],
  819 + [103.785513945313, 30.6320119453125],
  820 + [103.760943632813, 30.6675954414063],
  821 + [103.763565703125, 30.6792897773438],
  822 + [103.751429472656, 30.6979274726563],
  823 + [103.743260527344, 30.7197585273438],
  824 + [103.731429472656, 30.7379274726563],
  825 + [103.727345, 30.753843],
  826 + [103.721790800781, 30.7682888007813],
  827 + [103.712899199219, 30.8093971992188],
  828 + [103.683756132813, 30.8852126289063],
  829 + [103.717345, 30.8638430000001],
  830 + [103.721790800781, 30.8482888007813],
  831 + [103.752899199219, 30.8293971992187],
  832 + [103.761790800781, 30.8182888007813],
  833 + [103.782899199219, 30.8093971992188],
  834 + [103.801607695313, 30.7860329414063]
  835 + ]
  836 + ]
  837 + ]
  838 + }
  839 + },
  840 + {
  841 + "type": "Feature",
  842 + "properties": { "name": "武侯区" },
  843 + "geometry": {
  844 + "type": "MultiPolygon",
  845 + "coordinates": [
  846 + [
  847 + [
  848 + [104.083089628906, 30.6088088203125],
  849 + [104.077345, 30.573843],
  850 + [104.073079863281, 30.5333693671875],
  851 + [104.027672148438, 30.548843],
  852 + [104.036160917969, 30.5760964179688],
  853 + [104.002345, 30.5866310859375],
  854 + [103.965091582031, 30.5750270820313],
  855 + [103.960787382813, 30.5888430000001],
  856 + [103.963912382813, 30.5988747382813],
  857 + [103.951158476563, 30.6376564765625],
  858 + [103.947345, 30.663843],
  859 + [103.991790800781, 30.6582888007813],
  860 + [104.067345, 30.653843],
  861 + [104.07170046875, 30.6481984687501],
  862 + [104.084486113281, 30.6383303046875],
  863 + [104.081605253906, 30.618843],
  864 + [104.083089628906, 30.6088088203125]
  865 + ]
  866 + ]
  867 + ]
  868 + }
  869 + },
  870 + {
  871 + "type": "Feature",
  872 + "properties": { "name": "新都区" },
  873 + "geometry": {
  874 + "type": "MultiPolygon",
  875 + "coordinates": [
  876 + [
  877 + [
  878 + [104.177345, 30.9038430000001],
  879 + [104.177345, 30.913843],
  880 + [104.187345, 30.913843],
  881 + [104.187345, 30.9038430000001],
  882 + [104.177345, 30.9038430000001]
  883 + ]
  884 + ],
  885 + [
  886 + [
  887 + [103.907345, 30.923843],
  888 + [103.897345, 30.923843],
  889 + [103.897345, 30.9338430000001],
  890 + [103.907345, 30.9338430000001],
  891 + [103.907345, 30.923843]
  892 + ]
  893 + ],
  894 + [
  895 + [
  896 + [104.177345, 30.9038430000001],
  897 + [104.161151152344, 30.8682765937501],
  898 + [104.231668730469, 30.8582521796876],
  899 + [104.243519316406, 30.838608625],
  900 + [104.226378203125, 30.8253786445312],
  901 + [104.263949003906, 30.7747023750001],
  902 + [104.260203886719, 30.7493556953126],
  903 + [104.280301542969, 30.733843],
  904 + [104.267345, 30.723843],
  905 + [104.261158476563, 30.7200295234375],
  906 + [104.244737578125, 30.6718459296876],
  907 + [104.233531523438, 30.6900295234376],
  908 + [104.227345, 30.693843],
  909 + [104.219771757813, 30.708813703125],
  910 + [104.190704375, 30.717202375],
  911 + [104.172735625, 30.7314748359376],
  912 + [104.161353789063, 30.7259181953125],
  913 + [104.153985625, 30.740483625],
  914 + [104.140704375, 30.747202375],
  915 + [104.137345, 30.753843],
  916 + [104.132806425781, 30.7593044257813],
  917 + [104.121795683594, 30.768452375],
  918 + [104.123385039063, 30.7840578437501],
  919 + [104.058656035156, 30.8083815742188],
  920 + [104.065233183594, 30.7676076484375],
  921 + [104.091685820313, 30.7703054023438],
  922 + [104.093704863281, 30.7505104804688],
  923 + [104.06531375, 30.7476174140625],
  924 + [104.037345, 30.753843],
  925 + [104.033260527344, 30.7597585273437],
  926 + [104.019056425781, 30.8175905585938],
  927 + [103.977706328125, 30.8330617500001],
  928 + [103.939791289063, 30.8624489570313],
  929 + [103.948099394531, 30.8995143867188],
  930 + [103.921429472656, 30.9179274726563],
  931 + [103.917345, 30.923843],
  932 + [103.95298953125, 30.92819846875],
  933 + [104.043829375, 30.9643068671875],
  934 + [104.079295683594, 30.9183596015626],
  935 + [104.147345, 30.913843],
  936 + [104.163326445313, 30.9217873359376],
  937 + [104.170704375, 30.907202375],
  938 + [104.177345, 30.9038430000001]
  939 + ]
  940 + ]
  941 + ]
  942 + }
  943 + },
  944 + {
  945 + "type": "Feature",
  946 + "properties": { "name": "新津县" },
  947 + "geometry": {
  948 + "type": "MultiPolygon",
  949 + "coordinates": [
  950 + [
  951 + [
  952 + [103.817345, 30.523843],
  953 + [103.831585722656, 30.5079030585938],
  954 + [103.871585722656, 30.5102883125],
  955 + [103.882064238281, 30.4985622382813],
  956 + [103.9116809375, 30.4849684882813],
  957 + [103.912642851563, 30.468843],
  958 + [103.912034941406, 30.4586428046875],
  959 + [103.931698027344, 30.4038430000001],
  960 + [103.917345, 30.3638430000001],
  961 + [103.912205839844, 30.3406740546876],
  962 + [103.884998808594, 30.3304201484375],
  963 + [103.869691191406, 30.3572658515625],
  964 + [103.827345, 30.3413039375],
  965 + [103.794564238281, 30.3536598945313],
  966 + [103.770975371094, 30.3402126289063],
  967 + [103.767345, 30.3338430000001],
  968 + [103.752623320313, 30.3400270820313],
  969 + [103.728011503906, 30.3345095039062],
  970 + [103.750985136719, 30.369790265625],
  971 + [103.714151640625, 30.4173171210938],
  972 + [103.707345, 30.4438430000001],
  973 + [103.730220976563, 30.4579372382812],
  974 + [103.743990507813, 30.4983425117188],
  975 + [103.767345, 30.503843],
  976 + [103.799732695313, 30.5067263007813],
  977 + [103.784957304688, 30.5209596992188],
  978 + [103.817345, 30.523843]
  979 + ]
  980 + ]
  981 + ]
  982 + }
  983 + },
  984 + {
  985 + "type": "Feature",
  986 + "properties": { "name": "邛崃市" },
  987 + "geometry": {
  988 + "type": "MultiPolygon",
  989 + "coordinates": [
  990 + [
  991 + [
  992 + [103.127345, 30.4438430000001],
  993 + [103.130767851563, 30.4316506171875],
  994 + [103.139537382813, 30.4404201484375],
  995 + [103.133360625, 30.4672829414063],
  996 + [103.172713652344, 30.4944533515626],
  997 + [103.177345, 30.523843],
  998 + [103.20298953125, 30.51948753125],
  999 + [103.221954375, 30.5080471015625],
  1000 + [103.232345, 30.5095827460938],
  1001 + [103.260809355469, 30.505376203125],
  1002 + [103.272857695313, 30.5209841132813],
  1003 + [103.292916289063, 30.5180202460938],
  1004 + [103.303482695313, 30.5438381171875],
  1005 + [103.347345, 30.5503200507813],
  1006 + [103.367345, 30.5473659492188],
  1007 + [103.388421660156, 30.5504787421876],
  1008 + [103.437913847656, 30.5160622382813],
  1009 + [103.459075957031, 30.4886452460938],
  1010 + [103.51298953125, 30.47948753125],
  1011 + [103.55158328125, 30.4294875312501],
  1012 + [103.623175078125, 30.4382228828125],
  1013 + [103.62045046875, 30.4566677070313],
  1014 + [103.646654082031, 30.4724758125001],
  1015 + [103.707345, 30.4438430000001],
  1016 + [103.714151640625, 30.4173171210938],
  1017 + [103.750985136719, 30.369790265625],
  1018 + [103.728011503906, 30.3345095039062],
  1019 + [103.752623320313, 30.3400270820313],
  1020 + [103.767345, 30.3338430000001],
  1021 + [103.763985625, 30.327202375],
  1022 + [103.729417753906, 30.3098366523438],
  1023 + [103.739888945313, 30.28839378125],
  1024 + [103.717345, 30.2838430000001],
  1025 + [103.707345, 30.2838430000001],
  1026 + [103.707345, 30.273843],
  1027 + [103.677345, 30.273843],
  1028 + [103.68312625, 30.28855003125],
  1029 + [103.680765410156, 30.304536359375],
  1030 + [103.614813261719, 30.3229030585938],
  1031 + [103.562916289063, 30.3152321601562],
  1032 + [103.552906523438, 30.3396852851562],
  1033 + [103.482379179688, 30.3280983710938],
  1034 + [103.467345, 30.3303200507813],
  1035 + [103.442345, 30.326626203125],
  1036 + [103.413922148438, 30.3308254218751],
  1037 + [103.39298953125, 30.31819846875],
  1038 + [103.357164335938, 30.3035378242188],
  1039 + [103.312323027344, 30.2702907539063],
  1040 + [103.307345, 30.263843],
  1041 + [103.25625125, 30.2574513984375],
  1042 + [103.222345, 30.2151125312501],
  1043 + [103.202899199219, 30.2393971992188],
  1044 + [103.1839465625, 30.2545729804688],
  1045 + [103.155213652344, 30.2186916328126],
  1046 + [103.127345, 30.2138430000001],
  1047 + [103.087567167969, 30.2206008125001],
  1048 + [103.07298953125, 30.2394875312501],
  1049 + [103.067345, 30.243843],
  1050 + [103.0608996875, 30.2722194648438],
  1051 + [103.063587675781, 30.2938430000001],
  1052 + [103.061441679688, 30.3111086250001],
  1053 + [103.123924589844, 30.3611428046876],
  1054 + [103.114879179688, 30.4338600898438],
  1055 + [103.127345, 30.4438430000001]
  1056 + ]
  1057 + ]
  1058 + ]
  1059 + }
  1060 + },
  1061 + {
  1062 + "type": "Feature",
  1063 + "properties": { "name": "郫县" },
  1064 + "geometry": {
  1065 + "type": "MultiPolygon",
  1066 + "coordinates": [
  1067 + [
  1068 + [
  1069 + [103.787100859375, 30.9512038398437],
  1070 + [103.832135039063, 30.9380739570313],
  1071 + [103.852906523438, 30.9411428046876],
  1072 + [103.897345, 30.9338430000001],
  1073 + [103.897345, 30.923843],
  1074 + [103.907345, 30.923843],
  1075 + [103.917345, 30.923843],
  1076 + [103.921429472656, 30.9179274726563],
  1077 + [103.948099394531, 30.8995143867188],
  1078 + [103.939791289063, 30.8624489570313],
  1079 + [103.977706328125, 30.8330617500001],
  1080 + [104.019056425781, 30.8175905585938],
  1081 + [104.033260527344, 30.7597585273437],
  1082 + [104.037345, 30.753843],
  1083 + [104.0341809375, 30.73212425],
  1084 + [104.000716582031, 30.7653542304688],
  1085 + [103.994801054688, 30.7363869453125],
  1086 + [103.959888945313, 30.7312990546876],
  1087 + [103.957345, 30.723843],
  1088 + [103.947345, 30.723843],
  1089 + [103.94099734375, 30.7317702460938],
  1090 + [103.895206328125, 30.7510646796876],
  1091 + [103.86705203125, 30.747563703125],
  1092 + [103.801607695313, 30.7860329414063],
  1093 + [103.782899199219, 30.8093971992188],
  1094 + [103.761790800781, 30.8182888007813],
  1095 + [103.752899199219, 30.8293971992187],
  1096 + [103.721790800781, 30.8482888007813],
  1097 + [103.717345, 30.8638430000001],
  1098 + [103.753616972656, 30.8881667304688],
  1099 + [103.751160917969, 30.8991213203126],
  1100 + [103.763260527344, 30.9279274726563],
  1101 + [103.771429472656, 30.9597585273438],
  1102 + [103.777345, 30.963843],
  1103 + [103.787100859375, 30.9512038398437]
  1104 + ]
  1105 + ]
  1106 + ]
  1107 + }
  1108 + }
  1109 + ]
  1110 + }
  1111 +
\ No newline at end of file
... ...
  1 +import { ConfigType, PackagesCategoryEnum, ChartFrameEnum } from '@/packages/index.d'
  2 +import { ChatCategoryEnum, ChatCategoryEnumName } from '@/packages/components/Charts/index.d'
  3 +import { useWidgetKey } from '@/packages/external/useWidgetKey'
  4 +
  5 +const { key, conKey, chartKey } = useWidgetKey('AddThreeDimensionalMap', true)
  6 +
  7 +export const AddThreeDimensionalMapConfig: ConfigType = {
  8 + key,
  9 + chartKey,
  10 + conKey,
  11 + title: '3d地图',
  12 + category: ChatCategoryEnum.MAP,
  13 + categoryName: ChatCategoryEnumName.MAP,
  14 + package: PackagesCategoryEnum.CHARTS,
  15 + chartFrame: ChartFrameEnum.COMMON,
  16 + image: 'map.png'
  17 +}
... ...
  1 +<template>
  2 + <!-- 原生方式,没有使用vue-echarts -->
  3 + <div :style="`width:${w}px;height:${h}px;`" ref="map3DRef"></div>
  4 +</template>
  5 +
  6 +<script setup lang="ts">
  7 +import { onMounted, ref, nextTick, PropType, toRefs, watch } from 'vue'
  8 +import * as echarts from 'echarts'
  9 +import { registerMap } from 'echarts/core'
  10 +import 'echarts-gl'
  11 +import config from './config'
  12 +import { dataMaps } from './mock'
  13 +
  14 +const props = defineProps({
  15 + chartConfig: {
  16 + type: Object as PropType<config>,
  17 + required: true
  18 + }
  19 +})
  20 +
  21 +const { w, h } = toRefs(props.chartConfig.attr)
  22 +
  23 +const map3DRef = ref()
  24 +
  25 +const chartInstance = ref()
  26 +
  27 +//动态获取geojson文件进行注册地图
  28 +const getGeojson = (regionId: string) => {
  29 + try {
  30 + return new Promise<boolean>(resolve => {
  31 + import(`../OverrideMapBase/mapGeojson/${regionId}.json`).then(data => {
  32 + registerMap(regionId, { geoJSON: data.default as any, specialAreas: {} })
  33 + resolve(true)
  34 + })
  35 + })
  36 + } catch (e) {
  37 + console.log(e)
  38 + }
  39 +}
  40 +
  41 +watch(
  42 + () => w.value,
  43 + (value: number) => {
  44 + chartInstance.value.resize({
  45 + width: value + 'px',
  46 + height: h.value + 'px'
  47 + })
  48 + }
  49 +)
  50 +
  51 +const initMap = async () => {
  52 + chartInstance.value = echarts.init(map3DRef.value)
  53 + await nextTick()
  54 + await getGeojson(props.chartConfig.option.mapRegion.adcode)
  55 + await nextTick().then(() => {
  56 + vEchartsSetOption(props.chartConfig.option)
  57 + })
  58 +
  59 + chartInstance.value.on('click', (e: any) => {
  60 + console.log(e)
  61 + })
  62 +}
  63 +
  64 +// 手动触发渲染
  65 +const vEchartsSetOption = (option: any) => {
  66 + chartInstance.value.clear()
  67 + chartInstance.value.setOption(option)
  68 +}
  69 +
  70 +onMounted(() => {
  71 + initMap()
  72 +})
  73 +
  74 +//监听地图展示区域发生变化
  75 +watch(
  76 + () => `${props.chartConfig.option.mapRegion.adcode}`,
  77 + async (newData: any) => {
  78 + try {
  79 + await getGeojson(newData)
  80 + props.chartConfig.option.geo3D.map = newData
  81 + props.chartConfig.option.series.forEach((item: any) => {
  82 + if (item.type === 'map3D') {
  83 + item.map = newData
  84 + item.data = dataMaps
  85 + }
  86 + })
  87 + initMap()
  88 + vEchartsSetOption(props.chartConfig.option)
  89 + } catch (error) {
  90 + console.log(error)
  91 + }
  92 + },
  93 + {
  94 + immediate: true
  95 + }
  96 +)
  97 +
  98 +// 监听地图右侧配置项变化
  99 +watch(
  100 + props.chartConfig.option,
  101 + newData => {
  102 + try {
  103 + nextTick(() => {
  104 + initMap()
  105 + vEchartsSetOption(newData)
  106 + })
  107 + } catch (error) {
  108 + console.log(error)
  109 + }
  110 + },
  111 + {
  112 + deep: true
  113 + }
  114 +)
  115 +</script>
... ...
  1 +export const dataMaps = [
  2 + {
  3 + name: '北京',
  4 + value: '293',
  5 + height: 2.93
  6 + },
  7 + {
  8 + name: '天津',
  9 + value: '217',
  10 + height: 2.17
  11 + },
  12 + {
  13 + name: '河北',
  14 + value: '67',
  15 + height: 0.67
  16 + },
  17 + {
  18 + name: '山西',
  19 + value: '222',
  20 + height: 2.22
  21 + },
  22 + {
  23 + name: '内蒙古',
  24 + value: '52',
  25 + height: 0.52
  26 + },
  27 + {
  28 + name: '辽宁',
  29 + value: '270',
  30 + height: 2.7
  31 + },
  32 + {
  33 + name: '吉林',
  34 + value: '249',
  35 + height: 2.49
  36 + },
  37 + {
  38 + name: '黑龙江',
  39 + value: '218',
  40 + height: 2.18
  41 + },
  42 + {
  43 + name: '上海',
  44 + value: '71',
  45 + height: 0.71
  46 + },
  47 + {
  48 + name: '江苏',
  49 + value: '178',
  50 + height: 1.78
  51 + },
  52 + {
  53 + name: '浙江',
  54 + value: '263',
  55 + height: 2.63
  56 + },
  57 + {
  58 + name: '安徽',
  59 + value: '153',
  60 + height: 1.53
  61 + },
  62 + {
  63 + name: '福建',
  64 + value: '1',
  65 + height: 0.01
  66 + },
  67 + {
  68 + name: '江西',
  69 + value: '298',
  70 + height: 2.98
  71 + },
  72 + {
  73 + name: '山东',
  74 + value: '98',
  75 + height: 0.98
  76 + },
  77 + {
  78 + name: '河南',
  79 + value: '161',
  80 + height: 1.61
  81 + },
  82 + {
  83 + name: '湖北',
  84 + value: '69',
  85 + height: 0.69
  86 + },
  87 + {
  88 + name: '湖南',
  89 + value: '73',
  90 + height: 0.73
  91 + },
  92 + {
  93 + name: '重庆',
  94 + value: '188',
  95 + height: 1.88
  96 + },
  97 + {
  98 + name: '四川',
  99 + value: '215',
  100 + height: 2.15
  101 + },
  102 + {
  103 + name: '贵州',
  104 + value: '119',
  105 + height: 1.19
  106 + },
  107 + {
  108 + name: '云南',
  109 + value: '18',
  110 + height: 0.18
  111 + },
  112 + {
  113 + name: '西藏',
  114 + value: '13',
  115 + height: 0.13
  116 + },
  117 + {
  118 + name: '陕西',
  119 + value: '297',
  120 + height: 2.97
  121 + },
  122 + {
  123 + name: '甘肃',
  124 + value: '265',
  125 + height: 2.65
  126 + },
  127 + {
  128 + name: '青海',
  129 + value: '292',
  130 + height: 2.92
  131 + },
  132 + {
  133 + name: '宁夏',
  134 + value: '264',
  135 + height: 2.64
  136 + },
  137 + {
  138 + name: '新疆',
  139 + value: '215',
  140 + height: 2.15
  141 + },
  142 + {
  143 + name: '广东',
  144 + value: '259',
  145 + height: 2.59
  146 + },
  147 + {
  148 + name: '广西',
  149 + value: '300',
  150 + height: 3
  151 + },
  152 + {
  153 + name: '海南',
  154 + value: '219',
  155 + height: 2.19
  156 + },
  157 + {
  158 + name: '台湾',
  159 + value: '242',
  160 + height: 2.42
  161 + }
  162 +]
... ...
... ... @@ -2,19 +2,22 @@
2 2 import { EPackagesType } from '@/packages/components/external/types'
3 3 // import { ComposesList } from '@/packages/components/external/Composes'//此项目扩展侧边栏功能,保留待用
4 4 import { ConfigType, PackagesCategoryEnum } from '@/packages/index.d'
5   -import { PickIconConfig } from '@/packages/components/external/Decorates/Mores/PickIcon'
6   -import { WeatherConfig } from '@/packages/components/external/Decorates/Mores/Weather'
7 5 import { OverrideImageConfig } from '@/packages/components/external/Informations/Mores/OverrideImage'
8 6 import { OverrideCarouselConfig } from '@/packages/components/external/Informations/Mores/OverrideCarousel'
9 7 import { OverrideSelectConfig } from '@/packages/components/external/Informations/Inputs/OverrideSelect'
10 8 import { OverrideInputsDateConfig } from '@/packages/components/external/Informations/Inputs/OverrideInputsDate'
11 9 import { OverrideInputsTabConfig } from '@/packages/components/external/Informations/Inputs/OverrideInputsTab'
12 10 import { OverrideIframeConfig } from '@/packages/components/external/Informations/Mores/OverrideIframe'
13   -import { ButtonConfig } from '@/packages/components/external/Informations/Inputs/Button'
14   -import { TreeConfig } from '@/packages/components/external/Informations/Inputs/Tree'
15 11 import { OverrideTextCommonConfig } from '@/packages/components/external/Informations/Texts/OverrideTextCommon'
16 12 import { OverrideTextBarrageConfig } from '@/packages/components/external/Informations/Texts/OverrideTextBarrage'
17 13 import { OverrideTextGradientConfig } from '@/packages/components/external/Informations/Texts/OverrideTextGradient'
  14 +import { OverrideVideoConfig } from '@/packages/components/external/Informations/Mores/OverrideVideo'
  15 +import { ButtonConfig } from '@/packages/components/external/Informations/Inputs/Button'
  16 +import { TreeConfig } from '@/packages/components/external/Informations/Inputs/Tree'
  17 +import { CameraConfig } from '@/packages/components/external/Informations/Mores/Camera'
  18 +import { SingleCameraConfig } from '@/packages/components/external/Informations/Mores/SingleCamera'
  19 +import { OverrideILoadConfigurationframeConfig } from '@/packages/components/external/Informations/Mores/OverrideILoadConfigurationframe'
  20 +import { CustomEchartsConfig } from '@/packages/components/external/Informations/Mores/CustomEcharts'
18 21 import { OverrideBarCommonConfig } from '@/packages/components/external/Charts/Bars/OverrideBarCommon'
19 22 import { OverrideLineCommonConfig } from '@/packages/components/external/Charts/Lines/OverrideLineCommon'
20 23 import { OverrideLineGradientsConfig } from '@/packages/components/external/Charts/Lines/OverrideLineGradients'
... ... @@ -22,10 +25,12 @@ import { OverrideProcessConfig } from '@/packages/components/external/Charts/Mor
22 25 import { OverridePieCircleConfig } from '@/packages/components/external/Charts/Pies/OverridePieCircle'
23 26 import { OverrideMapBaseConfig } from '@/packages/components/external/Charts/Maps/OverrideMapBase'
24 27 import { OverrideMapAmapConfig } from '@/packages/components/external/Charts/Maps/OverrideMapAmap'
25   -import { OverrideVideoConfig } from '@/packages/components/external/Informations/Mores/OverrideVideo'
  28 +import { AddThreeDimensionalMapConfig } from '@/packages/components/external/Charts/Maps/AddThreeDimensionalMap'
26 29 import { OverrideWaterPoloConfig } from '@/packages/components/external/Charts/Mores/OverrideWaterPolo'
27 30 import { OverrideDialConfig } from '@/packages/components/external/Charts/Mores/OverrideDial'
28 31 import { OverrideLineRealTimeConfig } from '@/packages/components/external/Charts/Lines/OverrideLineRealTime'
  32 +import { PickIconConfig } from '@/packages/components/external/Decorates/Mores/PickIcon'
  33 +import { WeatherConfig } from '@/packages/components/external/Decorates/Mores/Weather'
29 34 import { ThreeDimensionalConfig } from '@/packages/components/external/Decorates/Three/ThreeDimensional'
30 35 import { Headline1Config } from '@/packages/components/external/Decorates/Headline/Headline1'
31 36 import { Headline2Config } from '@/packages/components/external/Decorates/Headline/Headline2'
... ... @@ -44,10 +49,7 @@ import { Decorates09Config } from '@/packages/components/external/Decorates/Deco
44 49 import { Decorates10Config } from '@/packages/components/external/Decorates/Decorates/Decorates10'
45 50 import { Decorates11Config } from '@/packages/components/external/Decorates/Decorates/Decorates11'
46 51 import { Decorates12Config } from '@/packages/components/external/Decorates/Decorates/Decorates12'
47   -import { CameraConfig } from '@/packages/components/external/Informations/Mores/Camera'
48   -import { SingleCameraConfig } from '@/packages/components/external/Informations/Mores/SingleCamera'
49   -import { OverrideILoadConfigurationframeConfig } from '@/packages/components/external/Informations/Mores/OverrideILoadConfigurationframe'
50   -import { CustomEchartsConfig } from '@/packages/components/external/Informations/Mores/CustomEcharts'
  52 +
51 53
52 54 /**
53 55 * 重写动态注入
... ... @@ -106,6 +108,7 @@ export function useInjectLib(packagesList: EPackagesType) {
106 108 addWidgetToCategoryByCategoryName(packagesList, PackagesCategoryEnum.CHARTS, OverridePieCircleConfig)//重写图表下的饼图
107 109 addWidgetToCategoryByCategoryName(packagesList, PackagesCategoryEnum.CHARTS, OverrideMapBaseConfig)//重写图表下的地图
108 110 addWidgetToCategoryByCategoryName(packagesList, PackagesCategoryEnum.CHARTS, OverrideMapAmapConfig)//重写图表下的高德地图
  111 + addWidgetToCategoryByCategoryName(packagesList, PackagesCategoryEnum.CHARTS, AddThreeDimensionalMapConfig)//新增图表下的3d echarts地图
109 112 addWidgetToCategoryByCategoryName(packagesList, PackagesCategoryEnum.CHARTS, OverrideWaterPoloConfig)//重写图表下的水球图
110 113 addWidgetToCategoryByCategoryName(packagesList, PackagesCategoryEnum.CHARTS, OverrideDialConfig)//重写图表下的表盘
111 114 //
... ...