From 5d10d711bfb9e7d6fac329383c330e8e20d83256 Mon Sep 17 00:00:00 2001 From: zhanghongqing Date: Tue, 23 Oct 2018 11:06:41 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=81=E9=87=8F=E7=BB=9F=E8=AE=A1=E6=B4=BB?= =?UTF-8?q?=E8=B7=83=E7=AB=AF=E5=8F=A3=E6=94=B9=E4=B8=BA=E5=BD=93=E5=89=8D?= =?UTF-8?q?=E6=97=B6=E9=97=B4=E4=B8=8E=E4=B8=8A=E4=B8=AA=E6=97=B6=E9=97=B4?= =?UTF-8?q?=E5=AF=B9=E6=AF=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../views/dashboard/dashBoardIndex.jsp | 54 +++++++++++-------- 1 file changed, 31 insertions(+), 23 deletions(-) diff --git a/src/main/webapp/WEB-INF/views/dashboard/dashBoardIndex.jsp b/src/main/webapp/WEB-INF/views/dashboard/dashBoardIndex.jsp index 6fe53e9af..449cc5ff8 100644 --- a/src/main/webapp/WEB-INF/views/dashboard/dashBoardIndex.jsp +++ b/src/main/webapp/WEB-INF/views/dashboard/dashBoardIndex.jsp @@ -171,7 +171,7 @@ - + @@ -572,27 +572,34 @@ function portActiveList(){ $("#tbodyDataPort").prepend(tr); }, success:function (rs) { - $("#tbodyDataPort").html(""); - var n=rs.length; - var total=0; - if(rs!=null&&rs.length>0&&rs[0].error!=null){ - $("#tbodyDataPort").prepend(""); - }else{ - if(n>0){ - $(rs).each(function(i, itemObj) { - total+=itemObj.sum; - }); - $(rs).each(function(i, itemObj) { - var tr = ""; - tr += ""+itemObj.port+""; - tr += ""+itemObj.sum+""; - tr += ""+((itemObj.sum/total)*100).toFixed(1)+" %"; - $("#tbodyDataPort").prepend(tr); - }) + rs.reverse(); + $("#tbodyDataPort").html(""); + var n=rs.length; + if(rs!=null&&rs.length>0&&rs[0].error!=null){ + $("#tbodyDataPort").prepend(""); }else{ - $("#tbodyDataPort").prepend("No Data"); + if(n>0){ + + $(rs).each(function(i, itemObj) { + var count= itemObj.sum; + var preCount = itemObj.preSum; + var tr = ""; + tr += ""+n+""; + tr += ""+itemObj.port+""; + if(preCount"+""; + }else if(preCount>count){ + tr += ""+""+""; + }else{ + tr += ""+""+""; + } + n=n-1; + $("#tbodyDataPort").prepend(tr); + }) + }else{ + $("#tbodyDataPort").prepend("No Data"); + } } - } }, }); } @@ -787,7 +794,8 @@ function websiteList() { $("#tbodyData2").prepend(tr); }, - success:function (rs) { + success:function (rs) { + rs.reverse(); $("#tbodyData2").html(""); var n=rs.length; if(rs!=null&&rs.length>0&&rs[0].error!=null){ @@ -831,11 +839,11 @@ function webClick(websiteServiceId,obj){ dataType:"json", cache:false,async:true, success:function (rs) { - echart_6(rs.reverse()); + echart_6(rs); }, }); } -//点击http网站列表-显示域名图 +//网站主题 function topicAndDomainList(){ $.ajax({ url: '${ctx}/dashboard/topicAndDomainList',