日志openvpn页面提交;公共类修改;日志公共字段,openvpn配置文件国际化

This commit is contained in:
zhanghongqing
2018-06-12 16:57:41 +08:00
parent 21a6b1b93a
commit b6bfcdda1f
6 changed files with 371 additions and 5 deletions

View File

@@ -0,0 +1,235 @@
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/include/taglib.jsp"%>
<html>
<head>
<script type="text/javascript">
$(document).ready(function(){
//搜索框提示语初始化
if("${log.clientIp}"){
$("#intype").val("${log.clientIp}");
}else if("${log.serverIp}"){
$("#intype").val("${log.serverIp}");
}else if("${log.cljIp}"){
$("#intype").val("${log.cljIp}");
}else if("${log.entranceId}"){
$("#intype").val("${log.entranceId}");
} else{
$("#intype").attr("placeholder","<spring:message code='input'/>"+$("#seltype").find("option:selected").text());
}
$("#seltype").change(function(){
$("#intype").attr("placeholder","<spring:message code='input'/>"+$(this).find("option:selected").text());
});
//筛选功能
filterActionInit();
//reset
$("#resetBtn").on("click",function(){
$("select.selectpicker").each(function(){
$(this).selectpicker('val',$(this).find('option:first').val());
$(this).find("option").attr("selected",false);
$(this).find("option:first").attr("selected",true);
});
$(".Wdate").attr("value",'');
$("#intype").attr("placeholder","<spring:message code='input'/>"+$("#seltype").find("option:selected").text());
$("#searchForm")[0].reset();
});
});
//查询
function page(n,s){
$("#intype").attr("name",$("#seltype").val());
$("#pageNo").val(n);
$("#pageSize").val(s);
$("#searchForm").attr("action","${ctx}/log/ntc/ntcOpenvpnLogs");
$("#searchForm").submit();
return false;
}
</script>
</head>
<body>
<div class="page-content">
<h3 class="page-title">
OpenVPN
<small><spring:message code="date_list"/></small>
</h3>
<h5 class="page-header"></h5>
<div class="row">
<div class="col-md-12">
<div class="portlet">
<div class="portlet-body">
<div class="row" >
<form:form id="searchForm" modelAttribute="log" action="${ctx}/log/ntc/ntcOpenvpnLogs" method="post" class="form-search">
<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
<!-- 筛选按钮展开状态-->
<input id="isFilterAction" name="isFilterAction" type="hidden" value="${log.isFilterAction }"/>
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
<!-- 搜索内容与操作按钮栏 -->
<div class="col-md-12">
<div class="pull-left">
<div class="input-group">
<div class="input-group-btn">
<c:set var="select"><spring:message code='select'/></c:set>
<form:select path="protocol" class="selectpicker select2 input-small" data-live-search="true" data-live-search-placeholder="search">
<form:option value=""><spring:message code="protocol_type"/></form:option>
<c:forEach items="${fns:getDictList('LOG_PROTOCOL')}" var="dict">
<form:option value="${dict.itemCode}" ><spring:message code="${dict.itemValue}"/></form:option>
</c:forEach>
</form:select>
</div></div>
</div>
<div class="pull-left">
<div class="input-group">
<div class="input-group-btn">
<form:select path="direction" class="selectpicker select2 input-small">
<form:option value=""><spring:message code="direct"/></form:option>
<c:forEach items="${fns:getDictList('DIRECTION')}" var="dict">
<form:option value="${dict.itemCode}"><spring:message code="${dict.itemValue}"/></form:option>
</c:forEach>
</form:select>
</div>
</div>
</div>
<div class="pull-left">
<div class="input-group">
<div class="input-group-btn">
<form:select path="seltype" class="selectpicker select2 input-small" >
<form:option value="clientIp"><spring:message code="clientip"></spring:message></form:option>
<form:option value="serverIp"><spring:message code="serverip"></spring:message></form:option>
<form:option value="cljIp"><spring:message code="clj_ip"></spring:message></form:option>
<form:option value="entranceId"><spring:message code="entrance_id"></spring:message></form:option>
</form:select>
</div>
<input id="intype" class="form-control input-medium" type="text" value="">
</div>
</div>
<div class="pull-left">
<button type="button" class="btn blue" onClick="page()"> <i class="fa fa-search"></i> <spring:message code="search"/> </button>
<button type="button" class="btn btn-default" id="resetBtn"> <i class="fa fa-refresh"></i> <spring:message code="reset"/> </button>
<button type="button" class="btn btn-default" id="filter-btn"> <spring:message code="filter"></spring:message> <i class="fa fa-angle-double-down"></i></button>
</div>
<div class="pull-right">
<a class="btn btn-icon-only btn-default setfields tooltips"
data-container="body" data-placement="top" data-original-title=<spring:message code="custom_columns"/> href="javascript:;">
<i class="icon-wrench"></i>
</a>
</div>
</div>
<!-- /搜索内容与操作按钮栏-->
<!-- 筛选搜索内容栏默认隐藏-->
<div class="col-md-12 filter-action-select-panle hide" >
<div class="row">
<div class="col-md-4">
<div class="form-group">
<label class="form-label"><spring:message code="begin_date"/></label>
<input name="searchFoundStartTime" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
value="<fmt:formatDate value="${log.searchFoundStartTime}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
</div>
</div>
<div class="col-md-4">
<div class="form-group">
<label><spring:message code="end_date"/></label>
<input name="searchFoundEndTime" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
value="<fmt:formatDate value="${log.searchFoundEndTime}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
</div>
</div>
</div>
</div>
<!-- /筛选搜索内容栏 结束-->
</form:form>
</div>
<div class="table-responsive">
<sys:message content="${message}"/>
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
<thead>
<tr>
<th><spring:message code='cfg_id'/></th>
<th class="sort-column r.foundTime"><spring:message code='found_time'/></th>
<th class="sort-column r.recvTime"><spring:message code='recv_time'/></th>
<th><spring:message code='protocol_type'/></th>
<th><spring:message code='addr_type'/></th>
<th><spring:message code='serverip'/></th>
<th><spring:message code='clientip'/></th>
<th><spring:message code='serverport'/></th>
<th><spring:message code='clientport'/></th>
<th><spring:message code='entrance_id'/></th>
<th><spring:message code='deviceid'/></th>
<th><spring:message code='direct'/></th>
<th><spring:message code='stream_type'/></th>
<th><spring:message code='clj_ip'/></th>
<th><spring:message code='nest_addr_list'/></th>
<th><spring:message code='user_region'/></th>
<th><spring:message code='version'/></th>
<th><spring:message code='encrypt_mode'/></th>
<th><spring:message code='hmac'/></th>
<th><spring:message code='tunnel_type'/></th>
</tr>
</thead>
<tbody>
<c:forEach items="${page.list}" var="log" varStatus="status" step="1">
<tr>
<td>${log.cfgId}</td>
<td>${log.foundTime}</td>
<td>${log.recvTime}</td>
<td>
<c:forEach items="${fns:getDictList('LOG_PROTOCOL')}" var="dic">
<c:if test="${log.protocol==dic.itemCode}"><spring:message code="${dic.itemValue }"/></c:if>
</c:forEach>
</td>
<td>
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="dic">
<c:if test="${log.addrType==dic.itemCode}"><spring:message code="${dic.itemValue }"/></c:if>
</c:forEach>
</td>
<td>${log.serverIp}</td>
<td>${log.clientIp}</td>
<td>${log.serverPort}</td>
<td>${log.clientPort}</td>
<td>${log.entranceId}</td>
<td>${log.deviceId}</td>
<td>
<c:forEach items="${fns:getDictList('LOG_DIRECTION')}" var="dic">
<c:if test="${log.direction==dic.itemCode}"><spring:message code="${dic.itemValue }"/></c:if>
</c:forEach>
</td>
<td>
<c:forEach items="${fns:getDictList('LOG_STREAM_TYPE')}" var="dic">
<c:if test="${log.streamType==dic.itemCode}"><spring:message code="${dic.itemValue }"/></c:if>
</c:forEach>
</td>
<td>${log.cljIp}</td>
<td>${log.nestAddrList}</td>
<td>${log.userRegion}</td>
<td>${log.version}</td>
<td>${log.encryptMode}</td>
<td>${log.hmac}</td>
<td>
<c:if test="${log.tunnelType==1}">TCP</c:if>
<c:if test="${log.tunnelType==2}">UDP"</c:if>
</td>
</tr>
</c:forEach>
</tbody>
</table>
<div class="page">${page}</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>