123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302 |
- <!DOCTYPE html>
- <html>
- <head>
- <title>设备受损受损曲线图</title>
- <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE9" />
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/jquery.js"></script>
- <script type="text/javascript" src="/nwyj/scripts/cockpit/cockpitIndex/context.js"></script>
- <script type="text/javascript" src="/nwyj/page/cockpit/echarts-2.2.7/build/dist/echarts.min.js"></script>
- <script type="text/javascript" src="/nwyj/page/cockpit/echarts-2.2.7/build/dist/echarts-all.min.js"></script>
- <script type="text/javascript" src="/nwyj/page/cockpit/echarts-2.2.7/build/dist/chart/line.js"></script>
- <script type="text/javascript" src=" /nwyj/page/cockpit/cockpit_echart.js"></script>
- <!-- <script type="text/javascript" src=" /nwyj/page/cockpit/webgis/util.js"></script> -->
- <script type="text/javascript" src="/nwyj/scripts/cockpit/cockpitIndex/util.js"></script>
- <link rel="stylesheet" type="text/css" href=" /nwyj/css/cockpit/commom/ehcartPage.css" />
- <!--框架必需start 扁平风格-->
- <link href="/nwyj/scripts/qui/libs/css/import_basic.css" rel="stylesheet" type="text/css"/>
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/jquery.js"></script>
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/language/cn.js"></script>
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/framework.js"></script>
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/main.js"></script>
- <!--框架必需end-->
- <!--树组件start-->
- <link rel="stylesheet" type="text/css" href="/nwyj/scripts/qui/libs/js/tree/ztree/ztree.css" />
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/tree/ztree/ztree.js"></script>
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/form/selectTree.js"></script>
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/form/listerTree.js"></script>
- <!--树组件end-->
- <!--自动提示框start-->
- <script type='text/javascript' src='/nwyj/scripts/qui/libs/js/form/suggestion.js'></script>
- <!--自动提示框end-->
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/form/datePicker/WdatePicker.js"></script>
- <!-- 日期选择框start -->
- <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/form/datePicker/WdatePicker.js"></script>
- <!-- 日期选择框end -->
- <!-- 驾驶舱与首页显示的样式 star -->
- <script type="text/javascript" src="/nwyj/scripts/cockpit/cockpitIndex/cockpitANDmainIndex.js"></script>
- <!-- 驾驶舱与首页显示的样式 end -->
- <script type="text/javascript" src="/nwyj/scripts/cockpit/search/public_search_char.js"></script>
- <link rel="stylesheet" type="text/css" href="/nwyj/css/cockpit/search/char_search.css">
- <script type='text/javascript' src='/nwyj/dwr/engine.js'></script>
- <script type='text/javascript' src='/nwyj/dwr/util.js'></script>
- <script type="text/javascript" src="/nwyj/scripts/cockpit/search/search_util.js"></script>
- </head>
- <body onload="dwr.engine.setActiveReverseAjax(true);dwr.engine.setNotifyServerOnPageUnload(true);">
- <div id="i_page_main" class="c_page_main">
- <div id="i_page_head" class="c_page_head">
- <div id="i_page_head_title">
- </div>
- <div id="i_page_head_subtitle"></div>
- </div>
- <div id="triangleOut" class="triangle"></div>
- <div id="searchByTime" class="sbt">
- <span>开始时间:</span><input type="text" id="beginTime" class="date dt" dateFmt="yyyy-MM-dd"/>
- <!-- <span>开始时间:</span><input type="text" id="beginTime" class="date dt" style="width:185px;" dateFmt="yyyy-MM-dd HH:mm:ss"/> -->
- <br>
- <span>截止时间:</span><input type="text" id="endTime" class="date dt" dateFmt="yyyy-MM-dd"/>
- <!-- <span>截止时间:</span><input type="text" id="endTime" class="date dt" style="width:185px;" dateFmt="yyyy-MM-dd HH:mm:ss"/> -->
- <br>
- <div class="sb"><button id="search">查询</button></div>
- <div class="triangleIn"></div>
- </div>
- <div id="i_page_chart" class="c_page_chart">
- </div>
- </div>
- <script type="text/javascript">
-
- var pageParam={};
- var chart=null;
- var utils=new Util();
- var searchUtil = new SearchUtil();
- $(function(){
- pageParam.style=utils.resolveUrl()["style"]||"style1";
- pageParam.title=utils.resolveUrl()["title"]||"广东电网";
- pageParam.number=utils.resolveUrl()["number"]||warnningnumber;
- pageParam.parentId=utils.resolveUrl()["dept_id"]||"11";
- pageParam.startTime=start;
- pageParam.endTime=end;
- pageParam.isalert=null;
- if(pageParam.number.split("|")[0]=="预警"){
- pageParam.isalert="0";
- }else{
- pageParam.isalert="1";
- }
- pageParam.number=pageParam.number.split("|")[1];
- init();
- });
- function init(){
- if(utils.resolveUrl().dataSourceState==0){
- loadChart(pageParam);
- }else{
- changeSysDataLoadChart(pageParam);
- }
- }
- function loadChart(jsonParam){
- setTitle();
- $.post("/nwyj/ws/ChartServiceImpl/ChartServiceImpl/getCompResentNRecodesInfo",{charType:"shebeisousun",sepratestr:"-",name:"getProiedRecodesAfterNumber",parentId:jsonParam.parentId,start:jsonParam.startTime,end:jsonParam.endTime,isalert:pageParam.isalert,number:pageParam.number,viewName:"REPORT_LINE_DAOGAN_VIEW-REPORT_LINE_DAOGAN_VIEW"},function(result){
-
- if(result.rows.length==0){
- zeroChartIntoParam("暂无填报数据");
- return;
- }
- veriColor();
- removeNoData();
- var sArr=[{type:"line",name:"主网",data:[],
- itemStyle: {
- normal: {
- color:pageStyle[jsonParam.style]["chartColor"][0],
- label:{show:true,
- position:"top",
- textStyle:{color: "rgb(255, 255, 255)",fontSize: 14,fontStyle: "normal",fontWeight: "bold"}
- }
- }
-
- }
-
- },
- {type:"line",name:"配网",data:[],
- itemStyle: {
- normal: {
- color:pageStyle[jsonParam.style]["chartColor"][1],
- label:{show:true,
- position:"top",
- textStyle:{color: "rgb(255, 255, 255)",fontSize: 14,fontStyle: "normal",fontWeight: "bold"}
- }
-
- }
-
- }
-
-
- }];
- var xAxis=[];
- /* var tempArr= result.rows.sort(sortFn); */
- var data=result.rows[0];
- //alert(JSON.stringify(data));
- for(var index=0,len=result.rows.length;index<len;index++){
- var item=result.rows[index];
- var main=utils.changeQ(item["main"])/* +utils.changeQ(item["PLON_BIANXING_500"])+utils.changeQ(item["PLON_DAOTA_200"])+utils.changeQ(item["PLON_BIANXING_200"])+utils.changeQ(item["PLON_DAOTA_110"])+
- utils.changeQ(item["PLON_BIANXING_110"])+utils.changeQ(item["DUANGAN_110"])+utils.changeQ(item["DIANGAN_QIGNXIE_110"])+utils.changeQ(item["PLON_DAOTA_35"])+utils.changeQ(item["PLON_BIANXING_35"])+
- utils.changeQ(item["DUANGAN_35"])+utils.changeQ(item["DAOGAN_35"])+utils.changeQ(item["DIANGAN_QIGNXIE_35"]); */
-
- var help=utils.changeQ(item["help"])/* +utils.changeQ(item["PLON_BIANXING_10"])+utils.changeQ(item["DUANGAN_10"])+utils.changeQ(item["DIANGAN_QIGNXIE_10"])+utils.changeQ(item["DAUNGAN_DIYA"])+
- utils.changeQ(item["DAOGAN_DIYA"])+utils.changeQ(item["DAOGAN_DIYA"])+utils.changeQ(item["QINGGAN_DIYA"]); */
-
- //sArr[0].data.push(main);
- //sArr[1].data.push(help);
- //alert(item["APPEAR_TIME"]);
- //xAxis.push(item["APPEAR_TIME"]);
- sArr[0].data.push(main);
- sArr[1].data.push(help);
- var time = item["APPEAR_TIME"];
- var dt = new Date(time.replace(/-/,"/"));
- //alert(dt.getFullYear()+"-"+(dt.getMonth()+1)+"-"+dt.getDate() +" "+dt.getHours()+":"+dt.getMinutes());
- //xAxis.push(dt.getFullYear()+"-"+(dt.getMonth()+1)+"-"+dt.getDate() +" "+dt.getHours()+":"+dt.getMinutes());
- xAxis.push(dt.getFullYear()+"-"+(dt.getMonth()+1)+"-"+dt.getDate() +" "+dt.getHours()+"时");
- }
- /* var tempArr= result.rows.sort(sortFn); */
- pageParam.opParams={
- //title:""/* "停运最多时间:"+tempArr[0]["sum"] */,//标题
- title:"起始时间:"+item["SEND_TIME"]+":00"+"\n截至时间:"+item["APPEAR_TIME"],//标题
- subtext:""/* (result["max"]["DEPT_NAME"] || "广东")+(result["max"]["sum"] || "100") */,
- saveName:$("#i_page_head_title").find("h2").html()+searchUtil.getNowFormatDateTime(new Date),
- unit:"座",//单位
- leArr:["主网","配网"],//图例
- xAxis:xAxis,//x轴
- sArr:sArr,//主数据
- trigger:"axis",
- value:"value",
- legendColor:legendC,
- xAxisColor:xAxisC,
- yAxisColor:yAxisC
- };
- chart=getEchart($("#i_page_chart"),getOption,pageParam.opParams,null);
-
- bindEvent();
- },"json");
- }
- /**
- *设置标题
- */
- function setTitle(){
- $("#i_page_head_title").find("h2").remove();
- if(pageParam.title=="广东电网有限责任公司"){
- pageParam.title="广东电网公司";
- }
- $("#i_page_head_title").append("<h2>"+pageParam.title+"主配网设备受损曲线</h2>");
- }
- function bindEvent(){
- $(window).resize(function(){
- chart.resize();
- });
-
- }
- /*dwr推送人工数据方法 */
- function dwrData(number){
- if(0!=top.dataSourceState) return;
- // if(number== pageParam.number){
- loadChart(pageParam);
- // }
- }
- /*dwr推送系统数据方法 */
- function dwrSysData(number){
- if(1!=top.dataSourceState) return;
- //如果需要关联通知单,放开注释即可
- // if(number== pageParam.number){
- changeSysData(pageParam);
- // }
- }
- /**********************************************************************************************/
- function changeSysData(number){
- pageParam.number=number;
- changeSysDataLoadChart(pageParam)
- }
- function changeSysDataLoadChart(jsonParam){
- setTitle();
- if("8F6F2D6B24494CB6B1F1E0931E7AF87D"!= jsonParam.parentId){
- zeroChartIntoParam("本单位未提供系统数据源");
- return;
- }
- $.post("/nwyj/ws/SystemDataSourceChartServiceImpl/SystemDataSourceChartServiceImpl/getDaoGanReportDeptByPeroidInfo",
- {compId:jsonParam.parentId,startTime:jsonParam.startTime,endTime:jsonParam.endTime},function(result){
- if(result.rows.length==0){
- zeroChartIntoParam("目前此时间段内尚无推送关联数据");
- return;
- }
- veriColor();
- removeNoData();
- var sArr=[{type:"line",name:"主网",data:[],
- itemStyle: {
- normal: {color:pageStyle[jsonParam.style]["chartColor"][0]}}
- },
- {type:"line",name:"配网",data:[],
- itemStyle: {
- normal: {color:pageStyle[jsonParam.style]["chartColor"][1]}}
-
- }];
- var xAxis=[];
- /* var tempArr= result.rows.sort(sortFn); */
- var data=result.rows[0];
- for(var index=0,len=result.rows.length;index<len;index++){
- var item=result.rows[index];
- var main=utils.changeQ(item["main"])/* +utils.changeQ(item["PLON_BIANXING_500"])+utils.changeQ(item["PLON_DAOTA_200"])+utils.changeQ(item["PLON_BIANXING_200"])+utils.changeQ(item["PLON_DAOTA_110"])+
- utils.changeQ(item["PLON_BIANXING_110"])+utils.changeQ(item["DUANGAN_110"])+utils.changeQ(item["DIANGAN_QIGNXIE_110"])+utils.changeQ(item["PLON_DAOTA_35"])+utils.changeQ(item["PLON_BIANXING_35"])+
- utils.changeQ(item["DUANGAN_35"])+utils.changeQ(item["DAOGAN_35"])+utils.changeQ(item["DIANGAN_QIGNXIE_35"]); */
-
- var help=utils.changeQ(item["help"])/* +utils.changeQ(item["PLON_BIANXING_10"])+utils.changeQ(item["DUANGAN_10"])+utils.changeQ(item["DIANGAN_QIGNXIE_10"])+utils.changeQ(item["DAUNGAN_DIYA"])+
- utils.changeQ(item["DAOGAN_DIYA"])+utils.changeQ(item["DAOGAN_DIYA"])+utils.changeQ(item["QINGGAN_DIYA"]); */
-
- sArr[0].data.push(main);
- sArr[1].data.push(help);
- var time = item["APPEAR_TIME"];
- var dt = new Date(time.replace(/-/,"/"));
- //alert(dt.getFullYear()+"-"+(dt.getMonth()+1)+"-"+dt.getDate() +" "+dt.getHours()+":"+dt.getMinutes());
- xAxis.push(dt.getFullYear()+"-"+(dt.getMonth()+1)+"-"+dt.getDate() +" "+dt.getHours()+":"+dt.getMinutes());
- }
- /* var tempArr= result.rows.sort(sortFn); */
- pageParam.opParams={
- title:"截止时间:"+subDate(data["APPEAR_TIME"]),//标题
- subtext:""/* (result["max"]["DEPT_NAME"] || "广东")+(result["max"]["sum"] || "100") */,
- saveName:$("#i_page_head_title").find("h2").html()+searchUtil.getNowFormatDateTime(new Date),
- unit:"座",//单位
- leArr:["主网","配网"],//图例
- xAxis:xAxis,//x轴
- sArr:sArr,//主数据
- trigger:"axis",
- value:"value",
- legendColor:legendC,
- xAxisColor:xAxisC,
- yAxisColor:yAxisC
- };
- chart=getEchart($("#i_page_chart"),getOption,pageParam.opParams,null);
- setTitle();
- bindEvent();
- },"json");
- }
- function subStrDate(strDate){
- strDate=strDate.substring(strDate.indexOf(":")+1,strDate.indexOf("."));
- return strDate;
-
- }
-
- function subDate(str){
- if(str==null || str==undefined) return "-";
- return str.substring(0,str.indexOf("."));
- }
- </script>
- </body>
- </html>
|