用户统计修改默认设置时间,可以点击列表直接查询

This commit is contained in:
zhanghongqing
2018-11-09 15:10:40 +08:00
parent 98860034a3
commit 301fa50606
2 changed files with 47 additions and 9 deletions

View File

@@ -68,6 +68,12 @@ public class TrafficStatisticsReportController extends BaseController {
endTime=DateUtils.getDateTime(); endTime=DateUtils.getDateTime();
bean.setSearchFoundStartTime(statTime); bean.setSearchFoundStartTime(statTime);
bean.setSearchFoundEndTime(endTime); bean.setSearchFoundEndTime(endTime);
statTime=URLEncoder.encode(statTime, "UTF-8");
endTime=URLEncoder.encode(endTime, "UTF-8");
String paramUrl="&searchReportStartTime="+statTime+"&searchReportEndTime="+endTime;
destUrl=destUrl+paramUrl;
userUrl=userUrl+paramUrl;
ipUrl=ipUrl+paramUrl;
}else { }else {
statTime=URLEncoder.encode(statTime, "UTF-8"); statTime=URLEncoder.encode(statTime, "UTF-8");
endTime=URLEncoder.encode(endTime, "UTF-8"); endTime=URLEncoder.encode(endTime, "UTF-8");

View File

@@ -6,6 +6,11 @@
<script type="text/javascript" src="${pageContext.request.contextPath}/static/global/plugins/jquery-ui/jquery-ui.min.js"></script> <script type="text/javascript" src="${pageContext.request.contextPath}/static/global/plugins/jquery-ui/jquery-ui.min.js"></script>
<title><spring:message code="traffic_user_behavior"></spring:message></title> <title><spring:message code="traffic_user_behavior"></spring:message></title>
<style>
td:hover{
cursor: pointer;
}
</style>
<script> <script>
$(document).ready(function() { $(document).ready(function() {
@@ -120,9 +125,36 @@
if($(".httpResCfg").hasClass("hidden")){ if($(".httpResCfg").hasClass("hidden")){
$("#searchBusinessType").val(2); $("#searchBusinessType").val(2);
} }
$("#searchForm").attr("action","${ctx}/traffic/userBehavior");
$("#searchForm").submit(); $("#searchForm").submit();
return false; return false;
} }
function searchAccountForList(param){
if($(".httpReqCfg").hasClass("hidden")){
$("#searchBusinessType").val(3);
}
if($(".httpResCfg").hasClass("hidden")){
$("#searchBusinessType").val(2);
}
$("#account").val(param);
$("#searchForm").attr("action","${ctx}/traffic/userBehavior");
$("#searchForm").submit();
return false;
}
function searchNasIpForList(param){
if($(".httpReqCfg").hasClass("hidden")){
$("#searchBusinessType").val(3);
}
if($(".httpResCfg").hasClass("hidden")){
$("#searchBusinessType").val(2);
}
$("#nasIp").val(param);
$("#searchForm").attr("action","${ctx}/traffic/userBehavior");
$("#searchForm").submit();
return false;
}
</script> </script>
</head> </head>
<body> <body>
@@ -162,7 +194,7 @@
<thead> <thead>
<tr> <tr>
<th><spring:message code="ip"/></th> <th><spring:message code="ip"/></th>
<th><spring:message code="link_num"/></th> <th><spring:message code="visits"/></th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
@@ -260,7 +292,7 @@
<tr> <tr>
<th><spring:message code="ip"/></th> <th><spring:message code="ip"/></th>
<th><spring:message code="stat_time"/></th> <th><spring:message code="stat_time"/></th>
<th><spring:message code="link_num"/></th> <th><spring:message code="visits"/></th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
@@ -275,7 +307,7 @@
</tbody> </tbody>
</table> --%> </table> --%>
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap"> <table id="contentTable" class="table table-hover table-striped table-bordered table-condensed text-nowrap table-active">
<thead> <thead>
<tr> <tr>
<th><spring:message code="account"/></th> <th><spring:message code="account"/></th>
@@ -284,7 +316,7 @@
<tbody> <tbody>
<c:forEach items="${accountList}" var="data"> <c:forEach items="${accountList}" var="data">
<tr> <tr>
<td title="${data.account}">${data.account}</td> <td onClick="return searchAccountForList('${data.account}')"><span title="${data.account}">${data.account}</span></td>
</tr> </tr>
</c:forEach> </c:forEach>
@@ -322,7 +354,7 @@
<div class="process-row"> <div class="process-row">
<div class="process-time"> <div class="process-time">
<div class="time-con"> <div class="time-con">
<span class="year" title="<spring:message code="link_num"/>: <fmt:formatNumber type='number' value='${us.num}' minFractionDigits='0'/>">${us.reportTime}</span> <span class="year" title="<spring:message code="visits"/>: <fmt:formatNumber type='number' value='${us.num}' minFractionDigits='0'/>">${us.reportTime}</span>
</div> </div>
</div> </div>
<div class="process-noyear" title="${us.nasIp}"> <div class="process-noyear" title="${us.nasIp}">
@@ -362,7 +394,7 @@
<tr> <tr>
<th><spring:message code="account"/></th> <th><spring:message code="account"/></th>
<th><spring:message code="stat_time"/></th> <th><spring:message code="stat_time"/></th>
<th><spring:message code="link_num"/></th> <th><spring:message code="visits"/></th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
@@ -377,7 +409,7 @@
</tbody> </tbody>
</table> --%> </table> --%>
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap"> <table id="contentTable" class="table table-hover table-striped table-bordered table-condensed text-nowrap">
<thead> <thead>
<tr> <tr>
<th><spring:message code="ip"/></th> <th><spring:message code="ip"/></th>
@@ -387,7 +419,7 @@
<c:forEach items="${nasIpList}" var="data"> <c:forEach items="${nasIpList}" var="data">
<tr> <tr>
<td title="${data.nasIp}">${data.nasIp}</td> <td onClick="return searchNasIpForList('${data.nasIp}')"><spantitle="${data.nasIp}">${data.nasIp}</span></td>
</tr> </tr>
</c:forEach> </c:forEach>
@@ -426,7 +458,7 @@
<div class="process-row"> <div class="process-row">
<div class="process-time"> <div class="process-time">
<div class="time-con"> <div class="time-con">
<span class="year" title="<spring:message code="link_num"/>: <fmt:formatNumber type='number' value='${it.num}' minFractionDigits='0'/>">${it.reportTime} <span class="year" title="<spring:message code="visits"/>: <fmt:formatNumber type='number' value='${it.num}' minFractionDigits='0'/>">${it.reportTime}
</span> </span>
</div> </div>