<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>变电站、线路设备分析和展示</title>
<!--easyui 框架引用-->
<link type="text/css" rel="stylesheet" href="/systemUI/system/vendor/easyui/themes/default/easyui.css">
<link rel="stylesheet" type="text/css" href="/systemUI/system/vendor/easyui/themes/icon.css"/>
<link rel="stylesheet" type="text/css" href="/systemUI/system/vendor/layui/css/layui.css"/>
<link type="text/css" rel="stylesheet" href="/systemUI/system/vendor/easyui/themes/default/demo.css">
<!--<link rel="stylesheet" href="//at.alicdn.com/t/font_607765_ny6pd0voz4lhaor.css">-->
<link rel="stylesheet" href="/systemUI/system/font_607765_iconfont/iconfont.css">
<!-- 公共样式 -->
<link type="text/css" rel="stylesheet" href="/systemUI/system/css/common.css">
<!-- 弹窗插件 -->
<link type="text/css" rel="stylesheet" href="/systemUI/system/vendor/easybootstrap/css/jquery.alertBox.css">
<!-- 自定样式 -->
<link type="text/css" rel="stylesheet" href="/systemUI/system/css/customEasyUi.css">
<!--demo样式-->
<link type="text/css" rel="stylesheet" href="/systemUI/system/css/controlDemo.css">
<!--菜单树引入 -->
<link type="text/css" rel="stylesheet" href="/systemUI/system/css/zTreeStyle/metro.css">
<link type="text/css" rel="stylesheet" href="/systemUI/system/vendor/easybootstrap/css/treeTable.css">
<!-- 自定样式 -->
<link type="text/css" rel="stylesheet" href="/systemUI/system/css/developPlatform-less/developPlatform.css">
<link type="text/css" rel="stylesheet" href="/systemUI/system/css/validate.css">
<link type="text/css" rel="stylesheet" href="/systemUI/system/css/grid.css">
<!-- <script src="js/require.js" defer async="true" ></script> -->
<!--<script src="/system/vendor/jquery/dist/jquery.min.js"></script>-->
<!--确定大中小屏-->
<script src="/systemUI/system/js/screenWidth.js"></script>
<script src="/systemUI/system/vendor/jquery/dist/jquery.min.js"></script>
<!--<script src="js/exJqueryHeader.js"></script>-->
<!--easyui 插件-->
<script src="/systemUI/system/vendor/easyui/jquery.easyui.min.js"></script>
<script src="/systemUI/system/vendor/easyui/locale/easyui-lang-zh_CN.js"></script>
<script src="/systemUI/system/vendor/easyui/plugins/jquery.form.js"></script>
<!-- 弹窗插件 -->
<script src="/systemUI/system/vendor/easybootstrap/js/jquery.alertBox.js"></script>
<!--<script src="/system/vendor/easybootstrap/js/jquery.treeTable.js"></script>-->
<!-- 初始化公共方法 -->
<script type="text/javascript" src="/systemUI/system/js/common.js"></script>
<script src="/systemUI/system/js/commonFn.js"></script>
<!-- 控件验证 -->
<script src="/systemUI/system/js/jquery.validate.min.js"></script>
<script src="/systemUI/system/js/additional-methods.js"></script>
<script src="/systemUI/system/js/messages_zh.js"></script>
<!--<script type="text/javascript" src="/system/js/publicollection-eui.js"></script>-->
<script src="/systemUI/system/js/commonCellTip.js"></script>
<script src="/systemUI/system/vendor/jquery/dist/echarts.min.js"></script>
<script src="/systemUI/system/vendor/layui/layui.js"></script>
<script src="/systemUI/system/module/zszc/zhzs/jsp/html/js/plugins/layer/layer.min.js"></script>
<script type="text/javascript" src="zhdc.js"></script>
<style type="text/css">
.w210>.layui-form-label {width: 70px;padding: 5px 2px 5px 2px;}
.w210>.layui-input-block {margin-left: 75px;}
.w210{width: 380px !important;height: 30px;}
.layui-select-title>.layui-input{ height: 30px !important;}
.layui-input-block>.layui-input{ height: 30px !important;}
.layui-form-select{height: 30px !important;width: 250px;}
.layui-table-cell {
height: auto !important;
line-height: 20px;
padding: 0 5px;
position: relative;
overflow: hidden;
text-overflow: ellipsis;
white-space: normal;
box-sizing: border-box;
}
.layui-label{width: 120px;margin-left: 10px;font-size: 16px;}
/*.l-btn{-webkit-border-radius:0px;background: white;border-width: 0px 0px 2px 0px;}*/
.l-btn:hover{color:black}
.s-Text{float: right;font-size: 14px;}
.laytable-cell-2-material_number>span{margin-left:-5px}
.laytable-cell-2-material_amount>span{margin-left:-5px}
.laytable-cell-2-percent_amount>span{margin-left:-5px}
.layui-form-select dl{top:30px}
.funBtnAggregate{
position: fixed;
right: 16px;
bottom: 20px;
width: 40px;
height: 40px;
border-right: 2px solid #39c5b3;
background: #c9f5ef;
background: -webkit-linear-gradient(left top, #f6f6f600 0, #4fe0ce 100%); /* Safari 5.1 - 6.0 */
background: -o-linear-gradient(bottom right, #f6f6f600 0, #4fe0ce 100%); /* Opera 11.1 - 12.0 */
background: -moz-linear-gradient(bottom right, #f6f6f600 0, #4fe0ce 100%); /* Firefox 3.6 - 15 */
background: linear-gradient(to bottom right, #f6f6f600 0, #4fe0ce 100%); /* 标准的语法 */
overflow: hidden;
}
.menuBtn{
display: block;
position: absolute;
right: 0;
bottom: 0;
width: 40px;
height: 40px;
line-height: 40px;
text-align: center;
background: #78e0d2;
}
.funBtnAggregate .iconfont{
font-size: 30px;
color: #fff;
}
.menuBtn .iconfont{
font-size: 40px;
color: #757572;
}
.btn-ul{
position: absolute;
bottom: 40px;
width: 100%;
height: auto;
}
.btn-ul li{
width: 100%;
height: 40px;
margin: 5px 0;
}
.btn-ul li a{
display: block;
width: 36px;
height: 36px;
line-height: 36px;
text-align: center;
border-radius: 7px;
border: 2px solid #fff;
}
.div-line{
float:left;
}
.div-pad{
padding:5px 5px 10px 5px;
margin:5px 5px 5px 5px;
background:#C6F5F1;
}
.div-pad2{
background:#FFFFFF;
}
.div-title{
font-size:16px;
font-weight:bold;
}
</style>
</head>
<body class="style2">
<div style="height: 100%; overflow: scroll;overflow-x: hidden;padding: 15px 15px 3px;box-sizing: border-box;background:#C6F5F1;">
<div class="layui-row " style="overflow: visible;background:#C6F5F1;" id="realResourcePanel" >
<!--查询及操作按钮-->
<div class="layui-card layui-card-body mb-20" style="overflow: visible;">
<form class="layui-row layui-col-space5 layui-form">
<div class="layui-col-sm2 w210">
<label class="layui-form-label">设备类型:</label>
<div class="layui-input-block" >
<!--<input type="text" class="input2" id="device_type" name="device_type" value="" style="width:120px"/>-->
<select id="device_type" name="device_type" class="textbox e_w200" style="display: block;margin-top:3px;">
<option value="">请选择</option>
<option value="输电设备">输电设备</option>
<option value="变压器类">变压器类</option>
<option value="开关类">开关类</option>
<option value="互感器类">互感器类</option>
<option value="避雷器">避雷器</option>
<option value="站用电系统">站用电系统</option>
<option value="二次系统">二次系统</option>
</select>
</div>
</div>
<div class="layui-col-sm2 w210" >
<label class="layui-form-label">设备区域:</label>
<div class="layui-input-block" >
<!--<input type="text" class="input2" id="device_area" name="device_area" value="" style="width:120px"/>-->
<select id="device_area" name="device_area" class="textbox e_w200" style="display: block;;margin-top:3px;">
<!--湖北、河南、湖南、江西-->
<option value="">请选择</option>
<option value="湖北">湖北</option>
<option value="河南">河南</option>
<option value="湖南">湖南</option>
<option value="江西">江西</option>
</select>
</div>
</div>
<div class="btn-box" style="float:left">
<button type="button" id ="userSearch" class="l-btn">查询</button>
<button type="button" id ="export" class="l-btn">导出报告</button>
</div>
</form>
</div>
<!-- 第一排 -->
<div class="layui-row layui-col-space20" style="padding-top:5px !important">
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">设备概况</span>
</div>
<table id="sbgkTable" class="e_panel-table" style="width: 100%;height:260px;"></table>
</div>
</div>
</div>
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">运行年限</span>
</div>
<div id="yxnxTable" class="e_panel-table" style="width: 100%;height:260px;"></div>
</div>
</div>
</div>
</div>
<!-- 第二排 -->
<div class="layui-row layui-col-space20" style="padding-top:5px !important">
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">按制造厂家统计</span>
</div>
<table id="zzcjTable" class="e_panel-table" style="width: 100%;height:260px;"></table>
</div>
</div>
</div>
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">高压套管制造厂家统计</span>
</div>
<div id="gyzzcjTable" class="e_panel-table" style="width: 100%;height:260px;"></div>
</div>
</div>
</div>
</div>
<!-- 第三排 -->
<div class="layui-row layui-col-space20" style="padding-top:5px !important">
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">设备运行情况分析</span>
</div>
<table id="sbyxqkTable" class="e_panel-table" style="width: 100%;height:260px;"></table>
</div>
</div>
</div>
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">按故障原因统计分析</span>
</div>
<div id="gzyytjTable" class="e_panel-table" style="width: 100%;height:260px;"></div>
</div>
</div>
</div>
</div>
<!-- 第四排-->
<div class="layui-row layui-col-space20" style="padding-top:5px !important">
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">按制造厂家分析</span>
</div>
<table id="zzcjtjTable" class="e_panel-table" style="width: 100%;height:260px;"></table>
</div>
</div>
</div>
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">按故障部件统计分析</span>
</div>
<div id="gzbjtjTable" class="e_panel-table" style="width: 100%;height:260px;"></div>
</div>
</div>
</div>
</div>
<!-- 第五排-->
<div class="layui-row layui-col-space20" style="padding-top:5px !important">
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">运行年限统计</span>
</div>
<table id="yxnxCharts" class="e_panel-table" style="width: 100%;height:260px;"></table>
</div>
</div>
</div>
<div class="layui-col-sm6 ">
<div class="" style="float:left;width:100%;">
<div class="layui-card">
<div class="layui-card-header">
<span class="div-title">各制造厂总量占比</span>
</div>
<div id="zzcjCharts" class="e_panel-table" style="width: 100%;height:260px;"></div>
</div>
</div>
</div>
</div>
</div>
</div>
<!--
<div class="pd-trl" id="userManagePanel" style="height:94%;overflow-y:hidden;height: 100%;box-sizing: border-box;padding: 15px 15px 3px;;background:#FFFFFF; color:#FFFFFF">
<div class="card" id="page4" style="height:88%;overflow-y:auto;">
<div class="card-body" style="background:#C6F5F1;">
<div style="width:100%;height:360px;" class="div-pad">
<div class="div-pad2" style="width: 30%;height:100%;">
<div id="zsxlbdsl1" class="div-line" style="width: 30%;height:340px"></div>
</div>
<div class="div-pad2" style="width: 60%;height:100%;">
<div id="dt1" class="div-line" style="width: 60%;height:340px;"></div>
</div>
</div>
<div style="width:100%;height:360px;" class="div-pad">
<div id="xlcd1" class="div-line" style="width: 32%;height:340px;"></div>
<div id="sbfynx1" class="div-line" style="width: 64%;height:340px;"></div>
</div>
<div style="width:100%;height:360px;" class="div-pad">
<div id="byqgkgekgsl1" class="div-line" style="width: 32%;height:340px;"></div>
<div id="dwyxsjfbqk1" class="div-line" style="width: 64%;height:340px;"></div>
</div>
<div style="width:100%;height:360px;" class="div-pad">
<div id="dwyxsjtj1" class="div-line" style="width: 32%;height:340px;"></div>
<div id="jxqk_11" class="div-line" style="width: 22%;height:340px;"></div>
<div id="jxqk_21" class="div-line" style="width: 22%;height:340px;"></div>
<div id="jxqk_31" class="div-line" style="width: 22%;height:340px;"></div>
</div>
</div>
</div>
</div>
-->
</body>
</html>
$(function(){
//var date = new Date();
//var time=formatterDate(date);
//$("#event_time").datebox("setValue",formatterDate(date));
//five(time);
parent.window.resizeTab();
showZSXLBDSL();//直属线路变电数量
showDWYXSJTJ();//电网运行事件统计
showXLCD();//线路长度
showDWYXSJFBQK();//电网运行事件分布情况
showBYQGKGLKGSL();//变压器,高抗,隔离开关数量
showSBFYNX();//设备服役年限
showSKYHJX();//三跨隐患检修
mapInit();//初始化地图
showDTTJ();//地图统计
});
var timer = null;
var i = 0;//窗口变化的次数
/*窗口自适应,关键代码*/
$(window).resize(function() {
clearTimeout(timer);//取消 setTimeout()
timer = setTimeout(function(){
//myChart.refresh();
myChart.resize();
},1000)
});
//直属线路变电数量
function showZSXLBDSL(){
ajaxPost(ServerURL + '/api/SubStation/getEchartsZSXLBDSLData', null, function (EchartsGroupData) {
var groupData = EchartsGroupData.data.data;
var xData = new Array;
var yHtslData = new Array;
var ySjjeData = new Array;
if(groupData != undefined && groupData != null){
$.each(groupData, function(index){
xData.push(groupData[index].XLNAME) ;
yHtslData.push({
x_str: groupData[index].BDZNAME,
value: groupData[index].XLCOUNT
});
ySjjeData.push({
x_str: groupData[index].BDZNAME,
value: groupData[index].BDZCOUNT
});
});
}
var myChart1 = echarts.init(document.getElementById('zsxlbdsl'));
var option = {
title : {
// text: '直属线路变电数量',
// x:'center'
// subtext: ''
},
tooltip : {
trigger: 'axis',
axisPointer: {
type: 'shadow'
},
formatter: function (params) {
return params[0].data.x_str + '<br/>' + params[0].marker + params[0].value + '<br/>' + params[1].marker + params[1].value;
}
},
grid: {
left: '5%',
right: '5%',
top:'20%',
bottom: '5%',
containLabel: true
},
legend: {
data:['线路条数','变电站数量'],
x:'right'
},
calculable : true,
xAxis : [
{
type : 'category',
data : xData,
axisLabel: {
//inside: true,
//rotate: 90,
fontSize: 14
}
}
],
yAxis : [
{
type : 'value',
//name: '线路条数',
nameGap: 20,
nameTextStyle: {
fontSize: 14
},
axisLabel: {
fontSize: 14
},
splitLine: {
show: false
}
}
],
// dataZoom: [
// {
// xAxisIndex: 0,
// type: 'slider',
// show: true,
// startValue: 1,
// endValue: 4,
// handleSize: 0,
// height: 10,
// top: '10%'
// }
// ],
series : [
{
name:'线路条数',
type:'bar',
barWidth:'20%',
batGap:'5%',
itemStyle: {
normal: {
color: '#00AAAA'
}
},
data:yHtslData
},
{
name:'变电站数量',
type:'bar',
barWidth:'20%',
batGap:'5%',
itemStyle: {
normal: {
color: '#FFAA33'
}
},
data:ySjjeData
}
]
};
myChart1.setOption(option);
});
}
//电网运行事件统计
function showDWYXSJTJ(){
ajaxPost(ServerURL + '/api/SubStation/getEchartsDWYXSJTJData', null, function (EchartsGroupData) {
var groupData = EchartsGroupData.data.data;
var xData = new Array;
var ySjjeData = new Array;
if(groupData != undefined && groupData != null){
$.each(groupData, function(index){
xData.push(groupData[index].SJCOUNT) ;
ySjjeData.push({
text: groupData[index].SJNAME,
max: 1000
});
});
}
var myChart1 = echarts.init(document.getElementById('dwyxsjtj'));
var option = {
title : {
// text: '电网运行事件统计',
// x:'center'
},
tooltip : {
trigger: 'axis',
axisPointer: {
type: 'shadow'
},
formatter: function (params) {
return params.data.value;
}
},
calculable : true,
polar : [
{
name: {
show: true,
textStyle:{
fontSize:16,
color:'#000'
}
},
/*indicator : [
{text : '解决问题', max : 100},
{text : '学习能力', max : 100},
{text : '综合', max : 100},
{text : '技术能力', max : 100},
{text : '业务能力', max : 100}
],*/
indicator : ySjjeData,
center : ['50%','50%'],
radius : 55 //半径,可放大放小雷达图
}
],
series : [
{
name:'',
type: 'radar',//图表类型 radar为雷达图
itemStyle: {
normal: {
lineStyle: {
color :"#66CDAA",
width : 2
},
areaStyle: {
color:"#66CDAA",
type: 'default'
}
}
},
symbolSize :6,
label: {
normal: {
show: true,
formatter:function(params) {
return params.value;
}
}
},
data : [{
//value:[100,80,80,80,80]
value:xData
}]
}
]
};
myChart1.setOption(option);
});
}
//线路长度
function showXLCD(){
ajaxPost(ServerURL + '/api/SubStation/getEchartsXLCDData', null, function (EchartsGroupData) {
var groupData = EchartsGroupData.data.data;
var xData = new Array;
var ySjjeData = new Array;
if(groupData != undefined && groupData != null){
$.each(groupData, function(index){
xData.push(groupData[index].XLNAME) ;
ySjjeData.push({
value: groupData[index].XLCD,
name: groupData[index].XLNAME
});
});
}
var myChart1 = echarts.init(document.getElementById('xlcd'));
var option = {
title : {
// text: '线路长度',
// x:'center'
},
tooltip: {
trigger: 'item',
formatter: "{a} <br/>{b}: {c} ({d}%)"
},
legend: {
orient: 'vertical',
x: 'right',
//data:['直接访问','邮件营销','联盟广告','视频广告','搜索引擎']
data:xData
},
series: [
{
name:'地区',
type:'pie',
radius: ['60%', '80%'],
avoidLabelOverlap: false,
color:['#00AAAA','#66CDAA','#FFAA33','#FA8072'],
label: {
normal: {
show: false,
position: 'center'
},
emphasis: {
show: true,
textStyle: {
fontSize: '30',
fontWeight: 'bold'
}
}
},
labelLine: {
normal: {
show: false
}
},
/*data:[
{value:335, name:'直接访问'},
{value:310, name:'邮件营销'},
{value:234, name:'联盟广告'},
{value:135, name:'视频广告'},
{value:1548, name:'搜索引擎'}
]*/
data:ySjjeData
}
]
};
myChart1.setOption(option);
});
}
//电网运行事件分布情况
function showDWYXSJFBQK(){
ajaxPost(ServerURL + '/api/SubStation/getEchartsDWYXSJFBQKData', null, function (EchartsGroupData) {
var groupData = EchartsGroupData.data.data;
var xData = new Array;
var HSData = new Array;
var LJData = new Array;
var FBData = new Array;
var WDData = new Array;
var YCData = new Array;
if(groupData != undefined && groupData != null){
$.each(groupData, function(index){
xData.push(groupData[index].SJMONTH) ;
HSData.push({
value: groupData[index].HSCOUNT,
name: groupData[index].SJMONTH
});
LJData.push({
value: groupData[index].LJCOUNT,
name: groupData[index].SJMONTH
});
FBData.push({
value: groupData[index].FBCOUNT,
name: groupData[index].SJMONTH
});
WDData.push({
value: groupData[index].WDCOUNT,
name: groupData[index].SJMONTH
});
YCData.push({
value: groupData[index].YCCOUNT,
name: groupData[index].SJMONTH
});
});
}
var myChart1 = echarts.init(document.getElementById('dwyxsjfbqk'));
var option = {
tooltip: {
trigger: 'axis'
},
grid: {
top:'15%',
bottom: '5%',
left:'2%',
right:'5%',
containLabel: true
},
legend: {
data:['山火事件', '雷击事件', '覆冰事件', '舞动事件', '异常事件']
},
xAxis: {
type: 'category',
boundaryGap: true,
axisLabel: {
interval:0,
rotate:0 ,//设置字体倾斜30
textStyle: {
fontSize: 12,
color: '#111',
},
},
data: xData
},
yAxis: {
type: 'value'
},
series: [{
data: HSData,
smooth: true,
scale: true,
name: '山火事件',
itemStyle : {
normal : {
color:'#00AAAA', // 设置最高气温线的颜色
}
},
type: 'line'
}
,{
data: LJData,
smooth: true,
scale: true,
name: '雷击事件',
itemStyle : {
normal : {
color:'#66CDAA', // 设置最高气温线的颜色
}
},
type: 'line'
}
,{
data: FBData,
smooth: true,
scale: true,
name: '覆冰事件',
itemStyle : {
normal : {
color:'#FFAA33', // 设置最高气温线的颜色
}
},
type: 'line'
}
,{
data: WDData,
smooth: true,
scale: true,
name: '舞动事件',
itemStyle : {
normal : {
color:'#FA8072', // 设置最高气温线的颜色
}
},
type: 'line'
}
,{
data: YCData,
smooth: true,
scale: true,
name: '异常事件',
type: 'line'
}
]
};
myChart1.setOption(option);
});
}
//变压器,高抗,隔离开关数量
function showBYQGKGLKGSL(){
ajaxPost(ServerURL + '/api/SubStation/getEchartsBYQGKGLKGSLData', null, function (EchartsGroupData) {
var groupData = EchartsGroupData.data.data;
var xData = new Array;
var byqData = new Array;
var gkData = new Array;
var glkgData = new Array;
if(groupData != undefined && groupData != null){
$.each(groupData, function(index){
xData.push(groupData[index].XLNAME);
byqData.push({
x_str: groupData[index].XLNAME,
value: groupData[index].BYQCOUNT
});
gkData.push({
x_str: groupData[index].XLNAME,
value: groupData[index].GKCOUNT
});
glkgData.push({
x_str: groupData[index].XLNAME,
value: groupData[index].GLKGCOUNT
});
});
}
var myChart1 = echarts.init(document.getElementById('byqgkgekgsl'));
var option = {
tooltip : {
trigger: 'axis',
axisPointer: {
type: 'shadow'
},
formatter: function (params) {
return params[0].data.x_str + '<br/>' + params[0].marker + params[0].value + '<br/>' + params[1].marker + params[1].value+ '<br/>' + params[2].marker + params[2].value;
}
},
grid: {
left: '5%',
right: '5%',
top:'20%',
bottom: '5%',
containLabel: true
},
legend: {
data:['变压器','高抗','隔离开关'],
x:'right'
},
calculable: true,
xAxis: [
{
type : 'category',
data : xData,
axisLabel: {
//inside: true,
//rotate: 90,
fontSize: 14
}
}
],
yAxis: [
{
type: 'value',
nameGap: 20,
nameTextStyle: {
fontSize: 14
},
axisLabel: {
fontSize: 14
},
splitLine: {
show: false
}
}
],
series: [
{
name:'变压器',
type: 'bar',
barWidth:'20%',
itemStyle: {
normal: {
color: '#00AAAA'
}
},
data: byqData
},
{
name:'高抗',
type: 'bar',
barWidth:'20%',
itemStyle: {
normal: {
color: '#FFAA33'
}
},
data: gkData
},
{
name:'隔离开关',
type: 'bar',
barWidth:'20%',
itemStyle: {
normal: {
color: '#66CDAA'
}
},
data: glkgData
},
]
};
myChart1.setOption(option);
});
}
//设备服役年限
function showSBFYNX(){
ajaxPost(ServerURL + '/api/SubStation/getEchartsSBFYNXData', null, function (EchartsGroupData) {
var newName=new Array();
var lenName = new Array();
var year1=new Array();
var year2=new Array();
var year3=new Array();
var year4=new Array();
var year5=new Array();
var year6=new Array();
var year7=new Array();
var year8=new Array();
var nowYear = EchartsGroupData.data.data;
for (var i = 0; i < nowYear.length; i++) {
newName.push(nowYear[i].STATIONTYPE);
year1.push({
name: nowYear[i].STATIONTYPE,
value: (nowYear[i].YEAR1==null)?0:nowYear[i].YEAR1
});
year2.push({
name: nowYear[i].STATIONTYPE,
value: (nowYear[i].YEAR2==null)?0:nowYear[i].YEAR2
});
year3.push({
name: nowYear[i].STATIONTYPE,
value: (nowYear[i].YEAR3==null)?0:nowYear[i].YEAR3
});
year4.push({
name: nowYear[i].STATIONTYPE,
value: (nowYear[i].YEAR4==null)?0:nowYear[i].YEAR4
});
year5.push({
name: nowYear[i].STATIONTYPE,
value: (nowYear[i].YEAR4==null)?0:nowYear[i].YEAR5
});
year6.push({
name: nowYear[i].STATIONTYPE,
value: (nowYear[i].YEAR4==null)?0:nowYear[i].YEAR6
});
year7.push({
name: nowYear[i].STATIONTYPE,
value: (nowYear[i].YEAR4==null)?0:nowYear[i].YEAR7
});
year8.push({
name: nowYear[i].STATIONTYPE,
value: (nowYear[i].YEAR4==null)?0:nowYear[i].YEAR8
});
}
var year = new Date().getFullYear();
lenName.push('1年以内');
lenName.push('1-5年');
lenName.push('5-10年');
lenName.push('10-15年');
lenName.push('15-20年');
lenName.push('20-25年');
lenName.push('25-30年');
lenName.push('30年以上');
//window.clearInterval(time1);
var myChart1 = echarts.init(document.getElementById('sbfynx'));
var option = {
title : { // 标题
top : '0%',
text : '',
x : '2%',
textStyle : {
fontSize: 14,
color : '#333'
}
},
tooltip : {
trigger: 'axis',
axisPointer: {
type: 'shadow'
},
formatter: function (params) {
return params[0].data.name + '<br/>' + params[0].marker + '1年以内:'+params[0].value + '<br/>' + params[1].marker + '1-5年:'+ params[1].value+ '<br/>' + params[2].marker + '5-10年:'+ params[2].value+ '<br/>' + params[3].marker + '10-15年:'+ params[3].value + '<br/>' + params[4].marker + '15-20年:'+ params[4].value + '<br/>' + params[5].marker + '20-25年:'+ params[5].value + '<br/>' + params[6].marker + '25-30年:'+ params[6].value +'<br/>' + params[7].marker + '30年以上:'+ params[7].value;
}
},
grid:{
left: '7%',
bottom: '20%',
height:'70%',
width:'75%'
},
legend: {
data: lenName,
textStyle:{ //图例文字的样式
fontSize:14,
color:'#111'
},
//x:'right',
//y:'bottom'
orient: 'vertical', //垂直显示
type:'scroll',
y: 'center', //延Y轴居中
x: 'right' //居右显示
},
xAxis : {
type : 'category',
axisLabel: {
interval : 0,
alignWithLabel:true,
textStyle: {
fontSize: 14,
color: '#111',
}
},
axisLine: {
show: true
},
splitLine: {
show: false
},
axisTick: {
show: true
},
boundaryGap: true,
//data : ['武汉','荆州','鄂州','黄石','宜昌','孝感']
data:newName
},
dataZoom: [
{
xAxisIndex: 0,
type: 'slider',
show: true,
startValue: 0,
endValue: 3,
handleSize: 0,
height: 10,
top: '5%'
}
],
yAxis : {
type : 'value',
axisLabel: {
textStyle: {
fontSize: 14,
color: '#111',
},
},
axisLine: {
show: true
},
splitLine: {
show: false
},
axisTick: {
show: false
}
},
series : [
{
name : lenName[0],
type : 'bar',
stack:'数量',
barGap : '-100%',
barWidth:20,
smooth:true,
itemStyle: {
normal: {
color: '#FA8072'
}
},
label : {
normal : {
show : false,
color:'#111',
position : 'top'
}
},
data : year1
},{
name : lenName[1],
type : 'bar',
stack:'数量',
barGap : '-100%',
barWidth:20,
smooth:true,
itemStyle: {
normal: {
color: '#f8cbad'
}
},
label : {
normal : {
show : false,
color:'#111',
position : 'top'
}
},
data : year2
},
{
name : lenName[2],
type : 'bar',
stack:'数量',
barGap : '-100%',
barWidth:20,
smooth:true,
itemStyle: {
normal: {
color: '#ffc000'
}
},
label : {
normal : {
show : false,
color:'#111',
position : 'top'
}
},
data : year3
},{
name : lenName[3],
type : 'bar',
stack:'数量',
barGap : '-100%',
barWidth:20,
smooth:true,
itemStyle: {
normal: {
color: '#9932CC'
}
},
label : {
normal : {
show : false,
color:'#111',
position : 'top'
}
},
data : year4
},{
name : lenName[4],
type : 'bar',
stack:'数量',
barGap : '-100%',
barWidth:20,
smooth:true,
itemStyle: {
normal: {
color: '#FF8C00'
}
},
label : {
normal : {
show : false,
color:'#111',
position : 'top'
}
},
data : year5
},{
name : lenName[5],
type : 'bar',
stack:'数量',
barGap : '-100%',
barWidth:20,
smooth:true,
itemStyle: {
normal: {
color: '#EEEE00'
}
},
label : {
normal : {
show : false,
color:'#111',
position : 'top'
}
},
data : year6
},{
name : lenName[6],
type : 'bar',
stack:'数量',
barGap : '-100%',
barWidth:20,
smooth:true,
itemStyle: {
normal: {
color: '#66FF66'
}
},
label : {
normal : {
show : false,
color:'#111',
position : 'top'
}
},
data : year7
},{
name : lenName[7],
type : 'bar',
stack:'数量',
barGap : '-100%',
barWidth:20,
smooth:true,
itemStyle: {
normal: {
color: '#33CCFF'
}
},
label : {
normal : {
show : false,
color:'#111',
position : 'top'
}
},
data : year8
}
]
};
myChart1.setOption(option);
});
}
//三跨隐患检修
function showSKYHJX(){
ajaxPost(ServerURL + '/api/SubStation/getEchartsSKYHJXData', null, function (EchartsGroupData) {
var groupData = EchartsGroupData.data.data;
var xData1 = new Array;
var ySKData = new Array;
var xData2 = new Array;
var yQXData = new Array;
var xData3 = new Array;
var yJXData = new Array;
if(groupData != undefined && groupData != null){
$.each(groupData, function(index){
if(groupData[index].XH=='1'){
xData1.push('已完成') ;
ySKData.push({
value: groupData[index].YWCCOUNT,
name: '已完成'
});
xData1.push('未完成') ;
ySKData.push({
value: groupData[index].WWCCOUNT,
name: '未完成'
});
}
if(groupData[index].XH=='2'){
xData2.push('已完成') ;
yQXData.push({
value: groupData[index].YWCCOUNT,
name: '已完成'
});
xData2.push('未完成') ;
yQXData.push({
value: groupData[index].WWCCOUNT,
name: '未完成'
});
}
if(groupData[index].XH=='3'){
xData3.push('已完成') ;
yJXData.push({
value: groupData[index].YWCCOUNT,
name: '已完成'
});
xData3.push('未完成') ;
yJXData.push({
value: groupData[index].WWCCOUNT,
name: '未完成'
});
}
});
}
//三跨
var myChart1 = echarts.init(document.getElementById('jxqk_1'));
var option = {
title : {
text: '三跨改造',
x:'center'
},
tooltip: {
trigger: 'item',
formatter: "{a} <br/>{b}: {c} ({d}%)"
},
legend: {
orient: 'vertical',
x: 'center',
y:'bottom',
//data:['直接访问','邮件营销','联盟广告','视频广告','搜索引擎']
data:xData1
},
series: [
{
name:'数量',
type:'pie',
radius: ['35%', '55%'],//饼图的半径,第一个为内半径,第二个为外半径
avoidLabelOverlap: false,
color:['#00AAAA','#DDDDDD'],
label: {
normal: {
show: false,
position: 'center'
},
emphasis: {
show: true,
textStyle: {
fontSize: '30',
fontWeight: 'bold'
}
}
},
labelLine: {
normal: {
show: false
}
},
/*data:[
{value:335, name:'直接访问'},
{value:310, name:'邮件营销'},
{value:234, name:'联盟广告'},
{value:135, name:'视频广告'},
{value:1548, name:'搜索引擎'}
]*/
data:ySKData
}
]
};
myChart1.setOption(option);
//缺陷治理
var myChart2 = echarts.init(document.getElementById('jxqk_2'));
var option2 = {
title : {
text: '缺陷治理',
x:'center'
},
tooltip: {
trigger: 'item',
formatter: "{a} <br/>{b}: {c} ({d}%)"
},
legend: {
orient: 'vertical',
x: 'center',
y:'bottom',
//data:['直接访问','邮件营销','联盟广告','视频广告','搜索引擎']
data:xData2
},
series: [
{
name:'数量',
type:'pie',
radius: ['35%', '55%'],
avoidLabelOverlap: false,
color:['#FFAA33','#DDDDDD'],
label: {
normal: {
show: false,
position: 'center'
},
emphasis: {
show: true,
textStyle: {
fontSize: '30',
fontWeight: 'bold'
}
}
},
labelLine: {
normal: {
show: false
}
},
/*data:[
{value:335, name:'直接访问'},
{value:310, name:'邮件营销'},
{value:234, name:'联盟广告'},
{value:135, name:'视频广告'},
{value:1548, name:'搜索引擎'}
]*/
data:yQXData
}
]
};
myChart2.setOption(option2);
//检修工作
var myChart3 = echarts.init(document.getElementById('jxqk_3'));
var option3 = {
title : {
text: '检修工作',
x:'center'
},
tooltip: {
trigger: 'item',
formatter: "{a} <br/>{b}: {c} ({d}%)"
},
legend: {
orient: 'vertical',
x: 'center',
y:'bottom',
//data:['直接访问','邮件营销','联盟广告','视频广告','搜索引擎']
data:xData3
},
series: [
{
name:'数量',
type:'pie',
radius: ['35%', '55%'],
avoidLabelOverlap: false,
color:['#FA8072','#DDDDDD'],
label: {
normal: {
show: false,
position: 'center'
},
emphasis: {
show: true,
textStyle: {
fontSize: '30',
fontWeight: 'bold'
}
}
},
labelLine: {
normal: {
show: false
}
},
/*data:[
{value:335, name:'直接访问'},
{value:310, name:'邮件营销'},
{value:234, name:'联盟广告'},
{value:135, name:'视频广告'},
{value:1548, name:'搜索引擎'}
]*/
data:yJXData
}
]
};
myChart3.setOption(option3);
});
}
//路径配置
var myChart;
var option;
//1000KV变电站
var subArr1=new Array();
//500kv变电站
var subArr2=new Array();
//500kv开关站
var subArr3=new Array();
//换流站
var subArr4=new Array();
//串补站
var subArr5=new Array();
//水电站
var subArr6=new Array();
//火电站
var subArr7=new Array();
//抽水蓄能电站
var subArr8=new Array();
//变电站直属资产
var subArr9=new Array();
//1000kv线路
var lineArr1=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ], [ ] ]
}
];
//500kv线路
var lineArr2=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ], [ ] ]
}
];
//+800kv直流线
var lineArr3=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ], [ ] ]
}
];
//+500kv直流线
var lineArr4=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ], [ ] ]
}
];
//华中直属资产
var lineArr5=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ], [ ] ]
}
];
//高亮
var lineArr6=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ], [ ] ]
}
];
//高亮
var subArr10=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ]]
}
];
//初始化地图
function mapInit(){
var Params = {
area : "",
}
var subJson = ajaxPost(ServerURL+'/api/SvgMap/getSub',Params, function () {});
var subStation=subJson.data;
for(i=0;i<subStation.length;i++){
subStation[i].substationName = subStation[i].substationName.replace("500","");
subStation[i].substationName = subStation[i].substationName.replace("1000","");
subStation[i].substationName = subStation[i].substationName.replace("kV","");
subStation[i].substationName = subStation[i].substationName.replace("kv","");
subStation[i].substationName = subStation[i].substationName.replace("KV","");
subStation[i].substationName = subStation[i].substationName.replace("变电站","");
subStation[i].substationName = subStation[i].substationName.replace("换流站","");
subStation[i].substationName = subStation[i].substationName.replace("水电站","");
subStation[i].substationName = subStation[i].substationName.replace("火电站","");
subStation[i].substationName = subStation[i].substationName.replace("串补站","");
subStation[i].substationName = subStation[i].substationName.replace("开关站","");
subStation[i].substationName = subStation[i].substationName.replace("抽水蓄能电站","");
if(subStation[i].substationType=='1'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr1.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId,
});
}else if(subStation[i].substationType=='2' && subStation[i].nationalassets == '02'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr2.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId
});
}else if(subStation[i].substationType=='3'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr3.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId
});
}else if(subStation[i].substationType=='4'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr4.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId
});
}else if(subStation[i].substationType=='5'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr5.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId
});
}else if(subStation[i].substationType=='6'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr6.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId
});
}else if(subStation[i].substationType=='7'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr7.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId
});
}else if(subStation[i].substationType=='8'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr8.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId
});
}else if(subStation[i].substationType=='2' && subStation[i].nationalassets == '01'){
var value=[];
value[0]=subStation[i].coordinatex;
value[1]=subStation[i].coordinatey;
subArr9.push({
name : subStation[i].substationName,
value : value,
id: subStation[i].substationId
});
}
}
var lineJson=ajaxPost(ServerURL+'/api/SvgMap/getLine',Params, function () {});
var lineInfo=lineJson.data;
for(i=0;i<lineInfo.length;i++){
lineInfo[i].lineName = lineInfo[i].lineName.replace("500","");
lineInfo[i].lineName = lineInfo[i].lineName.replace("1000","");
lineInfo[i].lineName = lineInfo[i].lineName.replace("kV","");
lineInfo[i].lineName = lineInfo[i].lineName.replace("kv","");
lineInfo[i].lineName = lineInfo[i].lineName.replace("KV","");
//if(lineInfo[i].lineType=='1'){
if(lineInfo[i].voltageLevel=='03' && lineInfo[i].nationalassets=='02'){
var sValue=[];
sValue[0]=lineInfo[i].ssx;
sValue[1]=lineInfo[i].ssy;
var eValue2=[];
eValue2[0]=lineInfo[i].esx;
eValue2[1]=lineInfo[i].esy;
lineArr1.push({
"name" : lineInfo[i].lineName,
'coords':[sValue,eValue2],
'id': lineInfo[i].lineId
});
//}else if(lineInfo[i].lineType=='2'){
}else if(lineInfo[i].voltageLevel=='08' && lineInfo[i].nationalassets=='02'){
var sValue=[];
sValue[0]=lineInfo[i].ssx;
sValue[1]=lineInfo[i].ssy;
var eValue2=[];
eValue2[0]=lineInfo[i].esx;
eValue2[1]=lineInfo[i].esy;
lineArr2.push({
"name" : lineInfo[i].lineName,
'coords':[sValue,eValue2],
'id': lineInfo[i].lineId
});
}else if(lineInfo[i].nationalassets=='01'){
var sValue=[];
sValue[0]=lineInfo[i].ssx;
sValue[1]=lineInfo[i].ssy;
var eValue2=[];
eValue2[0]=lineInfo[i].esx;
eValue2[1]=lineInfo[i].esy;
lineArr5.push({
"name" : lineInfo[i].lineName,
'coords':[sValue,eValue2],
'id': lineInfo[i].lineId
});
}
/*else if(lineInfo[i].lineType=='3'){
var sValue=[];
sValue[0]=lineInfo[i].ssx;
sValue[1]=lineInfo[i].ssy;
var eValue2=[];
eValue2[0]=lineInfo[i].esx;
eValue2[1]=lineInfo[i].esy;
lineArr3.push({
"name" : lineInfo[i].lineName,
'coords':[sValue,eValue2],
'id': lineInfo[i].lineId
});
}else if(lineInfo[i].lineType=='4'){
var sValue=[];
sValue[0]=lineInfo[i].ssx;
sValue[1]=lineInfo[i].ssy;
var eValue2=[];
eValue2[0]=lineInfo[i].esx;
eValue2[1]=lineInfo[i].esy;
lineArr4.push({
"name" : lineInfo[i].lineName,
'coords':[sValue,eValue2],
'id': lineInfo[i].lineId
});
}else if(lineInfo[i].lineType=='5'){
var sValue=[];
sValue[0]=lineInfo[i].ssx;
sValue[1]=lineInfo[i].ssy;
var eValue2=[];
eValue2[0]=lineInfo[i].esx;
eValue2[1]=lineInfo[i].esy;
lineArr5.push({
"name" : lineInfo[i].lineName,
'coords':[sValue,eValue2],
'id': lineInfo[i].lineId
});
}*/
}
ditus();
$("#eachLine").click(function(){
//清空之前的高亮
var lineArr6=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ], [ ] ]
}
];
var subArr10=[
{
"name" : "",
"fromName" : "",
"toName" : "",
'coords' : [ [ ], [ ] ]
}
];
var option1=myChart.getOption();
option1.series[17].data=lineArr6;
option1.series[18].data=subArr10;
myChart.setOption(option1,true);
//执行查询
var lineName=$("#lineName").val();
var area=$("#area").val();
var year=$("#year").val();
var Params={
"lineName" :lineName,
"area" : area,
"year" : year
}
if(lineName==""&&area==""&&year==""){
window.location.reload();
}else{
var line = ajaxPost(ServerURL+'/api/SvgMap/getLineDataBySearch',Params, function () {});
var lineInfo=line.data.line;
var subInfo=line.data.sub;
if(lineInfo != null && lineInfo != ""){
for(i=0;i<lineInfo.length;i++){
var sValue=[];
sValue[0]=lineInfo[i].ssx;
sValue[1]=lineInfo[i].ssy;
var eValue2=[];
eValue2[0]=lineInfo[i].esx;
eValue2[1]=lineInfo[i].esy;
lineArr6.push({
"name" : lineInfo[i].lineName,
'coords':[sValue,eValue2],
'id': lineInfo[i].lineId
});
}
}
if(subInfo != null && subInfo != ""){
for(i=0;i<subInfo.length;i++){
var value=[];
value[0]=subInfo[i].coordinatex;
value[1]=subInfo[i].coordinatey;
subArr10.push({
name : subInfo[i].substationName,
value:value,
id: subInfo[i].substationId/*,
symbolSize:'20',
itemStyle:{
normal : {
color : 'yellow'
}
}*/
});
}
}
}
var option1=myChart.getOption();
option1.series[17].data=lineArr6;
option1.series[18].data=subArr10;
myChart.setOption(option1,true);
})
}
var myChart;
function ditus() { //去年供电量与售电量的对比
myChart = echarts.init(document.getElementById('ditu'));
var uploadedDataURL = "../zszc/zhzs/jsp/html/geoJson/hz.geo.json";
var station = "image/00.png";
var line = "image/00.png";
//var station1000b="icon/1000kvbian.png";
var station1000b="../zszc/zhzs/jsp/html/icon/1000kVbdz.png";
//var station500b="icon/500kvbian.png";
var station500b="../zszc/zhzs/jsp/html/icon/500kVbdz.png";
//var station500k="icon/500kvkai.png";
var station500k="../zszc/zhzs/jsp/html/icon/500kVkgz.png";
//var stationhlz="icon/huanliu.png";
var stationhlz="../zszc/zhzs/jsp/html/icon/hlz.png";
//var stationcbz="icon/chuanbu.png";
var stationcbz="../zszc/zhzs/jsp/html/icon/cbz.png";
//var stationsdz="icon/shuidian.png";
var stationsdz="../zszc/zhzs/jsp/html/icon/sdz.png";
//var stationhdz="icon/huodian.png";
var stationhdz="../zszc/zhzs/jsp/html/icon/hdz.png";
//var stationcsxndz="icon/chushui.png";
var stationcsxndz="../zszc/zhzs/jsp/html/icon/csxndz.png";
var stationhuazhong = "../zszc/zhzs/jsp/html/icon/zszcbdz.png";
//var line1000 = "icon/1000.png";
var line1000 = "../zszc/zhzs/jsp/html/icon/1000kVxl.png";
//var line500 = "icon/500.png";
var line500 = "../zszc/zhzs/jsp/html/icon/500kVxl.png";
//var line800 = "icon/+800.png";
var line800 = "../zszc/zhzs/jsp/html/icon/800kVzlx.png";
//var line500zlx = "icon/+500.png";
var line500zlx = "../zszc/zhzs/jsp/html/icon/500kVzlx.png";
//var linehuazhong = "icon/huazhong.png";
var linehuazhong = "../zszc/zhzs/jsp/html/icon/hzzszc.png";
var bdzgl = "../zszc/zhzs/jsp/html/icon/bdzgl.png";
var max = 480,
min = 9; // todo
var maxSize4Pin = 100,
minSize4Pin = 20;
myChart.showLoading();
$.get(uploadedDataURL, function(geoJson) {
echarts.registerMap('华中', geoJson);
myChart.hideLoading();
myChart.on('click', function(params) {
//搜索参数
var area=$("#area").val();
var lineName=$("#lineName").val();
var year=$("#year").val();
// 控制台打印数据的名称
if (params.componentType == 'series' && params.componentSubType == 'scatter') {
var subId=params.data.id;
var subName=params.data.name;
layer.open({
title : '站点信息',
type : 2,
skin : 'layui-layer-molv', //样式类名
shade : [ 0.1, '#fff' ],
// closeBtn : false, //不显示关闭按钮
shift : 2,
area : [ '420px', '500px' ], //宽高
shadeClose : true, //开启遮罩关闭
content:"/systemUI/system/module/zszc/zhzs/jsp/html/station.html?subId="+subId+"&subName="+subName
});
} else if (params.componentType == 'series' && params.componentSubType == 'lines') {
var lineId=params.data.id;
var lineName=params.data.name;
layer.open({
title : '线路信息',
type : 2,
skin : 'layui-layer-molv', //样式类名
shade : [ 0.1, '#fff' ],
// closeBtn : false, //不显示关闭按钮
shift : 2,
area : [ '420px', '500px' ], //宽高
shadeClose : true, //开启遮罩关闭
content:"/systemUI/system/module/zszc/zhzs/jsp/html/line.html?lineId="+lineId+"&lineName="+lineName
});
} else if (params.componentSubType == 'map') {
if(params.name=='湖北'){
window.location.href="../zszc/zhzs/jsp/html/hubei.html?lineName="+ lineName +"&year="+year+"&areas="+area;
}else if(params.name=='湖南'){
window.location.href="../zszc/zhzs/jsp/html/hunan.html?lineName="+ lineName +"&year="+year+"&areas="+area;
}else if(params.name=='四川'){
window.location.href="../zszc/zhzs/jsp/html/sichuan.html?lineName="+ lineName +"&year="+year+"&areas="+area;
}else if(params.name=='河南'){
window.location.href="../zszc/zhzs/jsp/html/henan.html?lineName="+ lineName +"&year="+year+"&areas="+area;
}else if(params.name=='江西'){
window.location.href="../zszc/zhzs/jsp/html/jiangxi.html?lineName="+ lineName +"&year="+year+"&areas="+area;
}else if(params.name=='重庆'){
window.location.href="../zszc/zhzs/jsp/html/chongqin.html?lineName="+ lineName +"&year="+year+"&areas="+area;
}
}
});
var myZoom = 1.1;
var big = 0;
var small = 0;
myChart.on('georoam', function(params) {//地图缩放事件
//console.log(params);
if(params.dy || params.dx){//拖拽事件不操作,return
return;
}
var _option = myChart.getOption();
var _zoom = _option.series[0].zoom;
myZoom = params.zoom;
if(myZoom == _zoom){//大小未改变
return;
}
//myZoom = _zoom;
if(myZoom > _zoom){
big += 1;
/*if(small > 0){
small -= 1;
}*/
console.log("变大第"+big+"次");
}
if(myZoom < _zoom){
small += 1;
/*if(small > 0){
big -= 1;
}*/
console.log("变小第"+small+"次");
}
if(big - small >= 0 && big - small < 3){
_option.tooltip[0].textStyle.fontSize = 15;
_option.series[1].symbolSize = 15;
_option.series[2].symbolSize = 15;
_option.series[3].symbolSize = 15;
_option.series[4].symbolSize = 15;
_option.series[5].symbolSize = 15;
_option.series[6].symbolSize = 15;
_option.series[7].symbolSize = 15;
_option.series[8].symbolSize = 15;
_option.series[9].symbolSize = 15;
_option.series[10].symbolSize = 15;
_option.series[11].symbolSize = 15;
_option.series[12].symbolSize = 15;
_option.series[13].symbolSize = 15;
_option.series[14].symbolSize = 15;
_option.series[15].symbolSize = 15;
_option.series[16].symbolSize = 15;
_option.series[17].symbolSize = 15;
_option.series[18].symbolSize = 15;
_option.series[1].label.fontSize = '100%';
_option.series[2].label.fontSize = '100%';
_option.series[3].label.fontSize = '100%';
_option.series[4].label.fontSize = '100%';
_option.series[5].label.fontSize = '100%';
_option.series[6].label.fontSize = '100%';
_option.series[7].label.fontSize = '100%';
_option.series[8].label.fontSize = '100%';
_option.series[9].label.fontSize = '100%';
_option.series[10].label.fontSize = '100%';
_option.series[11].label.fontSize = '100%';
_option.series[12].label.fontSize = '100%';
_option.series[13].label.fontSize = '100%';
_option.series[14].label.fontSize = '100%';
_option.series[15].label.fontSize = '100%';
_option.series[16].label.fontSize = '100%';
_option.series[17].label.fontSize = '100%';
_option.series[18].label.fontSize = '100%';
/*_option.series[1].itemStyle.fontSize = '100%';
_option.series[2].itemStyle.fontSize = '100%';
_option.series[3].itemStyle.fontSize = '100%';
_option.series[4].itemStyle.fontSize = '100%';
_option.series[5].itemStyle.fontSize = '100%';
_option.series[6].itemStyle.fontSize = '100%';
_option.series[7].itemStyle.fontSize = '100%';
_option.series[8].itemStyle.fontSize = '100%';
_option.series[9].itemStyle.fontSize = '100%';
_option.series[10].itemStyle.fontSize = '100%';
_option.series[11].itemStyle.fontSize = '100%';
_option.series[12].itemStyle.fontSize = '100%';
_option.series[13].itemStyle.fontSize = '100%';
_option.series[14].itemStyle.fontSize = '100%';
_option.series[15].itemStyle.fontSize = '100%';
_option.series[16].itemStyle.fontSize = '100%';
_option.series[17].itemStyle.fontSize = '100%';
_option.series[18].itemStyle.fontSize = '100%';*/
console.log("字体不变");
}else if(big - small >= 3 && big - small <= 6){
_option.tooltip[0].textStyle.fontSize = 20;
_option.series[1].symbolSize = 20;
_option.series[2].symbolSize = 20;
_option.series[3].symbolSize = 20;
_option.series[4].symbolSize = 20;
_option.series[5].symbolSize = 20;
_option.series[6].symbolSize = 20;
_option.series[7].symbolSize = 20;
_option.series[8].symbolSize = 20;
_option.series[9].symbolSize = 20;
_option.series[10].symbolSize = 20;
_option.series[11].symbolSize = 20;
_option.series[12].symbolSize = 20;
_option.series[13].symbolSize = 20;
_option.series[14].symbolSize = 20;
_option.series[15].symbolSize = 20;
_option.series[16].symbolSize = 20;
_option.series[17].symbolSize = 20;
_option.series[18].symbolSize = 20;
_option.series[1].label.fontSize = 20;
_option.series[2].label.fontSize = 20;
_option.series[3].label.fontSize = 20;
_option.series[4].label.fontSize = 20;
_option.series[5].label.fontSize = 20;
_option.series[6].label.fontSize = 20;
_option.series[7].label.fontSize = 20;
_option.series[8].label.fontSize = 20;
_option.series[9].label.fontSize = 20;
_option.series[10].label.fontSize = 20;
_option.series[11].label.fontSize = 20;
_option.series[12].label.fontSize = 20;
_option.series[13].label.fontSize = 20;
_option.series[14].label.fontSize = 20;
_option.series[15].label.fontSize = 20;
_option.series[16].label.fontSize = 20;
_option.series[17].label.fontSize = 20;
_option.series[18].label.fontSize = 20;
/*_option.series[1].itemStyle.fontSize = 20;
_option.series[2].itemStyle.fontSize = 20;
_option.series[3].itemStyle.fontSize = 20;
_option.series[4].itemStyle.fontSize = 20;
_option.series[5].itemStyle.fontSize = 20;
_option.series[6].itemStyle.fontSize = 20;
_option.series[7].itemStyle.fontSize = 20;
_option.series[8].itemStyle.fontSize = 20;
_option.series[9].itemStyle.fontSize = 20;
_option.series[10].itemStyle.fontSize = 20;
_option.series[11].itemStyle.fontSize = 20;
_option.series[12].itemStyle.fontSize = 20;
_option.series[13].itemStyle.fontSize = 20;
_option.series[14].itemStyle.fontSize = 20;
_option.series[15].itemStyle.fontSize = 20;
_option.series[16].itemStyle.fontSize = 20;
_option.series[17].itemStyle.fontSize = 20;
_option.series[18].itemStyle.fontSize = 20;*/
console.log("字体变成20");
}else if(big - small > 6 && big - small <= 10){
_option.tooltip[0].textStyle.fontSize = 25;
_option.series[1].symbolSize = 25;
_option.series[2].symbolSize = 25;
_option.series[3].symbolSize = 25;
_option.series[4].symbolSize = 25;
_option.series[5].symbolSize = 25;
_option.series[6].symbolSize = 25;
_option.series[7].symbolSize = 25;
_option.series[8].symbolSize = 25;
_option.series[9].symbolSize = 25;
_option.series[10].symbolSize = 25;
_option.series[11].symbolSize = 25;
_option.series[12].symbolSize = 25;
_option.series[13].symbolSize = 25;
_option.series[14].symbolSize = 25;
_option.series[15].symbolSize = 25;
_option.series[16].symbolSize = 25;
_option.series[17].symbolSize = 25;
_option.series[18].symbolSize = 25;
_option.series[1].label.fontSize = 25;
_option.series[2].label.fontSize = 25;
_option.series[3].label.fontSize = 25;
_option.series[4].label.fontSize = 25;
_option.series[5].label.fontSize = 25;
_option.series[6].label.fontSize = 25;
_option.series[7].label.fontSize = 25;
_option.series[8].label.fontSize = 25;
_option.series[9].label.fontSize = 25;
_option.series[10].label.fontSize = 25;
_option.series[11].label.fontSize = 25;
_option.series[12].label.fontSize = 25;
_option.series[13].label.fontSize = 25;
_option.series[14].label.fontSize = 25;
_option.series[15].label.fontSize = 25;
_option.series[16].label.fontSize = 25;
_option.series[17].label.fontSize = 25;
_option.series[18].label.fontSize = 25;
/*_option.series[1].itemStyle.fontSize = 25;
_option.series[2].itemStyle.fontSize = 25;
_option.series[3].itemStyle.fontSize = 25;
_option.series[4].itemStyle.fontSize = 25;
_option.series[5].itemStyle.fontSize = 25;
_option.series[6].itemStyle.fontSize = 25;
_option.series[7].itemStyle.fontSize = 25;
_option.series[8].itemStyle.fontSize = 25;
_option.series[9].itemStyle.fontSize = 25;
_option.series[10].itemStyle.fontSize = 25;
_option.series[11].itemStyle.fontSize = 25;
_option.series[12].itemStyle.fontSize = 25;
_option.series[13].itemStyle.fontSize = 25;
_option.series[14].itemStyle.fontSize = 25;
_option.series[15].itemStyle.fontSize = 25;
_option.series[16].itemStyle.fontSize = 25;
_option.series[17].itemStyle.fontSize = 25;
_option.series[18].itemStyle.fontSize = 25;*/
console.log("字体变成25");
}else if(big - small > 10){
_option.tooltip[0].textStyle.fontSize = 30;
_option.series[1].symbolSize = 30;
_option.series[2].symbolSize = 30;
_option.series[3].symbolSize = 30;
_option.series[4].symbolSize = 30;
_option.series[5].symbolSize = 30;
_option.series[6].symbolSize = 30;
_option.series[7].symbolSize = 30;
_option.series[8].symbolSize = 30;
_option.series[9].symbolSize = 30;
_option.series[10].symbolSize = 30;
_option.series[11].symbolSize = 30;
_option.series[12].symbolSize = 30;
_option.series[13].symbolSize = 30;
_option.series[14].symbolSize = 30;
_option.series[15].symbolSize = 30;
_option.series[16].symbolSize = 30;
_option.series[17].symbolSize = 30;
_option.series[18].symbolSize = 30;
_option.series[2].label.fontSize = 30;
_option.series[3].label.fontSize = 30;
_option.series[4].label.fontSize = 30;
_option.series[5].label.fontSize = 30;
_option.series[6].label.fontSize = 30;
_option.series[7].label.fontSize = 30;
_option.series[8].label.fontSize = 30;
_option.series[9].label.fontSize = 30;
_option.series[10].label.fontSize = 30;
_option.series[11].label.fontSize = 30;
_option.series[12].label.fontSize = 30;
_option.series[13].label.fontSize = 30;
_option.series[14].label.fontSize = 30;
_option.series[15].label.fontSize = 30;
_option.series[16].label.fontSize = 30;
_option.series[17].label.fontSize = 30;
_option.series[18].label.fontSize = 30;
console.log("字体变成30");
}else if(small - big >= 0 && small - big < 3){
_option.tooltip[0].textStyle.fontSize = 15;
_option.series[1].symbolSize = 15;
_option.series[2].symbolSize = 15;
_option.series[3].symbolSize = 15;
_option.series[4].symbolSize = 15;
_option.series[5].symbolSize = 15;
_option.series[6].symbolSize = 15;
_option.series[7].symbolSize = 15;
_option.series[8].symbolSize = 15;
_option.series[9].symbolSize = 15;
_option.series[10].symbolSize = 15;
_option.series[11].symbolSize = 15;
_option.series[12].symbolSize = 15;
_option.series[13].symbolSize = 15;
_option.series[14].symbolSize = 15;
_option.series[15].symbolSize = 15;
_option.series[16].symbolSize = 15;
_option.series[17].symbolSize = 15;
_option.series[18].symbolSize = 15;
_option.series[2].label.fontSize = '100%';
_option.series[3].label.fontSize = '100%';
_option.series[4].label.fontSize = '100%';
_option.series[5].label.fontSize = '100%';
_option.series[6].label.fontSize = '100%';
_option.series[7].label.fontSize = '100%';
_option.series[8].label.fontSize = '100%';
_option.series[9].label.fontSize = '100%';
_option.series[10].label.fontSize = '100%';
_option.series[11].label.fontSize = '100%';
_option.series[12].label.fontSize = '100%';
_option.series[13].label.fontSize = '100%';
_option.series[14].label.fontSize = '100%';
_option.series[15].label.fontSize = '100%';
_option.series[16].label.fontSize = '100%';
_option.series[17].label.fontSize = '100%';
_option.series[18].label.fontSize = '100%';
console.log("字体变成12");
}else if(small - big >= 3 && small - big <= 6){
_option.series[1].symbolSize = 12;
_option.series[2].symbolSize = 12;
_option.series[3].symbolSize = 12;
_option.series[4].symbolSize = 12;
_option.series[5].symbolSize = 12;
_option.series[6].symbolSize = 12;
_option.series[7].symbolSize = 12;
_option.series[8].symbolSize = 12;
_option.series[9].symbolSize = 12;
_option.series[10].symbolSize = 12;
_option.series[11].symbolSize = 12;
_option.series[12].symbolSize = 12;
_option.series[13].symbolSize = 12;
_option.series[14].symbolSize = 12;
_option.series[15].symbolSize = 12;
_option.series[16].symbolSize = 12;
_option.series[17].symbolSize = 12;
_option.series[18].symbolSize = 12;
_option.series[2].label.fontSize = 12;
_option.series[3].label.fontSize = 12;
_option.series[4].label.fontSize = 12;
_option.series[5].label.fontSize = 12;
_option.series[6].label.fontSize = 12;
_option.series[7].label.fontSize = 12;
_option.series[8].label.fontSize = 12;
_option.series[9].label.fontSize = 12;
_option.series[10].label.fontSize = 12;
_option.series[11].label.fontSize = 12;
_option.series[12].label.fontSize = 12;
_option.series[13].label.fontSize = 12;
_option.series[14].label.fontSize = 12;
_option.series[15].label.fontSize = 12;
_option.series[16].label.fontSize = 12;
_option.series[17].label.fontSize = 12;
_option.series[18].label.fontSize = 12;
console.log("字体变成12");
}else if(small - big >6 && small - big <= 10){
_option.series[1].symbolSize = 10;
_option.series[2].symbolSize = 10;
_option.series[3].symbolSize = 10;
_option.series[4].symbolSize = 10;
_option.series[5].symbolSize = 10;
_option.series[6].symbolSize = 10;
_option.series[7].symbolSize = 10;
_option.series[8].symbolSize = 10;
_option.series[9].symbolSize = 10;
_option.series[10].symbolSize = 10;
_option.series[11].symbolSize = 10;
_option.series[12].symbolSize = 10;
_option.series[13].symbolSize = 10;
_option.series[14].symbolSize = 10;
_option.series[15].symbolSize = 10;
_option.series[16].symbolSize = 10;
_option.series[17].symbolSize = 10;
_option.series[18].symbolSize = 10;
_option.series[2].label.fontSize = 10;
_option.series[3].label.fontSize = 10;
_option.series[4].label.fontSize = 10;
_option.series[5].label.fontSize = 10;
_option.series[6].label.fontSize = 10;
_option.series[7].label.fontSize = 10;
_option.series[8].label.fontSize = 10;
_option.series[9].label.fontSize = 10;
_option.series[10].label.fontSize = 10;
_option.series[11].label.fontSize = 10;
_option.series[12].label.fontSize = 10;
_option.series[13].label.fontSize = 10;
_option.series[14].label.fontSize = 10;
_option.series[15].label.fontSize = 10;
_option.series[16].label.fontSize = 10;
_option.series[17].label.fontSize = 10;
_option.series[18].label.fontSize = 10;
console.log("字体变成10");
}else if(small - big > 10){
_option.series[1].symbolSize = 8;
_option.series[2].symbolSize = 8;
_option.series[3].symbolSize = 8;
_option.series[4].symbolSize = 8;
_option.series[5].symbolSize = 8;
_option.series[6].symbolSize = 8;
_option.series[7].symbolSize = 8;
_option.series[8].symbolSize = 8;
_option.series[9].symbolSize = 8;
_option.series[10].symbolSize = 8;
_option.series[11].symbolSize = 8;
_option.series[12].symbolSize = 8;
_option.series[13].symbolSize = 8;
_option.series[14].symbolSize = 8;
_option.series[15].symbolSize = 8;
_option.series[16].symbolSize = 8;
_option.series[17].symbolSize = 8;
_option.series[18].symbolSize = 8;
_option.series[2].label.fontSize = 8;
_option.series[3].label.fontSize = 8;
_option.series[4].label.fontSize = 8;
_option.series[5].label.fontSize = 8;
_option.series[6].label.fontSize = 8;
_option.series[7].label.fontSize = 8;
_option.series[8].label.fontSize = 8;
_option.series[9].label.fontSize = 8;
_option.series[10].label.fontSize = 8;
_option.series[11].label.fontSize = 8;
_option.series[12].label.fontSize = 8;
_option.series[13].label.fontSize = 8;
_option.series[14].label.fontSize = 8;
_option.series[15].label.fontSize = 8;
_option.series[16].label.fontSize = 8;
_option.series[17].label.fontSize = 8;
_option.series[18].label.fontSize = 8;
console.log("字体变成8");
}
myChart.clear();
myChart.setOption(_option);
});
option =
{
backgroundColor : '#FFFFFF',
title : {
top : 20,
text : '',
subtext : '',
x : 'center',
textStyle : {
color : '#ccc'
}
},
visualMap : {
show : false,
min : 0,
max : 500,
text : [ '高', '低' ],
x : 'left',
y : 'center',
realtime : false,
calculable : true,
inRange : {
color : ['#00E3E3','#00FFFF','#A6FFFF','#E8FFF5','#54A990','#D2E9FF']
}
},
tooltip : {
trigger : 'item',
textStyle : {
fontSize : 15
},
formatter : function(params) {
if (params.seriesType == 'scatter') {
return params.data.name;
} else if (params.seriesType == 'lines') {
return params.data.name;
}
}
},
legend : {
//selectedMode:false,
orient: 'horizontal', // 'vertical'
x: '0.5%', // 'center' | 'left' | {number},
y: '47%', // 'center' | 'bottom' | {number}
backgroundColor: '#fff',
shadowBlur:3,
shadowColor:'#333',
// borderColor: 'rgba(178,34,34,0.8)',
borderWidth: 0,
padding: 10, // [5, 10, 15, 20]
itemGap: 20,
data : [
{
name : '1000kV变电站',
// 强制设置图形为圆。
icon : 'image://' + station1000b,
// 设置文本为红色
},{
name : '抽水蓄能电站',
// 强制设置图形为圆。
icon : 'image://' + stationcsxndz,
// 设置文本为红色
},{
name : '',
},{
name : '500kV变电站 ',
// 强制设置图形为圆。
icon : 'image://' + station500b,
// 设置文本为红色
}, {
name : '1000kV线路',
// 强制设置图形为圆。
icon : 'image://' + line1000 ,
// 设置文本为红色
textStyle : {
color : '111'
}
},{
name : '',
},{
name : '500kV开关站 ',
// 强制设置图形为圆。
icon : 'image://' + station500k,
// 设置文本为红色
}, {
name : '500kV线路',
// 强制设置图形为圆。
icon : 'image://' + line500,
// 设置文本为红色
textStyle : {
color : '111'
}
},{
name : '',
},{
name : '换流站 ',
// 强制设置图形为圆。
icon : 'image://' + stationhlz,
// 设置文本为红色
},{
name : '±800kV直流线',
// 强制设置图形为圆。
icon : 'image://' + line800,
// 设置文本为红色
},{
name : '',
},{
name : '串补站 ',
// 强制设置图形为圆。
icon : 'image://' + stationcbz,
// 设置文本为红色
},{
name : '±500kV直流线',
// 强制设置图形为圆。
icon : 'image://' + line500zlx,
// 设置文本为红色
},{
name : '',
},{
name : '水电站 ',
// 强制设置图形为圆。
icon : 'image://' + stationsdz,
// 设置文本为红色
},{
name : '华中直属资产',
// 强制设置图形为圆。
icon : 'image://' + linehuazhong ,
// 设置文本为红色
textStyle : {
color : '#111'
}
},{
name : '',
},{
name : '火电站',
// 强制设置图形为圆。
icon : 'image://' + stationhdz,
// 设置文本为红色
}/*,
{
name : '高亮',
show:false,
// 强制设置图形为圆。
icon : 'image://' + line ,
// 设置文本为红色
textStyle : {
color : '#fff'
}
},
{
name : '高亮变电站',
show:false,
// 强制设置图形为圆。
icon : 'image://' + stationhdz ,
// 设置文本为黄色
textStyle : {
color : 'yellow'
}
}*/
]
},
geo : {
show : true,
map : '华中',
mapType : '华中',
label : {
normal : {
show : false,
color : '#111'
},
emphasis : {
show : false,
}
},
//silent : true,
aspectScale : 0.75, //长宽比
roam : true,
center:[108,30],
//zoom:1.1,
//layoutCenter: ['50%', '50%'],
// 如果宽高比大于 1 则宽度为 100,如果小于 1 则高度为 100,保证了不超过 100x100 的区域
//layoutSize: 1200,
// selectedMode:false,
//scaleLimit: { min: 1.0, max:60 },//缩放
itemStyle : {
normal : {
areaColor : 'transparent',
borderColor : '#3fdaff',
borderWidth : 2,
shadowColor : 'rgba(63, 218, 255, 0.5)',
shadowBlur : 30
},
emphasis : {
//areaColor : 'yellow',
}
}
},
series : [
{
name : '',
type : 'map',
geoIndex : 0,
mapType : '华中', // 自定义扩展图表类型
itemStyle : {
normal : {
label : {
show : false,
color:'#111'
}
},
emphasis : {
label : {
show : false
}
}
},
data : [
{
name : '湖北',
value:'000',
itemStyle: {
normal: {
color: '#111'
}
}
},
{
name : '湖南',
value:'200',
itemStyle: {
normal: {
color: '#111'
}
}
},
{
name : '河南',
value:'100',
itemStyle: {
normal: {
color: '#111'
}
}
},{
name : '江西',
value:'300',
itemStyle: {
normal: {
color: '#111'
}
}
},
{
name : '四川',
value:'400',
itemStyle: {
normal: {
color: '#111'
}
}
},
{
name : '重庆',
value:'500',
itemStyle: {
normal: {
color: '#111'
}
}
}
],
}, {
name : '图例',
type : 'scatter',
coordinateSystem : 'geo',
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + station,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
offset : [ 10, 20 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},
{
name : '变电站',
type : 'scatter',
coordinateSystem : 'geo',
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + line,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},
{
name : '1000kV变电站',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr1,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + station1000b,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : 50
}
},
},{
name : '500kV变电站 ',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr2,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + station500b,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},{
name : '500kV开关站 ',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr3,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + station500k,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},{
name : '换流站 ',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr4,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + stationhlz,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},{
name : '串补站 ',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr5,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + stationcbz,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},{
name : '水电站',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr6,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + stationsdz,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},{
name : '火电站',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr7,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + stationhdz,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},{
name : '抽水蓄能电站',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr8,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + stationcsxndz,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : '#111',
fontSize : '100%'
}
},
},
{
name : '华中直属资产',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr9,
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + stationhuazhong,
label : {
normal : {
show : true,
position : 'top',
formatter : '{b}',
color : '#111',
//offset : [ 30, 40 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
normal : {
color : 'red',
fontSize : '100%'
}
},
},
{
name : '1000kV线路',
type : 'lines',
coordinateSystem : 'geo',
zlevel : 2,
large : true,
effect : {
show : false,
constantSpeed : 20,
symbol : 'arrow', //ECharts 提供的标记类型包括 'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
symbolSize : 3,
trailLength : 0.08,
},
label : {
normal : {
show : false,
position : 'middle',
color : '#fff'
}
},
lineStyle : {
normal : {
color : 'black',
width : 2,
opacity : 1,
curveness : 0
}
},
data : lineArr1
}
,
{
name : '500kV线路',
type : 'lines',
coordinateSystem : 'geo',
zlevel : 2,
large : true,
effect : {
show : false,
constantSpeed : 20,
symbol : 'arrow', //ECharts 提供的标记类型包括 'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
symbolSize : 3,
trailLength : 0.08,
},
label : {
normal : {
show : false,
position : 'middle',
color : '#111'
}
},
lineStyle : {
normal : {
color : 'blue',
width : 2,
opacity : 1,
curveness : 0
}
},
data : lineArr2
} ,
{
name : '±800kV直流线',
type : 'lines',
coordinateSystem : 'geo',
zlevel : 2,
large : true,
effect : {
show : false,
constantSpeed : 20,
symbol : 'arrow', //ECharts 提供的标记类型包括 'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
symbolSize : 3,
trailLength : 0.08,
},
label : {
normal : {
show : false,
position : 'middle',
color : '#111'
}
},
lineStyle : {
normal : {
color : '#12d3d5',
width : 2,
opacity : 1,
curveness : 0
}
},
data : lineArr3
} ,{
name : '±500kV直流线',
type : 'lines',
coordinateSystem : 'geo',
zlevel : 2,
large : true,
effect : {
show : false,
constantSpeed : 20,
symbol : 'arrow', //ECharts 提供的标记类型包括 'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
symbolSize : 3,
trailLength : 0.08,
},
label : {
normal : {
show : false,
position : 'middle',
color : '#111'
}
},
lineStyle : {
normal : {
color : 'green',
width : 2,
opacity : 1,
curveness : 0
}
},
data : lineArr4
} ,
{
name : '华中直属资产',
type : 'lines',
coordinateSystem : 'geo',
zlevel : 2,
large : true,
effect : {
show : false,
constantSpeed : 20,
symbol : 'arrow', //ECharts 提供的标记类型包括 'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
symbolSize : 3,
trailLength : 0.08,
},
label : {
normal : {
show : false,
position : 'middle',
color : '#111'
}
},
lineStyle : {
normal : {
color : 'red',
width : 2,
opacity : 1,
curveness : 0
}
},
data : lineArr5
},
{
name : '高亮',
type : 'lines',
coordinateSystem : 'geo',
zlevel : 2,
large : true,
effect : {
show : false,
constantSpeed : 20,
symbol : 'arrow', //ECharts 提供的标记类型包括 'circle', 'rect', 'roundRect', 'triangle', 'diamond', 'pin', 'arrow'
symbolSize : 3,
trailLength : 0.08,
},
label : {
normal : {
show : false,
position : 'middle',
color : '#111'
}
},
lineStyle : {
normal : {
color : 'yellow',
width : 3,
opacity : 1,
curveness : 0
}
},
data : lineArr6 //动态改变数据
} ,
{
name : '高亮变电站',
type : 'scatter',
coordinateSystem : 'geo',
data : subArr10,
effrctType:'ripple',
symbolSize : function(val) {
return 15;
},
symbol : 'image://' + bdzgl,
//symbol : 'circle',
label : {
normal : {
show : false,
position : 'top',
formatter : '{b}',
color : '#111',
offset : [ 10, 20 ],
fontSize : '100%'
},
emphasis : {
show : true,
position : 'right',
formatter : '{b}'
}
},
itemStyle : {
color : 'yellow',
normal : {
color : 'yellow',
fontSize : '100%'
}
}
}
]
}
option.legend.show=false;
myChart.setOption(option,true);
var picInfo=myChart.getDataURL();
ajaxPost(ServerURL + '/api/introdution/ECharts_ditu', {'picInfo': picInfo,'imgname':'ditu0'}, function (resdata) {});
});
}
function view(){
layer.open({
title : '详细信息',
type : 2,
skin : 'layui-layer-molv', //样式类名
shade : [ 0.1, '#fff' ],
// closeBtn : 1, //不显示关闭按钮
shift : 2,
area : [ '720px', '520px' ], //宽高
shadeClose : true, //开启遮罩关闭
content:'/systemUI/system/module/zszc/zhzs/jsp/html/view.html'
});
}
//重置
function reset(){
$("#year").val("");
$("#lineName").val("");
$("#area").val("");
}
//跳转离线地图
function outLineMap(){
window.location.href="stations.html";
}
function openIntroduction(){
layer.open({
title : '简介',
type : 2,
skin : 'layui-layer-molv', //样式类名
shade : [ 0.1, '#fff' ],
// closeBtn : 1, //不显示关闭按钮
shift : 2,
area : [ '520px', '520px' ], //宽高
shadeClose : true, //开启遮罩关闭
content:'/systemUI/system/module/zszc/zhzs/jsp/html/introduction.html'
});
}
function openWord(){
//location.href=ServerURL + '/api/SvgMap/downLoadWord';
location.href=ServerURL + '/api/SubStation/downLoadWord';
}
function openWord1(){
//location.href=ServerURL + '/api/SvgMap/downLoadWord';
location.href=ServerURL + '/api/Lineinfo/downLoadWord';
}
function openWord0(){
ditus();
layer.open({
title : '生成图册',
type : 2,
skin : 'layui-layer-molv', //样式类名
shade : [ 0.1, '#fff' ],
// closeBtn : 1, //不显示关闭按钮
shift : 2,
area : [ '350px', '150px' ], //宽高
shadeClose : true, //开启遮罩关闭
content:'/systemUI/system/module/zszc/zhzs/jsp/html/export.html'
});
}
//地图统计
function showDTTJ(){
ajaxPost(ServerURL + '/api/SubStation/getDTData', null, function (EchartsGroupData) {
var groupData = EchartsGroupData.data.data;
//变电站数量
var bdzsl=groupData.BDZSL;
//主变压器
var zbyq=groupData.ZBYQ;
//变电站容量
var bdzrl=groupData.BDZRL;
//输电线路条数
var sdxlts=groupData.SDXLTS;
//线路总长度
var xlzcd=groupData.XLZCD;
//杆塔基数
var gtjs=groupData.GTJS;
$("#bdzsl").html(bdzsl);
$("#zbyq").html(zbyq);
$("#bdzrl").html(bdzrl);
$("#sdxlts").html(sdxlts);
$("#xlzcd").html(xlzcd);
$("#gtjs").html(gtjs);
$("#tt2_div1").attr("title","变电站数量:"+bdzsl+"座 主变压器:"+zbyq+"台 变电站容量:"+bdzrl+"MVA");
$("#tt2_div2").attr("title","输电线路条数:"+sdxlts+"条 输电线路长度:"+xlzcd+"KM 杆塔基数:"+gtjs);
});
}