|  |  | 
 |  |  | <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%> | 
 |  |  | <%@page isELIgnored="false" %> | 
 |  |  | <% | 
 |  |  |    String version ="1.000003"; | 
 |  |  |    String version ="1.000004"; | 
 |  |  |    response.setHeader("Cache-Control","no-store"); | 
 |  |  |    response.setHeader("Pragrma","no-cache"); | 
 |  |  |    response.setDateHeader("Expires",0); | 
 |  |  | 
 |  |  |   padding:0; | 
 |  |  |   list-style:none; | 
 |  |  | } | 
 |  |  |  | 
 |  |  | a{ | 
 |  |  |     color: #1900c6; | 
 |  |  |    text-decoration: none; | 
 |  |  |    cursor: pointer; | 
 |  |  |    font-size: 14px; | 
 |  |  |    font-weight: 300; | 
 |  |  | } | 
 |  |  | a:hover { | 
 |  |  |    text-decoration: underline; | 
 |  |  |    color: #e60012; | 
 |  |  | } | 
 |  |  | #popup_box { | 
 |  |  |    top: 75px; | 
 |  |  |    left: 20px; | 
 |  |  | 
 |  |  |    float: right; | 
 |  |  |    width: 70px; | 
 |  |  |    height: 28px; | 
 |  |  |    line-height: 28px | 
 |  |  |    line-height: 28px; | 
 |  |  |    cursor:pointer; | 
 |  |  | } | 
 |  |  |  | 
 |  |  | .list { | 
 |  |  | 
 |  |  |  | 
 |  |  | .list .state01 { | 
 |  |  |    background-color: #FF9; | 
 |  |  |     color: #ff7f00; | 
 |  |  | } | 
 |  |  |  | 
 |  |  | .list .state02 { | 
 |  |  | 
 |  |  | .equ-data-box .equ-data-list li .grade01{color:#282828;background:url(/img/list_num_yellow.png) left top no-repeat} | 
 |  |  | .equ-data-box .equ-data-list li .grade02{background:url(/img/list_num_orange.png) left top no-repeat} | 
 |  |  | .equ-data-box .equ-data-list li .grade03{background:url(/img/list_num_red.png) left top no-repeat} | 
 |  |  | .tools_box{ | 
 |  |  |    position: absolute; | 
 |  |  |    height: 120px; | 
 |  |  |    width: 400px; | 
 |  |  |    right: 1px; | 
 |  |  |    top: 20px; | 
 |  |  |    z-index: 1; | 
 |  |  | } | 
 |  |  |  .tools_box .charts_btn { | 
 |  |  |     position: relative; | 
 |  |  |    float: right; | 
 |  |  |    margin: 0; | 
 |  |  |    border: 0; | 
 |  |  |     height: 85px; | 
 |  |  |     width: 85px; | 
 |  |  |     background:url(/img/charts_btn_bg_1.png) left top no-repeat; | 
 |  |  |    background-size: 70%; | 
 |  |  |  } | 
 |  |  |  .tools_box .charts_btn:hover { | 
 |  |  |     cursor:pointer; | 
 |  |  |     background:url(/img/charts_btn_bg_2.png) left top no-repeat; | 
 |  |  |     background-size: 70%; | 
 |  |  |  } | 
 |  |  | </style> | 
 |  |  | <body> | 
 |  |  | <div class="main_body"> | 
 |  |  |        <div class="tools_box"> | 
 |  |  |          <div class="charts_btn"> | 
 |  |  |          </div> | 
 |  |  |       </div> | 
 |  |  |        <div class="search_box"> | 
 |  |  |       <button id="searchBtn" type="button">搜索</button> | 
 |  |  |       <input id="searchParam"/> | 
 |  |  | 
 |  |  |      window["listView"] = listView; | 
 |  |  |    //展示设备列表,click事件触发 | 
 |  |  |    function showEqus(obj) { | 
 |  |  |  | 
 |  |  |       var params = moralMap['params']; | 
 |  |  |       var mpoint = obj.currentTarget.getOption(); | 
 |  |  |         $("#searchParam").val(mpoint['name']); | 
 |  |  |       var url = 'get-devices-by-mid-oid?mpId=' + mpoint['id'] + "&orgId=" + params['orgId']; | 
 |  |  |       listView.load(url);  | 
 |  |  |       moralMap.showPopupbox("#popup_box"); | 
 |  |  | 
 |  |  |                                            return; | 
 |  |  |                                        } | 
 |  |  |                                   var equ = { | 
 |  |  |                                methodName : 'showDeviceMonitor', | 
 |  |  |                               name: _obj['name'], | 
 |  |  |                               mac: (_obj['mac']).toLowerCase(), | 
 |  |  |                               longitude: _obj['longitude'], | 
 |  |  |                               latitude: _obj['latitude'], | 
 |  |  |                                         monitorPointId: _obj['monitorPointId'], | 
 |  |  |                                version:_obj['deviceVersion']['version'] | 
 |  |  |                            } | 
 |  |  |                            var equStr = JSON.stringify(equ); | 
 |  |  |                            if(window["console"]!=undefined){ | 
 |  |  |                               console.log(equStr); | 
 |  |  |                            } | 
 |  |  |                             if(window['external']&&window['external']['showMonitorInfo']){ | 
 |  |  |                                  if(!!window['external']&&window['external']['callWin']){ | 
 |  |  |                                         window['external'].callWin(equStr); | 
 |  |  |                            }else | 
 |  |  |                             if(!!window['external']&&window['external']['showMonitorInfo']){ | 
 |  |  |                                 window['external'].showMonitorInfo(equStr); | 
 |  |  |                              }else{ | 
 |  |  |                                 alert(equStr); | 
 |  |  | 
 |  |  |    //地图加载完成后 加载监控点,速度慢 | 
 |  |  |    moralMap.addEventListener("tilesloaded", function(type, target) { | 
 |  |  |    }); | 
 |  |  |    // 点击事件关闭 弹窗列表 | 
 |  |  |     moralMap.addEventListener("click", function(type, target) { | 
 |  |  |         moralMap.closePopupbox("#popup_box"); | 
 |  |  |     }); | 
 |  |  |    //地图放大缩小事件时,关闭弹窗 | 
 |  |  |    moralMap.addEventListener('zoomstart', function(type) {}); | 
 |  |  |    //地图放大缩小事件时,关闭弹窗 | 
 |  |  | 
 |  |  |          var url = 'get-devices-for-popup?name=' + param + "&orgId=" + params['orgId']; | 
 |  |  |          listView.load(url);  | 
 |  |  |       } | 
 |  |  |    ) | 
 |  |  |    ); | 
 |  |  |    $("#searchParam").keydown(function (event) { | 
 |  |  |         if(event.keyCode ==13) { | 
 |  |  |             $("#searchBtn").trigger("click"); | 
 |  |  |         } | 
 |  |  |     }) | 
 |  |  |    //跳转表单页面按钮事件 | 
 |  |  |    $(".charts_btn").click( | 
 |  |  |        function (e) { | 
 |  |  |             var obj = {}; | 
 |  |  |             obj['methodName'] = 'showChart'; | 
 |  |  |             var objStr = JSON.stringify(obj); | 
 |  |  |             if(!!window['external']&&window['external']['callWin']){ | 
 |  |  |                 window['external'].callWin(objStr); | 
 |  |  |             }else | 
 |  |  |             if(!!window['external']&&window['external']['showChartInfo']){ | 
 |  |  |                 window['external'].showChartInfo(""); | 
 |  |  |             }else{ | 
 |  |  |                 alert(objStr); | 
 |  |  |             } | 
 |  |  |         } | 
 |  |  |    ); | 
 |  |  |    //页面刷新 | 
 |  |  |  | 
 |  |  | })(jQuery); |