From 6b72d58686e543bc7fda3fe12d65c81765d37f86 Mon Sep 17 00:00:00 2001 From: cjj <Administrator@192.168.10.9> Date: 星期五, 19 十月 2018 11:09:03 +0800 Subject: [PATCH] "-" --- gx_tieta/WebRoot/control.jsp | 87 ++++++++++++++++++++++++++++++++----------- 1 files changed, 65 insertions(+), 22 deletions(-) diff --git a/gx_tieta/WebRoot/control.jsp b/gx_tieta/WebRoot/control.jsp index e792f0f..62da258 100644 --- a/gx_tieta/WebRoot/control.jsp +++ b/gx_tieta/WebRoot/control.jsp @@ -127,11 +127,6 @@ <table> <tr> <td id="ele_content"> - <!-- 鏈烘埧鏁扮數姹犵粍鏁� --> - <div id="mach_num"> - <s:text name="Room_num"></s:text>:<span id="room_num"></span>; <s:text name="Batt_group_num"></s:text>:<span id="batt_group_num"></span> - <div style="float: right; margin-right: 5px"><i class="fa"></i></div> - </div> <!--鐢垫睜缁勮彍鍗曟爮--> <div id="lside"> @@ -981,8 +976,6 @@ var winHt = $(window).height(); var bodyHt = $('body').height(); var batt_listen = $('#ele_content .batt-listen').height(); - //console.info('*****'); - //console.info(batt_listen); var shiftHt = winHt - bodyHt; var graph = $('.graph').height(); var lSide = $('#lside').height(); @@ -1020,29 +1013,32 @@ var unit = ""; if(lname == 'Voltage'){ unit ="V"; - max = batt.MonVolStd*1.25; + /* max = batt.MonVolStd*1.25; var tempmax = Math.max.apply( Math, array); if(tempmax > max){ max = tempmax*1.25; - } + } */ + max = Math.max.apply( Math, array)*1.1; max = max.toFixed(3); }else if(lname == 'Resistance'){ unit = "m惟"; - max = (batt.MonResStd*1.25); + /* max = (batt.MonResStd*1.25); max = 10; var tempmax = Math.max.apply( Math, array)*1.25; if(tempmax<max){ max = tempmax; - } + } */ + max = Math.max.apply( Math, array)*1.1; max = (max).toFixed(3); }else if(lname == 'Temperature'){ unit = "鈩�"; - max = (Math.max.apply( Math, array)*1.25).toFixed(3); + max = (Math.max.apply( Math, array)*1.5).toFixed(3); }else if(lname == 'Conductance'){ - max = (batt.MonSerStd*1.25).toFixed(3); + //max = (batt.MonSerStd*1.25).toFixed(3); + max = (Math.max.apply( Math, array)*1.1).toFixed(3); }else if(lname == 'MonJHCurr') { unit = "mA"; - max = (Math.max.apply( Math, array)*1.25).toFixed(3); + max = (Math.max.apply( Math, array)*1.1).toFixed(3); } //console.info("max:"+max+" min:"+min); if(lname=='Resistance' || lname=='Temperature'){ @@ -1676,17 +1672,20 @@ var array = getArray(lname); var batt = getBatt(); var min = (Math.min.apply( Math, array)*0.9).toFixed(3); - var max = 0 ; + var max = (Math.max.apply( Math, array)*1.1).toFixed(3); //console.info(batt); if(lname == 'Voltage'){ - max = (batt.MonVolStd*1.25).toFixed(3); + //max = (batt.MonVolStd*1.25).toFixed(3); + max = (Math.max.apply( Math, array)*1.1).toFixed(3); }else if(lname == 'Resistance'){ //max = (batt.MonResStd*1.25).toFixed(3); - max =10; + //max =10; + max = (Math.max.apply( Math, array)*1.1).toFixed(3); }else if(lname == 'Temperature'){ - max = (Math.max.apply( Math, array)*1.25).toFixed(3); + max = (Math.max.apply( Math, array)*1.5).toFixed(3); }else if(lname == 'Conductance'){ - max = (batt.MonSerStd*1.25).toFixed(3); + //max = (batt.MonSerStd*1.25).toFixed(3); + max = (Math.max.apply( Math, array)*1.1).toFixed(3); } //console.info("max:"+max+" min:"+min); if(lname=='Resistance' || lname=='Temperature'){ @@ -2010,16 +2009,23 @@ //鏍规嵁褰撳墠閫変腑鐨勭數姹犵粍id鑾峰彇褰撳墠鐢垫睜缁勭殑淇℃伅 function getBatt(){ - if(battinlist!=undefined && BattGroupId!=undefined){ + /* if(battinlist!=undefined && BattGroupId!=undefined){ for(var i=0;i<battinlist.length;i++){ for(var k=0;k<battinlist[i].length;k++){ if(BattGroupId==battinlist[i][k].BattGroupId){ + console.info(battinlist); return battinlist[i][k]; } } } + } */ + var activeFile = $('.whyc-sider-menu .sider-menu-file.active'); + if(activeFile.length == 1) { + return activeFile.data('attr'); + }else { + return undefined; } - return undefined; + } //灏嗘寚瀹氬垪涓殑涓巚alue鐩哥瓑鐨勫�肩殑鍗曞厓鏍煎彉涓虹孩鑹� @@ -3944,6 +3950,8 @@ var third = GLOBAL.pages.siderbar.third; // 涓夌骇瀵艰埅 var fourth = GLOBAL.pages.siderbar.fourth; // 鍥涚骇瀵艰埅 var treeView = new TreeView($('#lside')); + $('#lside').width($('#ele_content').width()); + treeView.setContainer(); // 璁剧疆瀹瑰櫒鍙嫋鍔� $('#ele_content').resizable({ handles: 'e', @@ -3970,15 +3978,50 @@ third(treeView, $(this).parent(), city); }); + battinlist = []; // 鏈烘埧->鐢垫睜缁� treeView.ele.on('click', '.home', function() { var home = $(this).data('attr'); var tmp = { + StationName1: home.StationName1, + StationName2: home.StationName2, + StationName: home.StationName, StationId: home.StationId }; - console.info(tmp); fourth(treeView, $(this).parent(), tmp); }); + + // 鐢垫睜缁� + treeView.ele.on('click', '.eleGroup', function() { + var eleGroup = $(this).data('attr'); + // 鏍规嵁BattGroupId鏌ヨ鏁版嵁 + if(BattGroupId != eleGroup.BattGroupId) { + BattGroupId = eleGroup.BattGroupId; + // 瀵笲TS9611鍋氱壒娈婄殑澶勭悊 + var batt = getBatt(); + //console.info(batt); + $('#eleCircleBtn').removeClass('hide'); + if(regEquipType(batt.FBSDeviceId, globalPattern.BTSSreen)) { + var isAct = $('#eleCircleBtn').hasClass('action'); + if(isAct) { + lname = 'Voltage'; + $('#'+lname).addClass('action'); + } + + $('#eleCircleBtn').removeClass('action').addClass('hide'); + $('.ele-circle').hide(); + $('.graph').show(); + myChart.resize(); + } + mygraph.ischange = 1; //閲嶆柊缁樺埗鎷撴墤鍥� + + getBattStr(); + searchBattAlarmParam(); //鏌ヨ鐢垫睜鍛婅鍙傛暟 + clearInterval(time); + showtable(); + time=window.setInterval("showtable()",4000); + } + }); }); </script> <script type="text/javascript" src="js/Title.js"></script> -- Gitblit v1.9.1