添加长春市地市下钻

This commit is contained in:
cwchen 2025-09-24 13:58:34 +08:00
parent 4b27073e72
commit 86d812292b
5 changed files with 31 additions and 16 deletions

View File

@ -265,12 +265,12 @@ body {
} }
#other-module { #other-module {
width: 15%; width: 21%;
height: 100%; height: 100%;
} }
#other-echarts { #other-echarts {
width: 83%; width: 78%;
height: 100%; height: 100%;
} }
@ -325,7 +325,7 @@ body {
.person-num-box p{ .person-num-box p{
width: 24%; width: 24%;
margin-right: 1%; margin-right: 1%;
font-size: 13px; font-size: 12px;
} }
#person-echarts, #person-echarts,
#team-echarts { #team-echarts {

View File

@ -86,7 +86,7 @@
style="display: none;"> style="display: none;">
</div> </div>
</div> </div>
<p id="province" data-placement="bottom-right">全省</p> <!-- <p id="province" data-placement="bottom-right">全省</p> -->
</div> </div>
<div id="week-echarts"> <div id="week-echarts">

View File

@ -6,6 +6,8 @@ let myChart6 = echarts.init(document.getElementById('weekPlan-echarts'));
/*人员情况 echarts*/ /*人员情况 echarts*/
function initEchartsOne(nameList, valueList) { function initEchartsOne(nameList, valueList) {
let fontSize = '16', fontFamily = 'Alibaba PuHuiTi R', fontColor = '#fff'; let fontSize = '16', fontFamily = 'Alibaba PuHuiTi R', fontColor = '#fff';
nameList = nameList.slice(-5);
valueList = valueList.slice(-5);
let option = { let option = {
backgroundColor: 'transparent', backgroundColor: 'transparent',
grid: { grid: {
@ -29,13 +31,16 @@ function initEchartsOne(nameList, valueList) {
}, },
xAxis: [{ xAxis: [{
type: 'category', type: 'category',
boundaryGap: 1, boundaryGap: 1,
axisLine: { axisLine: {
show: false show: false
}, },
axisLabel: { axisLabel: {
color: fontColor, color: fontColor,
fontFamily: fontFamily fontFamily: fontFamily,
interval: 0,
fontSize: 12,
}, },
splitLine: { splitLine: {
show: false show: false
@ -135,6 +140,8 @@ function initEchartsOne(nameList, valueList) {
/* 队伍情况 echarts */ /* 队伍情况 echarts */
function initEchartsTwo(nameList, valueList) { function initEchartsTwo(nameList, valueList) {
nameList = nameList.slice(-5);
valueList = valueList.slice(-5);
let fontSize = '16', fontFamily = 'Alibaba PuHuiTi R', fontColor = '#fff'; let fontSize = '16', fontFamily = 'Alibaba PuHuiTi R', fontColor = '#fff';
let option = { let option = {
backgroundColor: 'transparent', backgroundColor: 'transparent',
@ -260,6 +267,9 @@ function initEchartsTwo(nameList, valueList) {
/* 作业票趋势 echarts */ /* 作业票趋势 echarts */
function initEchartsThree(nameList, valueList, valueList2) { function initEchartsThree(nameList, valueList, valueList2) {
nameList = nameList.slice(-5);
valueList = valueList.slice(-5);
valueList2 = valueList2.slice(-5);
let fontSize = '16', fontFamily = 'Alibaba PuHuiTi R', fontColor = '#fff'; let fontSize = '16', fontFamily = 'Alibaba PuHuiTi R', fontColor = '#fff';
const backgroundColor = 'transparent'; const backgroundColor = 'transparent';
const color = ['#FF5D5D', '#32F474', '#FFE922', '#32F474', '#3DD1F9', '#FFAD05']; //2个以上的series就需要用到color数组 const color = ['#FF5D5D', '#32F474', '#FFE922', '#32F474', '#3DD1F9', '#FFAD05']; //2个以上的series就需要用到color数组
@ -409,6 +419,11 @@ function initEchartsThree(nameList, valueList, valueList2) {
/* 风险趋势 echarts */ /* 风险趋势 echarts */
function initEchartsFour(nameList, valueList, valueList2, valueList3, valueList4) { function initEchartsFour(nameList, valueList, valueList2, valueList3, valueList4) {
nameList = nameList.slice(-5);
valueList = valueList.slice(-5);
valueList2 = valueList2.slice(-5);
valueList3 = valueList3.slice(-5);
valueList4 = valueList4.slice(-5);
let fontSize = '16', fontFamily = 'Alibaba PuHuiTi R', fontColor = '#fff'; let fontSize = '16', fontFamily = 'Alibaba PuHuiTi R', fontColor = '#fff';
const backgroundColor = 'transparent'; const backgroundColor = 'transparent';
const color = ['#FF5D5D', '#F9770F', '#FFE922', '#32F474', '#3DD1F9', '#FFAD05']; //2个以上的series就需要用到color数组 const color = ['#FF5D5D', '#F9770F', '#FFE922', '#32F474', '#3DD1F9', '#FFAD05']; //2个以上的series就需要用到color数组

View File

@ -255,7 +255,7 @@ function initEchartsOne(listMap) {
/*周风险echarts*/ /*周风险echarts*/
function initEchartsTwo(nameList, twoRiskData, threeRiskData) { function initEchartsTwo(nameList, twoRiskData, threeRiskData) {
let fontSize = "14", let fontSize = "13",
fontFamily = "Alibaba PuHuiTi R", fontFamily = "Alibaba PuHuiTi R",
fontColor = "#fff"; fontColor = "#fff";
// 基于准备好的dom初始化echarts图表 // 基于准备好的dom初始化echarts图表
@ -291,7 +291,7 @@ function initEchartsTwo(nameList, twoRiskData, threeRiskData) {
moveOnMouseMove: true, moveOnMouseMove: true,
moveOnMouseWheel: true, moveOnMouseWheel: true,
startValue: 0, startValue: 0,
endValue: 5, endValue: 3,
}, },
], ],
legend: { legend: {
@ -488,7 +488,7 @@ function initEchartsFive(nameList, dataList) {
let data = []; let data = [];
xAxisList = nameList; xAxisList = nameList;
data = dataList; data = dataList;
let fontSize = "16"; let fontSize = "13";
let option = { let option = {
backgroundColor: "transparent", backgroundColor: "transparent",
tooltip: { tooltip: {
@ -532,7 +532,7 @@ function initEchartsFive(nameList, dataList) {
moveOnMouseMove: true, moveOnMouseMove: true,
moveOnMouseWheel: true, moveOnMouseWheel: true,
startValue: 0, startValue: 0,
endValue: 6, endValue: 3,
}, },
], ],
xAxis: [ xAxis: [
@ -542,7 +542,7 @@ function initEchartsFive(nameList, dataList) {
interval: 0, // 解决x轴名称过长问题 interval: 0, // 解决x轴名称过长问题
textStyle: { textStyle: {
color: "#fff", color: "#fff",
fontSize: 16, fontSize: 13,
fontFamily: "Alibaba PuHuiTi R", fontFamily: "Alibaba PuHuiTi R",
}, },
}, },
@ -648,7 +648,7 @@ function initEchartsFive(nameList, dataList) {
//自动滚动 //自动滚动
timeOut3 = setInterval(() => { timeOut3 = setInterval(() => {
if (option.dataZoom[0].endValue === xAxisList.length) { if (option.dataZoom[0].endValue === xAxisList.length) {
option.dataZoom[0].endValue = 6; option.dataZoom[0].endValue = 3;
option.dataZoom[0].startValue = 0; option.dataZoom[0].startValue = 0;
} else { } else {
option.dataZoom[0].endValue = option.dataZoom[0].endValue + 1; option.dataZoom[0].endValue = option.dataZoom[0].endValue + 1;

View File

@ -681,7 +681,7 @@ function initEchartsByUser(nameList, dataList) {
borderColor: "rgba(255,255,255, .5)", borderColor: "rgba(255,255,255, .5)",
}, },
grid: { grid: {
left: "2%", left: "1%",
right: "0%", right: "0%",
bottom: "3%", bottom: "3%",
top: "8%", top: "8%",
@ -700,7 +700,7 @@ function initEchartsByUser(nameList, dataList) {
color: "#fff", //字体颜色 color: "#fff", //字体颜色
fontFamily: "Alibaba PuHuiTi R", fontFamily: "Alibaba PuHuiTi R",
}, },
right: "3%", //距离右侧 // right: "3%", //距离右侧
}, },
dataZoom: [ dataZoom: [
{ {
@ -709,7 +709,7 @@ function initEchartsByUser(nameList, dataList) {
moveOnMouseMove: true, moveOnMouseMove: true,
moveOnMouseWheel: true, moveOnMouseWheel: true,
startValue: 0, startValue: 0,
endValue: 6, endValue: 3,
}, },
], ],
xAxis: [ xAxis: [
@ -719,7 +719,7 @@ function initEchartsByUser(nameList, dataList) {
interval: 0, // 解决x轴名称过长问题 interval: 0, // 解决x轴名称过长问题
textStyle: { textStyle: {
color: "#fff", color: "#fff",
fontSize: 16, fontSize: 13,
fontFamily: "Alibaba PuHuiTi R", fontFamily: "Alibaba PuHuiTi R",
}, },
}, },
@ -825,7 +825,7 @@ function initEchartsByUser(nameList, dataList) {
//自动滚动 //自动滚动
timeOut3 = setInterval(() => { timeOut3 = setInterval(() => {
if (option.dataZoom[0].endValue === xAxisList.length) { if (option.dataZoom[0].endValue === xAxisList.length) {
option.dataZoom[0].endValue = 6; option.dataZoom[0].endValue = 3;
option.dataZoom[0].startValue = 0; option.dataZoom[0].startValue = 0;
} else { } else {
option.dataZoom[0].endValue = option.dataZoom[0].endValue + 1; option.dataZoom[0].endValue = option.dataZoom[0].endValue + 1;