refactor(views): 重组页面目录并调整路由引用
- 页面按功能归入 dashboard、login、workspace、system、demo、internal - 数据大屏移入示例目录,错误页、内嵌页与刷新中转移入 internal - 个人中心与我的通知移入 workspace,统一认证回调移入 login - 应用中心移入 workspace,菜单组件值 iframe 解析到 internal/iframe - 在线人数函数更名,未收到推送时显示占位符
This commit is contained in:
1 parent
4e7ac8c08e
commit
9cddb95fb7
54 files changed
+783
-95
No files matched your search
File diff suppressed because it is too large.
Load diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,14 @@
|
||||
@font-face {
|
||||
font-family: YouSheBiaoTiHei;
|
||||
src: url("./YouSheBiaoTiHei.woff");
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: MetroDF;
|
||||
src: url("./MetroDF.woff");
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: DIN;
|
||||
src: url("./DIN.woff");
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 809 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 5.6 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 1.5 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 41 KiB |
@@ -0,0 +1,129 @@
|
||||
// 导入字体文件
|
||||
@use "../fonts/font";
|
||||
|
||||
// 定义公共样式的Mixin
|
||||
@mixin head-styles($skew-direction, $margin-side, $after-position) {
|
||||
&::before {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
z-index: -1;
|
||||
margin-top: var(--padding-size);
|
||||
content: "";
|
||||
background-color: var(--bg-fill-color);
|
||||
transform: skewX($skew-direction);
|
||||
#{$margin-side}: var(--padding-size);
|
||||
}
|
||||
|
||||
&::after {
|
||||
position: absolute;
|
||||
z-index: -1;
|
||||
width: 100px;
|
||||
height: 100%;
|
||||
content: "";
|
||||
background-color: var(--bg-fill-color);
|
||||
#{$after-position}: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.dataScreen-container {
|
||||
--bg-fill-color: rgb(28 58 160 / 100%);
|
||||
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow: hidden;
|
||||
background: url("../images/bg.webp") center;
|
||||
background-size: cover;
|
||||
}
|
||||
|
||||
.dataScreen-header {
|
||||
position: relative;
|
||||
height: 60px;
|
||||
background: url("../images/header-bg.webp") 50%;
|
||||
background-size: cover;
|
||||
// padding: 0 10px;
|
||||
--padding-size: 10px;
|
||||
|
||||
.title {
|
||||
position: relative;
|
||||
top: -8px;
|
||||
// w="[50%]" text-center
|
||||
width: 50%;
|
||||
font-family: YouSheBiaoTiHei, Arial, sans-serif;
|
||||
font-size: 38px;
|
||||
color: #00eaff;
|
||||
text-align: center;
|
||||
letter-spacing: 8px;
|
||||
}
|
||||
|
||||
.leftHead,
|
||||
.rightHead {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
padding-top: var(--padding-size);
|
||||
}
|
||||
|
||||
// 应用Mixin
|
||||
.leftHead {
|
||||
@include head-styles(45deg, margin-right, left);
|
||||
}
|
||||
|
||||
.rightHead {
|
||||
@include head-styles(-45deg, margin-left, right);
|
||||
|
||||
.dateTime {
|
||||
display: flex;
|
||||
flex-direction: row-reverse;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
padding-right: 10px;
|
||||
font-family: YouSheBiaoTiHei, Arial, sans-serif;
|
||||
font-size: 24px;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
|
||||
.lines {
|
||||
position: absolute;
|
||||
top: -3px;
|
||||
width: 140px;
|
||||
height: 6px;
|
||||
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIwAAAAGCAYAAAAR63aAAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMTQyIDc5LjE2MDkyNCwgMjAxNy8wNy8xMy0wMTowNjozOSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTggKFdpbmRvd3MpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOkFDRTEzN0RDOTg3OTExRUM5RTgzQ0U4QUEzRjc2RTRFIiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOkFDRTEzN0REOTg3OTExRUM5RTgzQ0U4QUEzRjc2RTRFIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6QUNFMTM3REE5ODc5MTFFQzlFODNDRThBQTNGNzZFNEUiIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6QUNFMTM3REI5ODc5MTFFQzlFODNDRThBQTNGNzZFNEUiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz5uuACcAAAC/0lEQVR42oRXOZIUMRCsnCDwl/exJi4eeHyA/QLe/IiPrInXiY46stRBMMa2Wi3VkZV1LOw3P8LsjbTP4/lpPG0892++cC5gIC1/vgTjzPhufpZyN87M51X7iHMpJ+66nKv07Pus9bqP/ZyfLv9+LSvv8pc/8Z3GC/aYz5RX+uf7XD5YvtxkyVlT/b63ZFwcOrqPW/98Oi4XG45YroVv28+H+0n3IWyJGBX+cV/2Gn6KIxpeSydQsc74q1y8j5PPsfz2Yfz5Ofa/pgL3cRNkB5B2J0sa5Tfoq7A85KQBsp/XhFCxt5xGOUgBtBuBtGtaCUwy2AY8I+W2ucwgpHJ/S0NKg79bavAduE7FyFzwddi3/HDyN6zCjr2ABrARU/CzCjTDWlglVWpmf72wZWATLaKZpMFGV0lX16tQLEIZXxZHaH9mIrxW2F2BsTxD50mcLTj2mSRFQenBk7vLaZgK3bbWnrq/cT1k6Fl3POQEAzcG6Kfp9IMTTOIIr26dQrIGOwdR/kTwxckEXW0GVDqPYJevgSO19Iz9iEtPuIP5UcFTn59nJfXaAUsEisgwu9kVrx7zL4+KJbPs8ciKuwy2PKxqQvW2kYmse7TOaBiVPQpzb39CbNPKJ05XJvNm9yQYgzgs3USB0rIsEoOSIlG2UQRtZScZhRaQXhthGkK1s1Vlb4ElDa1g8agu6Gh6LDxK0IQsX6R7CUnZrN2JsS2ehHlGCYokgzKfdxCzImTbiPJXIKEX1MyUHkFJbFhrY//In2wV6zxkxpAk17ZCSl6CHVRY2q553+uLgIfCht4rwZOwlMQQ29hZc6/YB9/sTgpq69f5CKhUrIxv8s7ZNGmIe3vODPJWL8PQrznDfHdXX8efF57ZjEa/NjnUaMLGVMFJqqf0a5kOijm7ymW4qRlciFLKLCnt8BJCswirFq87TpokmlgK+98v7tcgS5kn2NJNQLwORh+MoZ+J+euch/QfArbKzWyLVRRqTsHZKdiHRY2RVjXF3fW9j9fnWP74K8AA3scr31D4jAoAAAAASUVORK5CYII=");
|
||||
}
|
||||
|
||||
.ray {
|
||||
position: absolute;
|
||||
bottom: -26px;
|
||||
z-index: -1;
|
||||
width: 100%;
|
||||
height: 56px;
|
||||
background-image: url("../images/ray.webp");
|
||||
background-position: 100px;
|
||||
}
|
||||
}
|
||||
|
||||
.leftChart,
|
||||
.rightChart {
|
||||
display: flex;
|
||||
flex: 1;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.centerChart {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
justify-content: space-between;
|
||||
width: 50%;
|
||||
|
||||
.map {
|
||||
height: 75%;
|
||||
}
|
||||
|
||||
.vehicleCharging {
|
||||
height: 25%;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,184 @@
|
||||
<template>
|
||||
<div
|
||||
v-if="border"
|
||||
rounded="[4px]"
|
||||
p-x-2
|
||||
p-y-3
|
||||
wh-full
|
||||
relative
|
||||
z-90
|
||||
class="border border-[#2E6099] charts-bg"
|
||||
flex="~ col"
|
||||
>
|
||||
<!-- 边框装饰 -->
|
||||
<div
|
||||
v-for="item in 4"
|
||||
:key="item"
|
||||
class="ornamental"
|
||||
:style="{ borderColor: ornamentalColor }"
|
||||
/>
|
||||
<slot name="before"></slot>
|
||||
<div ref="chart" wh-full />
|
||||
<slot name="after"></slot>
|
||||
</div>
|
||||
<div v-else ref="chart" wh-full />
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { useTemplateRef } from "vue";
|
||||
|
||||
/** 核心类型 */
|
||||
import type { EChartsOption } from "echarts";
|
||||
import type { EChartsType } from "echarts/core";
|
||||
|
||||
/** 核心模块 */
|
||||
import * as echarts from "echarts/core";
|
||||
/** 图表类型(按需注册) */
|
||||
import {
|
||||
BarChart,
|
||||
PieChart,
|
||||
LineChart,
|
||||
LinesChart,
|
||||
RadarChart,
|
||||
ScatterChart,
|
||||
EffectScatterChart,
|
||||
} from "echarts/charts";
|
||||
/**功能组件(按需注册) */
|
||||
import {
|
||||
GridComponent, // 直角坐标系网格
|
||||
LegendComponent, // 图例组件
|
||||
TooltipComponent, // 提示框组件
|
||||
TitleComponent, // 标题组件
|
||||
GeoComponent, // 地理坐标系组件
|
||||
} from "echarts/components";
|
||||
|
||||
/** 渲染器 */
|
||||
import { CanvasRenderer } from "echarts/renderers"; // 使用Canvas渲染
|
||||
|
||||
/** 注册必需组件(按需增减) */
|
||||
echarts.use([
|
||||
/** 渲染器 */
|
||||
CanvasRenderer,
|
||||
|
||||
TitleComponent, // 标题
|
||||
TooltipComponent, // 提示框
|
||||
GridComponent, // 网格系统
|
||||
LegendComponent, // 图例
|
||||
|
||||
/** 图表类型 */
|
||||
BarChart, // 柱状图
|
||||
PieChart, // 饼图
|
||||
LineChart, // 折线图
|
||||
LinesChart, // 折线图
|
||||
RadarChart, // 雷达图
|
||||
ScatterChart, // 散点图
|
||||
GeoComponent, // 地理坐标系
|
||||
EffectScatterChart, // 带有涟漪效果的散点图
|
||||
]);
|
||||
|
||||
defineOptions({ name: "BaseChart" });
|
||||
|
||||
/**
|
||||
* 数据大屏图表容器:主题、边框与装饰色
|
||||
*/
|
||||
const {
|
||||
theme = "light",
|
||||
border = true,
|
||||
ornamentalColor = "#7ce7fd",
|
||||
} = defineProps({
|
||||
theme: { type: String },
|
||||
border: { type: Boolean },
|
||||
ornamentalColor: { type: String },
|
||||
});
|
||||
|
||||
/**
|
||||
* 图表初始化完成后回传实例
|
||||
*/
|
||||
const emit = defineEmits<{
|
||||
(e: "onload", v: EChartsType): void;
|
||||
}>();
|
||||
|
||||
const chartRef = useTemplateRef<HTMLDivElement>("chart");
|
||||
const chartInstance = ref<EChartsType>();
|
||||
|
||||
/** 初始化图表实例 */
|
||||
const init = async () => {
|
||||
await nextTick();
|
||||
if (!chartRef.value) return;
|
||||
|
||||
chartInstance.value = echarts.getInstanceByDom(chartRef.value);
|
||||
if (!chartInstance.value) {
|
||||
chartInstance.value = markRaw(
|
||||
echarts.init(chartRef.value, theme, {
|
||||
renderer: "canvas", // 指定渲染模式(canvas性能更好)
|
||||
})
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
/** 初始化配置(清空后设置) */
|
||||
const initOptions = async (options: EChartsOption) => {
|
||||
await nextTick();
|
||||
chartInstance.value?.clear(); // 清空旧配置
|
||||
chartInstance.value?.setOption(options); // 应用新配置
|
||||
emit("onload", chartInstance.value!);
|
||||
};
|
||||
|
||||
/** 更新图表配置(增量更新) */
|
||||
const updateCharts = async (options: EChartsOption) => {
|
||||
await nextTick();
|
||||
chartInstance.value?.setOption(options);
|
||||
// chartInstance.value?.hideLoading();
|
||||
};
|
||||
|
||||
onMounted(() => init());
|
||||
|
||||
onBeforeUnmount(() => chartInstance.value?.dispose());
|
||||
|
||||
/**
|
||||
* 暴露图表实例与初始化、更新方法供父组件调用
|
||||
*/
|
||||
defineExpose({
|
||||
echarts,
|
||||
initOptions,
|
||||
updateCharts,
|
||||
});
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.charts-bg {
|
||||
background: rgb(0 24 106 / 40%) url("../assets/images/line.webp");
|
||||
}
|
||||
|
||||
.ornamental {
|
||||
position: absolute;
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
border: 3px solid;
|
||||
border-right: none;
|
||||
border-bottom: none;
|
||||
border-radius: 4px 0;
|
||||
|
||||
&:nth-child(1) {
|
||||
top: -2px;
|
||||
left: -2px;
|
||||
}
|
||||
|
||||
&:nth-child(2) {
|
||||
top: -2px;
|
||||
right: -2px;
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
|
||||
&:nth-child(3) {
|
||||
bottom: -2px;
|
||||
left: -2px;
|
||||
transform: rotate(-90deg);
|
||||
}
|
||||
|
||||
&:nth-child(4) {
|
||||
right: -2px;
|
||||
bottom: -2px;
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,90 @@
|
||||
<template>
|
||||
<BaseChart ref="chart" flex-1 />
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import type { EChartsOption } from "echarts";
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "BatteryHealth" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
|
||||
/**
|
||||
* 生成一个100到5000的随机数
|
||||
*/
|
||||
const randomNumber = () => Math.floor(Math.random() * 5000) + 100;
|
||||
|
||||
const healthRanges = ["70-75%", "75-80%", "80-85%", "85-90%", "90-95%", "95-100%"];
|
||||
const healthData = Array.from({ length: healthRanges.length }, () => randomNumber());
|
||||
|
||||
useKeepTicking(() => {
|
||||
chartRef.value?.updateCharts({
|
||||
series: [{ data: Array.from({ length: healthRanges.length }, () => randomNumber()) }],
|
||||
});
|
||||
});
|
||||
|
||||
const options: EChartsOption = {
|
||||
backgroundColor: "transparent",
|
||||
title: {
|
||||
text: "电池健康度",
|
||||
textStyle: {
|
||||
color: "#fff",
|
||||
fontSize: 20,
|
||||
fontFamily: "YouSheBiaoTiHei,Arial,sans-serif",
|
||||
fontWeight: "normal",
|
||||
},
|
||||
top: 0,
|
||||
left: "center",
|
||||
},
|
||||
grid: {
|
||||
left: 0,
|
||||
right: "2%",
|
||||
top: "20%",
|
||||
bottom: 0,
|
||||
},
|
||||
xAxis: {
|
||||
type: "category",
|
||||
data: healthRanges,
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#ffffff", fontSize: 10 },
|
||||
},
|
||||
yAxis: {
|
||||
type: "value",
|
||||
name: "车辆数量",
|
||||
nameTextStyle: { color: "#00ffff" },
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#ffffff" },
|
||||
splitLine: { lineStyle: { color: "rgba(0, 255, 255, 0.1)" } },
|
||||
},
|
||||
series: [
|
||||
{
|
||||
type: "bar",
|
||||
data: healthData,
|
||||
itemStyle: {
|
||||
color: (params) =>
|
||||
["#ff6b6b", "#ffc107", "#28a745", "#00ff7f", "#00ffff", "#007bff"][params.dataIndex],
|
||||
borderRadius: [5, 5, 0, 0],
|
||||
borderWidth: 0,
|
||||
},
|
||||
barWidth: "60%",
|
||||
label: {
|
||||
show: true,
|
||||
color: "#fff",
|
||||
position: "top",
|
||||
formatter: "{c} 辆",
|
||||
},
|
||||
},
|
||||
],
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
backgroundColor: "rgba(26, 35, 50, 0.9)",
|
||||
borderColor: "rgba(0, 255, 255, 0.5)",
|
||||
textStyle: { color: "#ffffff" },
|
||||
},
|
||||
};
|
||||
</script>
|
||||
@@ -0,0 +1,13 @@
|
||||
<template>
|
||||
<div class="centerChart">
|
||||
<!-- 文字滚动 -->
|
||||
<TextCarousel />
|
||||
<div class="vehicleCharging">
|
||||
<!-- 充电数据 -->
|
||||
<VehicleChargingChart />
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
defineOptions({ name: "CenterCharts" });
|
||||
</script>
|
||||
@@ -0,0 +1,46 @@
|
||||
<template>
|
||||
<!-- 头部区域 -->
|
||||
<div class="dataScreen-header">
|
||||
<!-- 头部内容 -->
|
||||
<div flex-center h-full overflow-hidden>
|
||||
<!-- 左侧内容 -->
|
||||
<div class="leftHead"></div>
|
||||
<!-- 中间标题 -->
|
||||
<div class="title">新能源汽车联网平台数据概览</div>
|
||||
<!-- 右侧内容 -->
|
||||
<div class="rightHead">
|
||||
<!-- 实时时间 -->
|
||||
<div class="dateTime">{{ dateTime }}</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 装饰线 -->
|
||||
<div class="lines" left="[10%]" />
|
||||
<div class="lines" right="[10%]" rotate="180" />
|
||||
<div class="ray" />
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "Cephalosome" });
|
||||
|
||||
// 看板时间格式:YYYY-MM-DD HH:mm:ss 周X 上午/下午
|
||||
function formatClock(date: Date): string {
|
||||
const week = ["日", "一", "二", "三", "四", "五", "六"][date.getDay()];
|
||||
const pad = (n: number) => String(n).padStart(2, "0");
|
||||
const meridiem = date.getHours() < 12 ? "上午" : "下午";
|
||||
|
||||
return (
|
||||
`${date.getFullYear()}-${pad(date.getMonth() + 1)}-${pad(date.getDate())} ` +
|
||||
`${pad(date.getHours())}:${pad(date.getMinutes())}:${pad(date.getSeconds())} ` +
|
||||
`周${week} ${meridiem}`
|
||||
);
|
||||
}
|
||||
|
||||
// 获取当前时间
|
||||
const dateTime = ref("加载中...");
|
||||
const getCurrentTime = () => (dateTime.value = formatClock(new Date()));
|
||||
|
||||
// 使用定时器钩子更新时间
|
||||
useKeepTicking(getCurrentTime, 1000);
|
||||
</script>
|
||||
@@ -0,0 +1,92 @@
|
||||
<template>
|
||||
<div class="electricityUsageMode" style="--height: 195px; --width: 280px">
|
||||
<BaseChart ref="chart" @onload="highlightItem" />
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import type { EChartsOption } from "echarts";
|
||||
import { EChartsType } from "echarts/core";
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "ElectricityUsageMode" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
|
||||
const data = ref([
|
||||
{ value: 1048, name: "快充", itemStyle: { color: "#00E676" } }, // 荧光绿
|
||||
{ value: 835, name: "慢充", itemStyle: { color: "#FF4081" } }, // 玫红色
|
||||
{ value: 515, name: "换电", itemStyle: { color: "#536DFE" } }, // 亮蓝色
|
||||
{ value: 178, name: "其他", itemStyle: { color: "#FFD600" } }, // 黄色
|
||||
]);
|
||||
|
||||
const options: EChartsOption = {
|
||||
tooltip: { trigger: "item" },
|
||||
legend: {
|
||||
bottom: 0,
|
||||
left: "center",
|
||||
textStyle: { color: "white" },
|
||||
},
|
||||
series: [
|
||||
{
|
||||
type: "pie",
|
||||
radius: ["40%", "70%"],
|
||||
center: ["50%", "40%"],
|
||||
padAngle: 5,
|
||||
avoidLabelOverlap: false,
|
||||
itemStyle: { borderRadius: 4 },
|
||||
label: { show: false, position: "center" },
|
||||
emphasis: {
|
||||
label: {
|
||||
show: true,
|
||||
color: "#fff",
|
||||
fontSize: 16,
|
||||
fontWeight: "bold",
|
||||
},
|
||||
},
|
||||
labelLine: { show: false },
|
||||
data: data.value,
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
const currentIndex = ref(0);
|
||||
const chartInstance = ref<EChartsType>();
|
||||
|
||||
/**
|
||||
* 高亮指定图表
|
||||
*/
|
||||
const highlightItem = (chart: EChartsType) => {
|
||||
chartInstance.value = chart;
|
||||
};
|
||||
|
||||
useKeepTicking(() => {
|
||||
if (!chartInstance.value) return;
|
||||
|
||||
// 取消之前的高亮
|
||||
chartInstance.value.dispatchAction({ type: "downplay" });
|
||||
|
||||
chartInstance.value.dispatchAction({
|
||||
type: "highlight",
|
||||
seriesIndex: 0,
|
||||
dataIndex: currentIndex.value,
|
||||
});
|
||||
|
||||
// 更新索引
|
||||
currentIndex.value = (currentIndex.value + 1) % data.value.length;
|
||||
});
|
||||
</script>
|
||||
<style scoped lang="scss">
|
||||
.electricityUsageMode {
|
||||
position: absolute;
|
||||
top: calc(-1 * var(--height) - 12px); /* 通过 calc 计算为负值 */
|
||||
left: -1px;
|
||||
width: var(--width);
|
||||
height: var(--height);
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,15 @@
|
||||
<template>
|
||||
<div class="leftChart">
|
||||
<!-- 车辆实时状态 -->
|
||||
<RealTimeStatus />
|
||||
|
||||
<!-- 车辆分布 -->
|
||||
<VehicleDistribution />
|
||||
|
||||
<!-- 区域运营 -->
|
||||
<RegionalOperation />
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
defineOptions({ name: "LeftCharts" });
|
||||
</script>
|
||||
@@ -0,0 +1,97 @@
|
||||
<template>
|
||||
<div absolute inset-0 z-1>
|
||||
<BaseChart ref="chart" :border="false" />
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
import chinaGeoJSON from "../assets/chinaGeoJSON.json";
|
||||
|
||||
import getSeriesData from "../utils/seriesData";
|
||||
import { EChartsOption } from "echarts";
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
const eriesData = getSeriesData(20);
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
const option: EChartsOption = {
|
||||
legend: { show: false },
|
||||
geo: [
|
||||
{
|
||||
map: "china",
|
||||
// zoom: 1.2, // 缩放比例
|
||||
aspectScale: 0.85,
|
||||
layoutCenter: ["50%", "50%"], //地图位置
|
||||
layoutSize: "100%",
|
||||
label: {
|
||||
show: true,
|
||||
color: "#fff",
|
||||
fontSize: 14,
|
||||
},
|
||||
emphasis: {
|
||||
itemStyle: {
|
||||
areaColor: "#409eff",
|
||||
},
|
||||
label: {
|
||||
color: "#fff",
|
||||
},
|
||||
},
|
||||
itemStyle: {
|
||||
areaColor: "rgba(7,21,55,0.8)",
|
||||
borderColor: "#0177ff",
|
||||
borderWidth: 2,
|
||||
shadowColor: "rgba(7,21,55,0.8)",
|
||||
shadowBlur: 10,
|
||||
},
|
||||
roam: true,
|
||||
},
|
||||
],
|
||||
series: [
|
||||
{
|
||||
name: "地点",
|
||||
type: "effectScatter",
|
||||
coordinateSystem: "geo",
|
||||
rippleEffect: { brushType: "stroke" },
|
||||
emphasis: {
|
||||
label: {
|
||||
show: true,
|
||||
position: "right",
|
||||
formatter: "{b}",
|
||||
},
|
||||
},
|
||||
showEffectOn: "render",
|
||||
data: eriesData.cityData,
|
||||
},
|
||||
{
|
||||
name: "线路",
|
||||
type: "lines",
|
||||
coordinateSystem: "geo",
|
||||
effect: {
|
||||
show: true,
|
||||
symbol: "arrow",
|
||||
symbolSize: 5,
|
||||
trailLength: 0,
|
||||
},
|
||||
lineStyle: {
|
||||
color: "#58B3CC",
|
||||
curveness: 0.08,
|
||||
},
|
||||
data: eriesData.moveLines,
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.echarts.registerMap("china", chinaGeoJSON as any);
|
||||
chartRef.value?.initOptions(option);
|
||||
});
|
||||
|
||||
// 定时更新地图图表
|
||||
useKeepTicking(() => {
|
||||
const seriesData = getSeriesData(20);
|
||||
|
||||
chartRef.value?.updateCharts({
|
||||
series: [{ data: seriesData.cityData }, { data: seriesData.moveLines }],
|
||||
});
|
||||
}, 6 * 1000);
|
||||
</script>
|
||||
@@ -0,0 +1,203 @@
|
||||
<template>
|
||||
<BaseChart ref="chart" flex-1 />
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import type { EChartsOption } from "echarts";
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "MileageEnergyConsumption" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
|
||||
/**
|
||||
* 生成一个800到1500的随机数
|
||||
*/
|
||||
const randomMileage = () => Math.floor(Math.random() * (1500 - 800 + 1)) + 800;
|
||||
|
||||
/**
|
||||
* 生成一个15到20的随机数
|
||||
*/
|
||||
const randomEnergy = () => Math.floor(Math.random() * (20 - 15 + 1)) + 15;
|
||||
|
||||
const days = ["周一", "周二", "周三", "周四", "周五", "周六", "周日"];
|
||||
const mileageData = Array.from({ length: 7 }, () => randomMileage());
|
||||
const energyData = Array.from({ length: 7 }, () => randomEnergy());
|
||||
|
||||
useKeepTicking(() => {
|
||||
chartRef.value?.updateCharts({
|
||||
series: [
|
||||
{ data: Array.from({ length: 7 }, () => randomMileage()) },
|
||||
{ data: Array.from({ length: 7 }, () => randomEnergy()) },
|
||||
],
|
||||
});
|
||||
});
|
||||
|
||||
const options: EChartsOption = {
|
||||
backgroundColor: "transparent",
|
||||
animation: true,
|
||||
animationDuration: 1500,
|
||||
animationEasing: "cubicInOut",
|
||||
title: {
|
||||
text: "里程与能耗分析",
|
||||
textStyle: {
|
||||
color: "#fff",
|
||||
fontSize: 20,
|
||||
fontFamily: "YouSheBiaoTiHei,Arial,sans-serif",
|
||||
fontWeight: "normal",
|
||||
},
|
||||
top: 0,
|
||||
left: "center",
|
||||
},
|
||||
grid: {
|
||||
left: 0,
|
||||
right: "2%",
|
||||
top: "20%",
|
||||
bottom: 0,
|
||||
// containLabel: true, // 已过时的方式
|
||||
},
|
||||
xAxis: {
|
||||
type: "category",
|
||||
data: days,
|
||||
axisLine: {
|
||||
lineStyle: {
|
||||
color: "rgba(0, 255, 255, 0.6)",
|
||||
width: 2,
|
||||
},
|
||||
},
|
||||
axisLabel: {
|
||||
color: "#a0e7ff",
|
||||
fontSize: 12,
|
||||
margin: 10,
|
||||
},
|
||||
axisTick: {
|
||||
alignWithLabel: true,
|
||||
lineStyle: {
|
||||
color: "rgba(0, 255, 255, 0.3)",
|
||||
},
|
||||
},
|
||||
},
|
||||
yAxis: [
|
||||
{
|
||||
type: "value",
|
||||
name: "km",
|
||||
nameTextStyle: { color: "#00ff7f" },
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 127, 0.5)" } },
|
||||
axisLabel: { color: "#00ff7f" },
|
||||
splitLine: { show: false },
|
||||
},
|
||||
{
|
||||
type: "value",
|
||||
name: "kWh/100km",
|
||||
nameTextStyle: { color: "#00ffff" },
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#00ffff" },
|
||||
splitLine: { lineStyle: { color: "rgba(0, 255, 255, 0.1)" } },
|
||||
},
|
||||
],
|
||||
series: [
|
||||
{
|
||||
name: "日行驶里程",
|
||||
type: "bar",
|
||||
yAxisIndex: 0,
|
||||
data: mileageData,
|
||||
barWidth: "42%",
|
||||
itemStyle: {
|
||||
color: {
|
||||
type: "linear",
|
||||
x: 0,
|
||||
y: 0,
|
||||
x2: 0,
|
||||
y2: 1,
|
||||
colorStops: [
|
||||
{ offset: 0, color: "#00ff7f" },
|
||||
{ offset: 0.5, color: "rgba(0, 255, 127, 0.7)" },
|
||||
{ offset: 1, color: "rgba(0, 255, 127, 0.3)" },
|
||||
],
|
||||
global: false,
|
||||
},
|
||||
borderRadius: [5, 5, 0, 0],
|
||||
borderWidth: 0,
|
||||
},
|
||||
emphasis: {
|
||||
itemStyle: {
|
||||
shadowBlur: 15,
|
||||
shadowColor: "rgba(0, 255, 127, 0.8)",
|
||||
},
|
||||
},
|
||||
// label: {
|
||||
// show: true,
|
||||
// position: "top",
|
||||
// color: "#00ff7f",
|
||||
// formatter: "{c}",
|
||||
// },
|
||||
z: 2,
|
||||
},
|
||||
{
|
||||
name: "平均能耗",
|
||||
type: "line",
|
||||
smooth: true,
|
||||
yAxisIndex: 1,
|
||||
data: energyData,
|
||||
lineStyle: {
|
||||
color: "#00ffff",
|
||||
width: 3,
|
||||
shadowColor: "rgba(0, 255, 255, 0.5)",
|
||||
shadowBlur: 10,
|
||||
},
|
||||
symbol: "circle",
|
||||
symbolSize: 10,
|
||||
itemStyle: {
|
||||
color: "#00ffff",
|
||||
borderWidth: 2,
|
||||
borderColor: "#0d1825",
|
||||
},
|
||||
emphasis: {
|
||||
scale: 1.5,
|
||||
itemStyle: {
|
||||
borderWidth: 2,
|
||||
borderColor: "#0d1825",
|
||||
shadowBlur: 10,
|
||||
shadowColor: "rgba(0, 255, 255, 0.8)",
|
||||
},
|
||||
},
|
||||
// label: {
|
||||
// show: true,
|
||||
// position: "top",
|
||||
// color: "#00ffff",
|
||||
// formatter: "{c}",
|
||||
// },
|
||||
areaStyle: {
|
||||
color: {
|
||||
type: "linear",
|
||||
x: 0,
|
||||
y: 0,
|
||||
x2: 0,
|
||||
y2: 1,
|
||||
colorStops: [
|
||||
{
|
||||
offset: 0,
|
||||
color: "rgba(0, 255, 255, 0.3)",
|
||||
},
|
||||
{
|
||||
offset: 1,
|
||||
color: "rgba(0, 255, 255, 0.05)",
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
z: 3,
|
||||
},
|
||||
],
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
backgroundColor: "rgba(26, 35, 50, 0.9)",
|
||||
borderColor: "rgba(0, 255, 255, 0.5)",
|
||||
textStyle: { color: "#ffffff" },
|
||||
},
|
||||
};
|
||||
</script>
|
||||
@@ -0,0 +1,85 @@
|
||||
<template>
|
||||
<BaseChart ref="chart" flex-1 />
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { useTemplateRef } from "vue";
|
||||
import { type EChartsOption } from "echarts";
|
||||
|
||||
defineOptions({ name: "RealTimeAlarm" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
|
||||
const options: EChartsOption = {
|
||||
backgroundColor: "transparent",
|
||||
title: {
|
||||
text: "实时告警看板",
|
||||
textStyle: {
|
||||
color: "#fff",
|
||||
fontSize: 20,
|
||||
fontFamily: "YouSheBiaoTiHei,Arial,sans-serif",
|
||||
fontWeight: "normal",
|
||||
},
|
||||
top: 0,
|
||||
left: 0,
|
||||
},
|
||||
radar: {
|
||||
indicator: [
|
||||
{ name: "电池故障", max: 100 },
|
||||
{ name: "电机故障", max: 100 },
|
||||
{ name: "电控故障", max: 100 },
|
||||
{ name: "网络故障", max: 100 },
|
||||
{ name: "传感器故障", max: 100 },
|
||||
{ name: "其他故障", max: 100 },
|
||||
],
|
||||
center: ["50%", "50%"],
|
||||
radius: "70%",
|
||||
axisName: {
|
||||
color: "#ffffff",
|
||||
fontSize: 14,
|
||||
// backgroundColor: "#0175FC",
|
||||
// padding: [5, 5, 3, 5],
|
||||
// borderRadius: 4,
|
||||
},
|
||||
splitLine: {
|
||||
lineStyle: { color: "rgba(0, 255, 255, 0.3)" },
|
||||
},
|
||||
splitArea: {
|
||||
areaStyle: {
|
||||
color: ["rgba(0, 255, 255, 0.1)", "rgba(0, 255, 255, 0.05)"],
|
||||
},
|
||||
},
|
||||
},
|
||||
series: [
|
||||
{
|
||||
type: "radar",
|
||||
data: [
|
||||
{
|
||||
value: [65, 45, 30, 25, 40, 35],
|
||||
name: "故障分布",
|
||||
areaStyle: {
|
||||
color: "rgba(255, 107, 107, 0.3)",
|
||||
},
|
||||
lineStyle: {
|
||||
color: "#ff6b6b",
|
||||
width: 2,
|
||||
},
|
||||
symbol: "circle",
|
||||
symbolSize: 5,
|
||||
itemStyle: {
|
||||
color: "#ff6b6b",
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
tooltip: {
|
||||
backgroundColor: "rgba(26, 35, 50, 0.9)",
|
||||
borderColor: "rgba(0, 255, 255, 0.5)",
|
||||
textStyle: { color: "#ffffff" },
|
||||
},
|
||||
};
|
||||
</script>
|
||||
@@ -0,0 +1,105 @@
|
||||
<template>
|
||||
<BaseChart ref="chart" flex-1 />
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import type { EChartsOption } from "echarts";
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "RealTimeOperation" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
|
||||
// 生成24小时数据
|
||||
const hours = [];
|
||||
const speedData = [];
|
||||
|
||||
for (let i = 0; i < 24; i++) {
|
||||
hours.push(i + ":00");
|
||||
speedData.push(Math.random() * 30 + 40 + Math.sin((i / 24) * Math.PI * 2) * 10);
|
||||
}
|
||||
|
||||
const options: EChartsOption = {
|
||||
backgroundColor: "transparent",
|
||||
title: {
|
||||
text: "实时运行监控",
|
||||
textStyle: {
|
||||
color: "#fff",
|
||||
fontSize: 20,
|
||||
fontFamily: "YouSheBiaoTiHei,Arial,sans-serif",
|
||||
fontWeight: "normal",
|
||||
},
|
||||
top: 0,
|
||||
left: "center",
|
||||
},
|
||||
grid: {
|
||||
left: 0,
|
||||
right: "2%",
|
||||
top: "20%",
|
||||
bottom: 0,
|
||||
},
|
||||
xAxis: {
|
||||
type: "category",
|
||||
data: hours,
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#ffffff", fontSize: 10 },
|
||||
},
|
||||
yAxis: {
|
||||
type: "value",
|
||||
name: "km/h",
|
||||
nameTextStyle: { color: "#00ffff" },
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#ffffff" },
|
||||
splitLine: { lineStyle: { color: "rgba(0, 255, 255, 0.1)" } },
|
||||
},
|
||||
series: [
|
||||
{
|
||||
name: "平均车速",
|
||||
type: "line",
|
||||
data: speedData,
|
||||
smooth: true,
|
||||
lineStyle: {
|
||||
color: "#00ff7f",
|
||||
width: 2,
|
||||
},
|
||||
areaStyle: {
|
||||
color: {
|
||||
type: "linear",
|
||||
x: 0,
|
||||
y: 0,
|
||||
x2: 0,
|
||||
y2: 1,
|
||||
colorStops: [
|
||||
{ offset: 0, color: "rgba(0,202,149,0.5)" },
|
||||
{ offset: 1, color: "rgba(0,202,149,0)" },
|
||||
],
|
||||
global: false,
|
||||
},
|
||||
shadowColor: "rgba(0,202,149, 0.9)",
|
||||
shadowBlur: 20,
|
||||
},
|
||||
},
|
||||
],
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
backgroundColor: "rgba(26, 35, 50, 0.9)",
|
||||
borderColor: "rgba(0, 255, 255, 0.5)",
|
||||
textStyle: { color: "#ffffff" },
|
||||
},
|
||||
};
|
||||
|
||||
useKeepTicking(() => {
|
||||
const newSpeedData = [];
|
||||
|
||||
for (let i = 0; i < 24; i++) {
|
||||
newSpeedData.push(Math.random() * 30 + 40 + Math.sin((i / 24) * Math.PI * 2) * 10);
|
||||
}
|
||||
chartRef.value?.updateCharts({
|
||||
series: [{ data: newSpeedData }],
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@@ -0,0 +1,134 @@
|
||||
<template>
|
||||
<BaseChart ref="chart" h-300px @onload="highlightItem">
|
||||
<template #before>
|
||||
<div pt-10px pb-8px>
|
||||
<div class="digital-display">
|
||||
<div class="digit-item">
|
||||
<span class="digit-value">12,580</span>
|
||||
<span class="digit-label">接入车辆总数</span>
|
||||
</div>
|
||||
<div class="digit-item">
|
||||
<span class="digit-value online">11,245</span>
|
||||
<span class="digit-label">在线车辆数</span>
|
||||
</div>
|
||||
<div class="digit-item">
|
||||
<span class="digit-value offline">1,335</span>
|
||||
<span class="digit-label">离线车辆数</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</BaseChart>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
import { EChartsOption } from "echarts";
|
||||
import { EChartsType } from "echarts/core";
|
||||
|
||||
defineOptions({ name: "RealTimeStatus" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
|
||||
const data = [
|
||||
{ value: 89.4, name: "在线率" },
|
||||
{ value: 10.6, name: "离线率" },
|
||||
];
|
||||
|
||||
const currentIndex = ref(0);
|
||||
const chartInstance = ref<EChartsType>();
|
||||
|
||||
const highlightItem = (chart: EChartsType) => {
|
||||
chartInstance.value = chart;
|
||||
};
|
||||
|
||||
useKeepTicking(() => {
|
||||
if (!chartInstance.value) return;
|
||||
|
||||
// 取消之前的高亮
|
||||
chartInstance.value.dispatchAction({ type: "downplay" });
|
||||
|
||||
chartInstance.value.dispatchAction({
|
||||
type: "highlight",
|
||||
seriesIndex: 0,
|
||||
dataIndex: currentIndex.value,
|
||||
});
|
||||
|
||||
// 更新索引
|
||||
currentIndex.value = (currentIndex.value + 1) % data.length;
|
||||
});
|
||||
|
||||
const options: EChartsOption = {
|
||||
tooltip: { trigger: "item" },
|
||||
legend: {
|
||||
top: "center",
|
||||
right: "10%",
|
||||
orient: "vertical",
|
||||
textStyle: { color: "white" },
|
||||
},
|
||||
series: [
|
||||
{
|
||||
type: "pie",
|
||||
radius: ["60%", "80%"],
|
||||
center: ["40%", "50%"],
|
||||
startAngle: 90,
|
||||
data,
|
||||
label: { color: "white" },
|
||||
},
|
||||
],
|
||||
};
|
||||
</script>
|
||||
<style scoped lang="scss">
|
||||
/* 数字翻牌器 */
|
||||
.digital-display {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
margin-bottom: 15px;
|
||||
|
||||
.digit-item {
|
||||
flex: 1;
|
||||
text-align: center;
|
||||
|
||||
.digit-value {
|
||||
display: block;
|
||||
margin-bottom: 5px;
|
||||
font-family: YouSheBiaoTiHei, Arial, sans-serif;
|
||||
font-size: 1.6rem;
|
||||
color: #fff;
|
||||
text-shadow: 0 0 10px rgb(255 255 255 / 50%);
|
||||
animation: pulse 2s ease-in-out infinite;
|
||||
|
||||
&.online {
|
||||
color: #00ff7f;
|
||||
text-shadow: 0 0 10px rgb(0 255 127 / 50%);
|
||||
}
|
||||
|
||||
&.offline {
|
||||
color: #ff6b6b;
|
||||
text-shadow: 0 0 10px rgb(255 107 107 / 50%);
|
||||
}
|
||||
}
|
||||
|
||||
.digit-label {
|
||||
font-size: 0.85rem;
|
||||
font-weight: 300;
|
||||
color: #e0e0e0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes pulse {
|
||||
0%,
|
||||
100% {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
50% {
|
||||
opacity: 0.7;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,114 @@
|
||||
<template>
|
||||
<BaseChart ref="chart" flex-1 />
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import type { EChartsOption } from "echarts";
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "RegionalOperation" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
|
||||
/**
|
||||
* 生成一个500到3000的随机数
|
||||
*/
|
||||
const randomNum = () => Math.floor(Math.random() * (500 - 3000 + 1)) + 3000;
|
||||
|
||||
const cities = ["北京", "上海", "深圳", "广州", "杭州", "成都", "西安", "武汉", "南京", "重庆"];
|
||||
|
||||
/**
|
||||
* 获取数据
|
||||
*/
|
||||
const getDate = () =>
|
||||
Array.from({ length: cities.length }, () => randomNum()).sort((a, b) => b - a);
|
||||
|
||||
useKeepTicking(() => {
|
||||
chartRef.value?.updateCharts({
|
||||
series: [{ data: getDate() }],
|
||||
});
|
||||
});
|
||||
|
||||
const options: EChartsOption = {
|
||||
backgroundColor: "transparent",
|
||||
title: {
|
||||
text: "区域运营对比",
|
||||
textStyle: {
|
||||
color: "#fff",
|
||||
fontSize: 20,
|
||||
fontFamily: "YouSheBiaoTiHei,Arial,sans-serif",
|
||||
fontWeight: "normal",
|
||||
},
|
||||
top: 0,
|
||||
left: "center",
|
||||
},
|
||||
grid: {
|
||||
left: "10%",
|
||||
right: "2%",
|
||||
top: "13%",
|
||||
bottom: 0,
|
||||
},
|
||||
xAxis: {
|
||||
type: "value",
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#ffffff" },
|
||||
splitLine: { lineStyle: { color: "rgba(0, 255, 255, 0.1)" } },
|
||||
},
|
||||
yAxis: {
|
||||
type: "category",
|
||||
data: cities,
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#ffffff" },
|
||||
},
|
||||
series: [
|
||||
{
|
||||
name: "车辆数",
|
||||
type: "bar",
|
||||
data: getDate(),
|
||||
itemStyle: {
|
||||
color: {
|
||||
type: "linear",
|
||||
x: 0,
|
||||
y: 0,
|
||||
x2: 1,
|
||||
y2: 0,
|
||||
colorStops: [
|
||||
{ offset: 0, color: "#00ff7f" },
|
||||
{ offset: 0.7, color: "#00b7ff" },
|
||||
{ offset: 1, color: "#409eff" },
|
||||
],
|
||||
global: false,
|
||||
},
|
||||
borderRadius: [0, 4, 4, 0],
|
||||
borderWidth: 0,
|
||||
shadowColor: "rgba(64, 158, 255, 0.5)",
|
||||
shadowBlur: 10,
|
||||
},
|
||||
label: {
|
||||
show: true,
|
||||
color: "#fff",
|
||||
fontSize: 12,
|
||||
formatter: "{c}",
|
||||
},
|
||||
barWidth: "55%",
|
||||
emphasis: {
|
||||
itemStyle: {
|
||||
shadowColor: "rgba(64, 158, 255, 0.8)",
|
||||
shadowBlur: 10,
|
||||
},
|
||||
},
|
||||
},
|
||||
],
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
backgroundColor: "rgba(26, 35, 50, 0.9)",
|
||||
borderColor: "rgba(0, 255, 255, 0.5)",
|
||||
textStyle: { color: "#ffffff" },
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped lang="scss"></style>
|
||||
@@ -0,0 +1,15 @@
|
||||
<template>
|
||||
<div class="rightChart">
|
||||
<!-- 实时告警看板 -->
|
||||
<RealTimeAlarm />
|
||||
<!-- 实时运行监控 -->
|
||||
<RealTimeOperation />
|
||||
<!-- 里程与能耗分析 -->
|
||||
<MileageEnergyConsumption />
|
||||
<!-- 电池健康度 -->
|
||||
<BatteryHealth />
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
defineOptions({ name: "RightCharts" });
|
||||
</script>
|
||||
@@ -0,0 +1,85 @@
|
||||
<template>
|
||||
<!-- 文字轮播 -->
|
||||
<div class="text-carousel">
|
||||
<transition-group name="carousel" tag="div" class="carousel-container">
|
||||
<div :key="currentIdx" class="text-carousel-item">
|
||||
{{ carouselData[currentIdx] }}
|
||||
</div>
|
||||
</transition-group>
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "TextCarousel" });
|
||||
// 所有轮播数据
|
||||
const carouselData = ref([
|
||||
"全国新能源车在线数量:125945 辆,当前充电中车辆占比 36%",
|
||||
"今日新增行程 67454 公里,减少碳排放 1120 吨",
|
||||
"合肥充电需求飙升!当前 1258 辆车排队等待充电",
|
||||
"实时处理电池异常告警 52 例,安全响应率99.8%",
|
||||
"安徽车辆在线率突破 82%,续航达标率行业领先",
|
||||
"10分钟内完成2510次远程诊断,高效护航出行",
|
||||
]);
|
||||
|
||||
// 当前显示项目索引
|
||||
const currentIdx = ref(0);
|
||||
|
||||
useKeepTicking(() => {
|
||||
currentIdx.value = (currentIdx.value + 1) % carouselData.value.length;
|
||||
}, 5000);
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.text-carousel {
|
||||
height: 52px;
|
||||
overflow: hidden;
|
||||
font-family: DIN, Arial, sans-serif;
|
||||
font-size: 18px;
|
||||
color: #fff;
|
||||
background: linear-gradient(90deg, rgb(64 158 255 / 60%), rgb(64 158 255 / 0%));
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.carousel-container {
|
||||
position: relative;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.text-carousel-item {
|
||||
position: absolute;
|
||||
box-sizing: border-box;
|
||||
width: 100%;
|
||||
padding: 0 20px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
}
|
||||
|
||||
// 轮播动画样式
|
||||
.carousel-enter-active,
|
||||
.carousel-leave-active {
|
||||
transition: all 0.5s ease-in-out;
|
||||
}
|
||||
|
||||
.carousel-enter-from {
|
||||
opacity: 0;
|
||||
transform: translateY(100%);
|
||||
}
|
||||
|
||||
.carousel-leave-to {
|
||||
opacity: 0;
|
||||
transform: translateY(-100%);
|
||||
}
|
||||
|
||||
.carousel-enter-to,
|
||||
.carousel-leave-from {
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,132 @@
|
||||
<template>
|
||||
<BaseChart ref="chart">
|
||||
<template #before>
|
||||
<!-- 用电方式 -->
|
||||
<ElectricityUsageMode />
|
||||
</template>
|
||||
</BaseChart>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
import { type EChartsOption } from "echarts";
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "VehicleChargingChart" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
// 生成一个500到1000的随机数
|
||||
const randomNum = () => Math.floor(Math.random() * 500) + 500;
|
||||
|
||||
const options: EChartsOption = {
|
||||
title: {
|
||||
text: "车辆充电统计",
|
||||
textStyle: {
|
||||
color: "#fff",
|
||||
fontSize: 20,
|
||||
fontFamily: "YouSheBiaoTiHei,Arial,sans-serif",
|
||||
fontWeight: "normal",
|
||||
},
|
||||
top: 0,
|
||||
left: 0,
|
||||
},
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
},
|
||||
grid: {
|
||||
left: "0",
|
||||
right: "0",
|
||||
top: "20%",
|
||||
bottom: "0",
|
||||
},
|
||||
// color: ["#a4d8cc", "#25f3e6"],
|
||||
xAxis: {
|
||||
type: "category",
|
||||
boundaryGap: true, // 两边留白
|
||||
data: Array.from({ length: 24 }, (_, i) => `${i}:00`),
|
||||
axisLabel: {
|
||||
color: "#ccc",
|
||||
fontSize: "12",
|
||||
rotate: 45,
|
||||
},
|
||||
},
|
||||
yAxis: {
|
||||
type: "value",
|
||||
axisLabel: { color: "#ccc", fontSize: "12" },
|
||||
axisLine: {
|
||||
lineStyle: {
|
||||
color: "rgba(160,160,160,0.3)",
|
||||
},
|
||||
},
|
||||
splitLine: {
|
||||
lineStyle: {
|
||||
color: "rgba(0, 255, 255, 0.15)",
|
||||
type: "dashed",
|
||||
},
|
||||
},
|
||||
},
|
||||
series: [
|
||||
{
|
||||
type: "line",
|
||||
name: "充电量(度)",
|
||||
symbol: "circle",
|
||||
symbolSize: 8,
|
||||
itemStyle: {
|
||||
color: "#04eef8",
|
||||
borderWidth: 2,
|
||||
borderColor: "#ffffff",
|
||||
},
|
||||
lineStyle: {
|
||||
width: 4,
|
||||
color: {
|
||||
type: "linear",
|
||||
x: 0,
|
||||
y: 0,
|
||||
x2: 1,
|
||||
y2: 0,
|
||||
colorStops: [
|
||||
{ offset: 0, color: "#04eef8" },
|
||||
{ offset: 1, color: "#047ee8" },
|
||||
],
|
||||
},
|
||||
shadowColor: "rgba(4, 126, 232, 0.5)",
|
||||
shadowBlur: 15,
|
||||
},
|
||||
areaStyle: {
|
||||
color: {
|
||||
type: "linear",
|
||||
x: 0,
|
||||
y: 0,
|
||||
x2: 0,
|
||||
y2: 1,
|
||||
colorStops: [
|
||||
{ offset: 0, color: "rgba(4, 126, 232, 0.8)" },
|
||||
{ offset: 1, color: "rgba(4, 126, 232, 0.1)" },
|
||||
],
|
||||
},
|
||||
},
|
||||
label: {
|
||||
show: true,
|
||||
position: "top",
|
||||
color: "#fff",
|
||||
fontSize: 12,
|
||||
formatter: "{c}",
|
||||
backgroundColor: "rgba(0, 0, 0, 0.3)",
|
||||
padding: [2, 4],
|
||||
borderRadius: 4,
|
||||
},
|
||||
smooth: true,
|
||||
data: Array.from({ length: 24 }, () => randomNum()),
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
useKeepTicking(() => {
|
||||
chartRef.value?.updateCharts({
|
||||
series: [{ data: Array.from({ length: 24 }, () => randomNum()) }],
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@@ -0,0 +1,118 @@
|
||||
<template>
|
||||
<BaseChart ref="chart" flex-1 />
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
import { type EChartsOption } from "echarts";
|
||||
import { city } from "../utils/seriesData";
|
||||
import { useTemplateRef } from "vue";
|
||||
import { useKeepTicking } from "../composables/useKeepTicking";
|
||||
|
||||
defineOptions({ name: "VehicleDistribution" });
|
||||
|
||||
const chartRef = useTemplateRef("chart");
|
||||
|
||||
onMounted(() => {
|
||||
chartRef.value?.initOptions(options);
|
||||
});
|
||||
|
||||
// 生成一个500到2000的数值
|
||||
const randomNum = () => Math.floor(Math.random() * (500 - 2000 + 1)) + 2000;
|
||||
|
||||
const buildGeoData = () =>
|
||||
Array.from({ length: 20 }).map(() => {
|
||||
const cityData = city[Math.floor(Math.random() * city.length)];
|
||||
|
||||
const {
|
||||
name,
|
||||
value: [a, b],
|
||||
} = cityData;
|
||||
|
||||
return {
|
||||
name,
|
||||
value: [a, b, randomNum()],
|
||||
};
|
||||
});
|
||||
|
||||
useKeepTicking(() => {
|
||||
chartRef.value?.updateCharts({
|
||||
series: [{ data: buildGeoData() }],
|
||||
});
|
||||
});
|
||||
|
||||
const options: EChartsOption = {
|
||||
backgroundColor: "transparent",
|
||||
title: {
|
||||
text: "车辆分布热力图",
|
||||
textStyle: {
|
||||
color: "#fff",
|
||||
fontSize: 20,
|
||||
fontFamily: "YouSheBiaoTiHei,Arial,sans-serif",
|
||||
fontWeight: "normal",
|
||||
},
|
||||
top: 0,
|
||||
left: "center",
|
||||
},
|
||||
tooltip: {
|
||||
trigger: "item",
|
||||
backgroundColor: "rgba(26, 35, 50, 0.9)",
|
||||
borderColor: "rgba(0, 255, 255, 0.5)",
|
||||
textStyle: { color: "#ffffff" },
|
||||
formatter(params: any) {
|
||||
return params.name + "<br/>车辆数: " + params.value[2];
|
||||
},
|
||||
},
|
||||
grid: {
|
||||
left: "8%",
|
||||
right: "8%",
|
||||
top: "13%",
|
||||
bottom: 0,
|
||||
},
|
||||
xAxis: {
|
||||
type: "value",
|
||||
name: "经度",
|
||||
nameTextStyle: { color: "#00ffff" },
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#ffffff", fontSize: 10 },
|
||||
splitLine: { lineStyle: { color: "rgba(0, 255, 255, 0.1)" } },
|
||||
min: 100,
|
||||
max: 125,
|
||||
},
|
||||
yAxis: {
|
||||
type: "value",
|
||||
name: "纬度",
|
||||
nameTextStyle: { color: "#00ffff" },
|
||||
axisLine: { lineStyle: { color: "rgba(0, 255, 255, 0.5)" } },
|
||||
axisLabel: { color: "#ffffff", fontSize: 10 },
|
||||
splitLine: { lineStyle: { color: "rgba(0, 255, 255, 0.1)" } },
|
||||
min: 20,
|
||||
max: 50,
|
||||
},
|
||||
series: [
|
||||
{
|
||||
type: "scatter",
|
||||
data: buildGeoData(),
|
||||
symbolSize(val) {
|
||||
return Math.max(val[2] / 100, 8);
|
||||
},
|
||||
itemStyle: {
|
||||
color(params: any) {
|
||||
const colors = ["#00ffff", "#00ff7f", "#ffc107", "#ff6b6b"];
|
||||
const index = Math.floor(params.value[2] / 600);
|
||||
|
||||
return colors[Math.min(index, 3)];
|
||||
},
|
||||
shadowBlur: 10,
|
||||
shadowColor: "#00ffff",
|
||||
opacity: 0.8,
|
||||
},
|
||||
label: {
|
||||
show: true,
|
||||
formatter: "{b}",
|
||||
position: "top",
|
||||
color: "#ffffff",
|
||||
fontSize: 10,
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
||||
</script>
|
||||
@@ -0,0 +1,52 @@
|
||||
import { onMounted, onUnmounted } from "vue";
|
||||
|
||||
/**
|
||||
* 常驻定时器:组件存活期间按固定间隔执行回调,页面隐藏时自动暂停
|
||||
*
|
||||
* @param callback 定时器每次触发时执行的回调
|
||||
* @param interval 间隔毫秒数,默认 3000
|
||||
*/
|
||||
export function useKeepTicking(callback: () => void, interval = 3000) {
|
||||
/** 定时器是否正在运行 */
|
||||
let ticking = false;
|
||||
/** 定时器标识 */
|
||||
let timerId: ReturnType<typeof setInterval> | null = null;
|
||||
|
||||
const startTicker = () => {
|
||||
if (!ticking) {
|
||||
ticking = true;
|
||||
timerId = setInterval(callback, interval);
|
||||
}
|
||||
};
|
||||
|
||||
const stopTicker = () => {
|
||||
if (ticking) {
|
||||
ticking = false;
|
||||
if (timerId) clearInterval(timerId);
|
||||
timerId = null;
|
||||
}
|
||||
};
|
||||
|
||||
const handleVisibilityChange = () => {
|
||||
if (document.hidden) {
|
||||
stopTicker();
|
||||
} else {
|
||||
startTicker();
|
||||
}
|
||||
};
|
||||
|
||||
onMounted(() => {
|
||||
document.addEventListener("visibilitychange", handleVisibilityChange);
|
||||
startTicker();
|
||||
});
|
||||
|
||||
onUnmounted(() => {
|
||||
document.removeEventListener("visibilitychange", handleVisibilityChange);
|
||||
stopTicker();
|
||||
});
|
||||
|
||||
return {
|
||||
startTicker,
|
||||
stopTicker,
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,76 @@
|
||||
<template>
|
||||
<div class="dataScreen-container">
|
||||
<!-- 适配屏幕容器:按 1920×1080 设计稿等比缩放 -->
|
||||
<div v-fit-screen pt-10px flex flex-col>
|
||||
<!-- 头部区域 -->
|
||||
<Cephalosome />
|
||||
|
||||
<!-- 图表区域 -->
|
||||
<div flex-1 p-10px flex gap="10px" relative>
|
||||
<!-- 漂浮地图 -->
|
||||
<MapChart />
|
||||
<!-- 左侧图表 -->
|
||||
<LeftCharts />
|
||||
<!-- 中间图表 -->
|
||||
<CenterCharts />
|
||||
<!-- 右侧图表 -->
|
||||
<RightCharts />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { type Directive } from "vue";
|
||||
|
||||
import "./assets/styles/index.scss";
|
||||
|
||||
defineOptions({ name: "DataScreen" });
|
||||
|
||||
/** 设计稿宽度 */
|
||||
const DESIGN_WIDTH = 1920;
|
||||
|
||||
/** 设计稿高度 */
|
||||
const DESIGN_HEIGHT = 1080;
|
||||
|
||||
/** 元素与 resize 回调的映射,卸载时按引用移除监听 */
|
||||
const resizeHandlers = new WeakMap<HTMLElement, () => void>();
|
||||
|
||||
/**
|
||||
* 按视口与设计稿的较小比例缩放,并平移回视口中心
|
||||
*/
|
||||
function applyScale(el: HTMLElement): void {
|
||||
const scale = Math.min(window.innerWidth / DESIGN_WIDTH, window.innerHeight / DESIGN_HEIGHT);
|
||||
el.style.transform = `scale(${scale}) translate(-50%, -50%)`;
|
||||
}
|
||||
|
||||
/**
|
||||
* 大屏适配指令:元素固定为设计稿尺寸后等比缩放,版式不随窗口比例变形
|
||||
*/
|
||||
const vFitScreen: Directive<HTMLElement> = {
|
||||
mounted(el) {
|
||||
Object.assign(el.style, {
|
||||
position: "fixed",
|
||||
top: "50%",
|
||||
left: "50%",
|
||||
zIndex: "999",
|
||||
width: `${DESIGN_WIDTH}px`,
|
||||
height: `${DESIGN_HEIGHT}px`,
|
||||
transformOrigin: "top left",
|
||||
transition: "all 0.3s",
|
||||
});
|
||||
|
||||
const resize = () => applyScale(el);
|
||||
resizeHandlers.set(el, resize);
|
||||
applyScale(el);
|
||||
window.addEventListener("resize", resize);
|
||||
},
|
||||
unmounted(el) {
|
||||
const resize = resizeHandlers.get(el);
|
||||
if (resize) {
|
||||
window.removeEventListener("resize", resize);
|
||||
resizeHandlers.delete(el);
|
||||
}
|
||||
},
|
||||
};
|
||||
</script>
|
||||
@@ -0,0 +1,421 @@
|
||||
interface City {
|
||||
name: string;
|
||||
value: [number, number, number];
|
||||
symbolSize?: number;
|
||||
itemStyle: { color: string };
|
||||
}
|
||||
|
||||
interface MoveLine {
|
||||
fromName: string;
|
||||
toName: string;
|
||||
coords: [[number, number], [number, number]];
|
||||
}
|
||||
|
||||
export const city: City[] = [
|
||||
{ name: "北京", value: [116.395645, 39.929986, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "上海", value: [121.487899, 31.249162, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "天津", value: [117.210813, 39.14393, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "重庆", value: [106.530635, 29.544606, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "合肥", value: [117.282699, 31.866942, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "安庆", value: [117.058739, 30.537898, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "蚌埠", value: [117.35708, 32.929499, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "亳州", value: [115.787928, 33.871211, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "巢湖", value: [117.88049, 31.608733, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "池州", value: [117.494477, 30.660019, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "滁州", value: [118.32457, 32.317351, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "阜阳", value: [115.820932, 32.901211, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "淮北", value: [116.791447, 33.960023, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "淮南", value: [117.018639, 32.642812, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "黄山", value: [118.29357, 29.734435, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "六安", value: [116.505253, 31.755558, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "马鞍山", value: [118.515882, 31.688528, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宿州", value: [116.988692, 33.636772, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "铜陵", value: [117.819429, 30.94093, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "芜湖", value: [118.384108, 31.36602, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宣城", value: [118.752096, 30.951642, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "福州", value: [119.330221, 26.047125, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "龙岩", value: [117.017997, 25.078685, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "南平", value: [118.181883, 26.643626, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宁德", value: [119.542082, 26.656527, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "莆田", value: [119.077731, 25.44845, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "泉州", value: [118.600362, 24.901652, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "三明", value: [117.642194, 26.270835, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "厦门", value: [118.103886, 24.489231, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "漳州", value: [117.676205, 24.517065, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "兰州", value: [103.823305, 36.064226, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "白银", value: [104.171241, 36.546682, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "定西", value: [104.626638, 35.586056, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "甘南州", value: [102.917442, 34.992211, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "嘉峪关", value: [98.281635, 39.802397, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "金昌", value: [102.208126, 38.516072, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "酒泉", value: [98.508415, 39.741474, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "临夏州", value: [103.215249, 35.598514, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "陇南", value: [104.934573, 33.39448, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "平凉", value: [106.688911, 35.55011, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "庆阳", value: [107.644227, 35.726801, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "天水", value: [105.736932, 34.584319, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "武威", value: [102.640147, 37.933172, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "张掖", value: [100.459892, 38.93932, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "广州", value: [113.30765, 23.120049, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "潮州", value: [116.630076, 23.661812, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "东莞", value: [113.763434, 23.043024, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "佛山", value: [113.134026, 23.035095, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "河源", value: [114.713721, 23.757251, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "惠州", value: [114.410658, 23.11354, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "江门", value: [113.078125, 22.575117, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "揭阳", value: [116.379501, 23.547999, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "茂名", value: [110.931245, 21.668226, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "梅州", value: [116.126403, 24.304571, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "清远", value: [113.040773, 23.698469, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "汕头", value: [116.72865, 23.383908, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "汕尾", value: [115.372924, 22.778731, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "韶关", value: [113.594461, 24.80296, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "深圳", value: [114.025974, 22.546054, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "阳江", value: [111.97701, 21.871517, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "云浮", value: [112.050946, 22.937976, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "湛江", value: [110.365067, 21.257463, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "肇庆", value: [112.479653, 23.078663, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "中山", value: [113.42206, 22.545178, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "珠海", value: [113.562447, 22.256915, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "南宁", value: [108.297234, 22.806493, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "百色", value: [106.631821, 23.901512, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "北海", value: [109.122628, 21.472718, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "崇左", value: [107.357322, 22.415455, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "防城港", value: [108.351791, 21.617398, 15], itemStyle: { color: "#F58158" } },
|
||||
{ name: "桂林", value: [110.26092, 25.262901, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "贵港", value: [109.613708, 23.103373, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "河池", value: [108.069948, 24.699521, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "贺州", value: [111.552594, 24.411054, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "来宾", value: [109.231817, 23.741166, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "柳州", value: [109.422402, 24.329053, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "钦州", value: [108.638798, 21.97335, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "梧州", value: [111.305472, 23.485395, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "玉林", value: [110.151676, 22.643974, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "贵阳", value: [106.709177, 26.629907, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "安顺", value: [105.92827, 26.228595, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "毕节地区", value: [105.300492, 27.302612, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "六盘水", value: [104.852087, 26.591866, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "铜仁地区", value: [109.196161, 27.726271, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "遵义", value: [106.93126, 27.699961, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "黔西南州", value: [104.900558, 25.095148, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "黔东南州", value: [107.985353, 26.583992, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "黔南州", value: [107.523205, 26.264536, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "海口", value: [110.330802, 20.022071, 13], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "白沙", value: [109.358586, 19.216056, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "保亭", value: [109.656113, 18.597592, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "昌江", value: [109.0113, 19.222483, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "儋州", value: [109.413973, 19.571153, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "澄迈", value: [109.996736, 19.693135, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "东方", value: [108.85101, 18.998161, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "定安", value: [110.32009, 19.490991, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "琼海", value: [110.414359, 19.21483, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "琼中", value: [109.861849, 19.039771, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "乐东", value: [109.062698, 18.658614, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "临高", value: [109.724101, 19.805922, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "陵水", value: [109.948661, 18.575985, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "三亚", value: [109.522771, 18.257776, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "屯昌", value: [110.063364, 19.347749, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "万宁", value: [110.292505, 18.839886, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "文昌", value: [110.780909, 19.750947, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "五指山", value: [109.51775, 18.831306, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "石家庄", value: [114.522082, 38.048958, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "保定", value: [115.49481, 38.886565, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "沧州", value: [116.863806, 38.297615, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "承德", value: [117.933822, 40.992521, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "邯郸", value: [114.482694, 36.609308, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "衡水", value: [115.686229, 37.746929, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "廊坊", value: [116.703602, 39.518611, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "秦皇岛", value: [119.604368, 39.945462, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "唐山", value: [118.183451, 39.650531, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "邢台", value: [114.520487, 37.069531, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "张家口", value: [114.893782, 40.811188, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "郑州", value: [113.649644, 34.75661, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "安阳", value: [114.351807, 36.110267, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "鹤壁", value: [114.29777, 35.755426, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "焦作", value: [113.211836, 35.234608, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "开封", value: [114.351642, 34.801854, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "洛阳", value: [112.447525, 34.657368, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "漯河", value: [114.046061, 33.576279, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "南阳", value: [112.542842, 33.01142, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "平顶山", value: [113.300849, 33.745301, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "濮阳", value: [115.026627, 35.753298, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "三门峡", value: [111.181262, 34.78332, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "商丘", value: [115.641886, 34.438589, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "新乡", value: [113.91269, 35.307258, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "信阳", value: [114.085491, 32.128582, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "许昌", value: [113.835312, 34.02674, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "周口", value: [114.654102, 33.623741, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "驻马店", value: [114.049154, 32.983158, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "哈尔滨", value: [126.657717, 45.773225, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "大庆", value: [125.02184, 46.596709, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "大兴安岭地区", value: [124.196104, 51.991789, 10], itemStyle: { color: "#F58158" } },
|
||||
{ name: "鹤岗", value: [130.292472, 47.338666, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "黑河", value: [127.50083, 50.25069, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "鸡西", value: [130.941767, 45.32154, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "佳木斯", value: [130.284735, 46.81378, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "牡丹江", value: [129.608035, 44.588521, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "七台河", value: [131.019048, 45.775005, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "齐齐哈尔", value: [123.987289, 47.3477, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "双鸭山", value: [131.171402, 46.655102, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "绥化", value: [126.989095, 46.646064, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "伊春", value: [128.910766, 47.734685, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "武汉", value: [114.3162, 30.581084, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "鄂州", value: [114.895594, 30.384439, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "恩施", value: [109.517433, 30.308978, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "黄冈", value: [114.906618, 30.446109, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "黄石", value: [115.050683, 30.216127, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "荆门", value: [112.21733, 31.042611, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "荆州", value: [112.241866, 30.332591, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "潜江", value: [112.768768, 30.343116, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "神农架林区", value: [110.487231, 31.595768, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "十堰", value: [110.801229, 32.636994, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "随州", value: [113.379358, 31.717858, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "天门", value: [113.12623, 30.649047, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "仙桃", value: [113.387448, 30.293966, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "咸宁", value: [114.300061, 29.880657, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "襄阳", value: [112.176326, 32.094934, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "孝感", value: [113.935734, 30.927955, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宜昌", value: [111.310981, 30.732758, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "长沙", value: [112.979353, 28.213478, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "常德", value: [111.653718, 29.012149, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "郴州", value: [113.037704, 25.782264, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "衡阳", value: [112.583819, 26.898164, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "怀化", value: [109.986959, 27.557483, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "娄底", value: [111.996396, 27.741073, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "邵阳", value: [111.461525, 27.236811, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "湘潭", value: [112.935556, 27.835095, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "湘西州", value: [109.745746, 28.317951, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "益阳", value: [112.366547, 28.588088, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "永州", value: [111.614648, 26.435972, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "岳阳", value: [113.146196, 29.378007, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "张家界", value: [110.48162, 29.124889, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "株洲", value: [113.131695, 27.827433, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "南京", value: [118.778074, 32.057236, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "常州", value: [119.981861, 31.771397, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "淮安", value: [119.030186, 33.606513, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "连云港", value: [119.173872, 34.601549, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "南通", value: [120.873801, 32.014665, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "苏州", value: [120.619907, 31.317987, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宿迁", value: [118.296893, 33.95205, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "泰州", value: [119.919606, 32.476053, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "无锡", value: [120.305456, 31.570037, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "徐州", value: [117.188107, 34.271553, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "盐城", value: [120.148872, 33.379862, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "扬州", value: [119.427778, 32.408505, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "镇江", value: [119.455835, 32.204409, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "南昌", value: [115.893528, 28.689578, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "抚州", value: [116.360919, 27.954545, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "赣州", value: [114.935909, 25.845296, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "吉安", value: [114.992039, 27.113848, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "景德镇", value: [117.186523, 29.303563, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "九江", value: [115.999848, 29.71964, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "萍乡", value: [113.859917, 27.639544, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "上饶", value: [117.955464, 28.457623, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "新余", value: [114.947117, 27.822322, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宜春", value: [114.400039, 27.81113, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "鹰潭", value: [117.03545, 28.24131, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "长春", value: [125.313642, 43.898338, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "白城", value: [122.840777, 45.621086, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "白山", value: [126.435798, 41.945859, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "吉林市", value: [126.564544, 43.871988, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "辽源", value: [125.133686, 42.923303, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "四平", value: [124.391382, 43.175525, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "松原", value: [124.832995, 45.136049, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "通化", value: [125.94265, 41.736397, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "延边", value: [129.485902, 42.896414, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "沈阳", value: [123.432791, 41.808645, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "鞍山", value: [123.007763, 41.118744, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "本溪", value: [123.778062, 41.325838, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "朝阳", value: [120.446163, 41.571828, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "大连", value: [121.593478, 38.94871, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "丹东", value: [124.338543, 40.129023, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "抚顺", value: [123.92982, 41.877304, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "阜新", value: [121.660822, 42.01925, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "葫芦岛", value: [120.860758, 40.74303, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "锦州", value: [121.147749, 41.130879, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "辽阳", value: [123.172451, 41.273339, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "盘锦", value: [122.073228, 41.141248, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "铁岭", value: [123.85485, 42.299757, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "营口", value: [122.233391, 40.668651, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "呼和浩特", value: [111.660351, 40.828319, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "阿拉善盟", value: [105.695683, 38.843075, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "包头", value: [109.846239, 40.647119, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "巴彦淖尔", value: [107.423807, 40.76918, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "赤峰", value: [118.930761, 42.297112, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "鄂尔多斯", value: [109.993706, 39.81649, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "呼伦贝尔", value: [119.760822, 49.201636, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "通辽", value: [122.260363, 43.633756, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "乌海", value: [106.831999, 39.683177, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "乌兰察布", value: [113.112846, 41.022363, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "锡林郭勒盟", value: [116.02734, 43.939705, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "兴安盟", value: [122.048167, 46.083757, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "银川", value: [106.206479, 38.502621, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "固原", value: [106.285268, 36.021523, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "石嘴山", value: [106.379337, 39.020223, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "吴忠", value: [106.208254, 37.993561, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "中卫", value: [105.196754, 37.521124, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "西宁", value: [101.767921, 36.640739, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "果洛州", value: [100.223723, 34.480485, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "海东地区", value: [102.085207, 36.51761, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "海北州", value: [100.879802, 36.960654, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "海南州", value: [100.624066, 36.284364, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "海西州", value: [97.342625, 37.373799, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "黄南州", value: [102.0076, 35.522852, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "玉树州", value: [97.013316, 33.00624, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "济南", value: [117.024967, 36.682785, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "滨州", value: [117.968292, 37.405314, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "东营", value: [118.583926, 37.487121, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "德州", value: [116.328161, 37.460826, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "菏泽", value: [115.46336, 35.26244, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "济宁", value: [116.600798, 35.402122, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "莱芜", value: [117.684667, 36.233654, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "聊城", value: [115.986869, 36.455829, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "临沂", value: [118.340768, 35.072409, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "青岛", value: [120.384428, 36.105215, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "日照", value: [119.50718, 35.420225, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "泰安", value: [117.089415, 36.188078, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "威海", value: [122.093958, 37.528787, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "潍坊", value: [119.142634, 36.716115, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "烟台", value: [121.309555, 37.536562, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "枣庄", value: [117.279305, 34.807883, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "淄博", value: [118.059134, 36.804685, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "太原", value: [112.550864, 37.890277, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "长治", value: [113.120292, 36.201664, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "大同", value: [113.290509, 40.113744, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "晋城", value: [112.867333, 35.499834, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "晋中", value: [112.738514, 37.693362, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "临汾", value: [111.538788, 36.099745, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "吕梁", value: [111.143157, 37.527316, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "朔州", value: [112.479928, 39.337672, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "忻州", value: [112.727939, 38.461031, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "阳泉", value: [113.569238, 37.869529, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "运城", value: [111.006854, 35.038859, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "西安", value: [108.953098, 34.2778, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "安康", value: [109.038045, 32.70437, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宝鸡", value: [107.170645, 34.364081, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "汉中", value: [107.045478, 33.081569, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "商洛", value: [109.934208, 33.873907, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "铜川", value: [108.968067, 34.908368, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "渭南", value: [109.483933, 34.502358, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "咸阳", value: [108.707509, 34.345373, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "延安", value: [109.50051, 36.60332, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "榆林", value: [109.745926, 38.279439, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "成都", value: [104.067923, 30.679943, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "阿坝州", value: [102.228565, 31.905763, 15], itemStyle: { color: "#F58158" } },
|
||||
{ name: "巴中", value: [106.757916, 31.869189, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "达州", value: [107.494973, 31.214199, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "德阳", value: [104.402398, 31.13114, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "甘孜州", value: [101.969232, 30.055144, 15], itemStyle: { color: "#F58158" } },
|
||||
{ name: "广安", value: [106.63572, 30.463984, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "广元", value: [105.819687, 32.44104, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "乐山", value: [103.760824, 29.600958, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "凉山州", value: [102.259591, 27.892393, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "泸州", value: [105.44397, 28.89593, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "南充", value: [106.105554, 30.800965, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "眉山", value: [103.84143, 30.061115, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "绵阳", value: [104.705519, 31.504701, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "内江", value: [105.073056, 29.599462, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "攀枝花", value: [101.722423, 26.587571, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "遂宁", value: [105.564888, 30.557491, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "雅安", value: [103.009356, 29.999716, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宜宾", value: [104.633019, 28.769675, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "资阳", value: [104.63593, 30.132191, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "自贡", value: [104.776071, 29.359157, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "拉萨", value: [91.111891, 29.662557, 13], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "阿里地区", value: [81.107669, 30.404557, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "昌都地区", value: [97.185582, 31.140576, 15], itemStyle: { color: "#F58158" } },
|
||||
{ name: "林芝地区", value: [94.349985, 29.666941, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "那曲地区", value: [92.067018, 31.48068, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "日喀则地区", value: [88.891486, 29.269023, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "山南地区", value: [91.750644, 29.229027, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "乌鲁木齐", value: [87.564988, 43.84038, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "阿拉尔", value: [81.291737, 40.61568, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "阿克苏地区", value: [80.269846, 41.171731, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "阿勒泰地区", value: [88.137915, 47.839744, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "巴音郭楞", value: [86.121688, 41.771362, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "博尔塔拉州", value: [82.052436, 44.913651, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "昌吉州", value: [87.296038, 44.007058, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "哈密地区", value: [93.528355, 42.858596, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "和田地区", value: [79.930239, 37.116774, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "喀什地区", value: [75.992973, 39.470627, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "克拉玛依", value: [84.88118, 45.594331, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "克孜勒苏州", value: [76.137564, 39.750346, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "石河子", value: [86.041865, 44.308259, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "塔城地区", value: [82.974881, 46.758684, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "图木舒克", value: [79.198155, 39.889223, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "吐鲁番地区", value: [89.181595, 42.96047, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "五家渠", value: [87.565449, 44.368899, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "伊犁州", value: [81.297854, 43.922248, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "昆明", value: [102.714601, 25.049153, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "保山", value: [99.177996, 25.120489, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "楚雄州", value: [101.529382, 25.066356, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "大理州", value: [100.223675, 25.5969, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "德宏州", value: [98.589434, 24.44124, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "迪庆州", value: [99.713682, 27.831029, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "红河州", value: [103.384065, 23.367718, 11], itemStyle: { color: "#F58158" } },
|
||||
{ name: "丽江", value: [100.229628, 26.875351, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "临沧", value: [100.092613, 23.887806, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "怒江州", value: [98.859932, 25.860677, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "普洱", value: [100.980058, 22.788778, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "曲靖", value: [103.782539, 25.520758, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "昭通", value: [103.725021, 27.340633, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "文山", value: [104.089112, 23.401781, 14], itemStyle: { color: "#F58158" } },
|
||||
{ name: "西双版纳", value: [100.803038, 22.009433, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "玉溪", value: [102.545068, 24.370447, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "杭州", value: [120.219375, 30.259244, 12], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "湖州", value: [120.137243, 30.877925, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "嘉兴", value: [120.760428, 30.773992, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "金华", value: [119.652576, 29.102899, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "丽水", value: [119.929576, 28.4563, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "宁波", value: [121.579006, 29.885259, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "衢州", value: [118.875842, 28.95691, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "绍兴", value: [120.592467, 30.002365, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "台州", value: [121.440613, 28.668283, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "温州", value: [120.690635, 28.002838, 12], itemStyle: { color: "#F58158" } },
|
||||
{ name: "舟山", value: [122.169872, 30.03601, 13], itemStyle: { color: "#F58158" } },
|
||||
{ name: "香港", value: [114.186124, 22.293586, 11], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "澳门", value: [113.557519, 22.204118, 13], itemStyle: { color: "#58B3CC" } },
|
||||
{ name: "台湾", value: [120.961454, 23.80406, 8], itemStyle: { color: "#58B3CC" } },
|
||||
];
|
||||
|
||||
/**
|
||||
* 获取折线数据
|
||||
* @param length 折线数量
|
||||
* @returns 折线数据
|
||||
*/
|
||||
const getSeriesData = (length: number) => {
|
||||
const cityList = city.sort(() => Math.random() - 0.5);
|
||||
|
||||
const moveLines: MoveLine[] = [];
|
||||
|
||||
for (let i = 0; i <= length; i++) {
|
||||
const from = cityList[Math.floor(Math.random() * cityList.length)];
|
||||
const to = cityList[Math.floor(Math.random() * cityList.length)];
|
||||
|
||||
const [a1, b1] = from.value;
|
||||
const [a2, b2] = to.value;
|
||||
|
||||
moveLines.push({
|
||||
fromName: from.name,
|
||||
toName: to.name,
|
||||
coords: [
|
||||
[a1, b1],
|
||||
[a2, b2],
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// 通过数量计算出symbolSize的值
|
||||
city.forEach((item) => {
|
||||
item.symbolSize =
|
||||
moveLines.filter((line) => line.fromName === item.name || line.toName === item.name).length *
|
||||
2;
|
||||
});
|
||||
|
||||
return {
|
||||
cityData: city,
|
||||
moveLines,
|
||||
};
|
||||
};
|
||||
|
||||
export default getSeriesData;
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -124,16 +124,16 @@ defineOptions({
|
||||
import UserAPI from "@/api/system/user";
|
||||
import type { IObject, IOperateData, CrudModalInstance } from "@/components/Crud/types";
|
||||
import useCrudPage from "@/components/Crud/useCrudPage";
|
||||
import addModalConfig from "./config/add";
|
||||
import contentConfig from "./config/content";
|
||||
import editModalConfig from "./config/edit";
|
||||
import searchConfig from "./config/search";
|
||||
import { initOptions } from "./config/options";
|
||||
import addModalConfig from "./config/user/add";
|
||||
import contentConfig from "./config/user/content";
|
||||
import editModalConfig from "./config/user/edit";
|
||||
import searchConfig from "./config/user/search";
|
||||
import { initOptions } from "./config/user/options";
|
||||
|
||||
import addModalConfig2 from "./config2/add";
|
||||
import contentConfig2 from "./config2/content";
|
||||
import editModalConfig2 from "./config2/edit";
|
||||
import searchConfig2 from "./config2/search";
|
||||
import addModalConfig2 from "./config/mock/add";
|
||||
import contentConfig2 from "./config/mock/content";
|
||||
import editModalConfig2 from "./config/mock/edit";
|
||||
import searchConfig2 from "./config/mock/search";
|
||||
|
||||
const {
|
||||
searchRef,
|
||||
|
||||
Reference in new issue
Block a user