This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
k18-ntcs-web-ntc/src/main/webapp/WEB-INF/views/specific/specificServiceHostCfgList.jsp

379 lines
17 KiB
Plaintext
Raw Normal View History

2018-03-17 17:09:19 +08:00
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/include/taglib.jsp"%>
<html>
<head>
<title><spring:message code="agreement_ip_configuration" /></title>
2018-03-17 17:09:19 +08:00
<script>
$(document).ready(function() {
//筛选功能初始化
filterActionInit();
$("#isAudit").change(function(){
page();
});
$("#direction").change(function(){
page();
});
$("#protocol").change(function(){
page();
});
$("#ipType").change(function(){
page();
});
$("#ipType").change(function(){
page();
});
2018-03-17 17:09:19 +08:00
//全选及取消
$("#checkAll").change(function(){
if($("#checkAll").prop("checked")){
$("input.i-checks").prop("checked",true);
}else{
$("input.i-checks").prop("checked",false);
}
});
});
function resetx(){
$(':input','#searchForm')
.not(':button,:submit,:reset,:hidden')
.val('')
.removeAttr('checked')
.removeAttr('selected');
$("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);
});
$("#specServiceId").attr("value","");
$("#srcIp").attr("value","");
$("#dstIp").attr("value","");
}
//编辑
function edit(){
var mulitId="";
jQuery("#contentTable").find(":checkbox:checked[name='check']").each(function(){
if(jQuery(this).val()!=""){
mulitId+=jQuery(this).val()+",";
}
});
if(mulitId!=""){
confirmx('您确认要执行该操作?', '${ctx}/specific/specificServiceHostCfg/form?hostId='+mulitId.split(",", 1)[0]);
}else{
alert("至少选择一条数据记录");
}
2018-03-17 17:09:19 +08:00
}
//删除
function delAll(){
var mulitId="";
jQuery("#contentTable").find(":checkbox:checked[name='check']").each(function(){
if(jQuery(this).val()!=""){
mulitId+=jQuery(this).val()+",";
}
});
if(mulitId!=""){
confirmx('您确认要执行该操作?', '${ctx}/specific/specificServiceHostCfg/delete?mulitId='+mulitId);
}else{
alert("至少选择一条数据记录");
}
}
//查询
function page(n,s){
$("#pageNo").val(n);
$("#pageSize").val(s);
$("#searchForm").attr("action","${ctx}/specific/specificServiceHostCfg/list");
$("#searchForm").submit();
return false;
}
</script>
</head>
<body>
<div class="page-content">
<div class="theme-panel hidden-xs hidden-sm">
<button type="button" class="btn btn-primary"
onClick="javascript:window.location='${ctx}/specific/specificServiceHostCfg/form'">
<i class="fa fa-plus"></i>
<spring:message code="add"/></button>
</div>
<h3 class="page-title">
<spring:message code="agreement_ip_configuration" />
2018-03-17 17:09:19 +08:00
<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="specificServiceHostCfg" action="${ctx}/specific/specificServiceHostCfg/list" 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="${specificServiceHostCfg.isFilterAction }"/>
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
2018-03-17 17:09:19 +08:00
<!-- 搜索内容与操作按钮栏 -->
<div class="col-md-12">
<%-- <div class="pull-left">
2018-03-17 17:09:19 +08:00
<form:select path="isAudit" class="selectpicker select2 input-small" >
<form:option value=""><spring:message code="all_states"/></form:option>
<c:forEach items="${fns:getDictList('SPEC_AUDIT')}" var="dict">
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
</c:forEach>
</form:select>
</div> --%>
<div class="pull-left">
<c:set var="spec_service_id">请选择协议名称</c:set>
<form:select path="specServiceId" class="selectpicker select2 input-small" title="${spec_service_id}" data-live-search="true" data-live-search-placeholder="search" onchange="page()">
<c:forEach items="${listSpecService}" var="specService" >
<form:option value="${specService.specServiceId}">${specService.specServiceName}</form:option>
2018-03-17 17:09:19 +08:00
</c:forEach>
</form:select>
</div>
<div class="pull-left" style="margin-right:0px;">
<form:select path="ipType" class="selectpicker select2 input-small" >
<form:option value="">-请选择ip类型-</form:option>
<c:forEach items="${fns:getDictList('SPEC_IP_TYPE')}" var="dict">
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
</c:forEach>
</form:select>
2018-03-17 17:09:19 +08:00
</div>
<div class="pull-left">
<form:input path="srcIp" placeholder="请输入源IP地址" class="form-control input-small"/>
2018-03-17 17:09:19 +08:00
</div>
<div class="pull-left">
<form:input path="dstIp" placeholder="请输入目的IP地址" class="form-control input-small"/>
2018-03-17 17:09:19 +08:00
</div>
<%-- <div class="pull-left">
<form:select path="direction" class="selectpicker select2 input-small">
2018-03-17 17:09:19 +08:00
<form:option value="">-请选择方向-</form:option>
<c:forEach items="${fns:getDictList('SPEC_DIRECTION')}" var="dict">
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
</c:forEach>
</form:select>
</div> --%>
2018-03-17 17:09:19 +08:00
<div class="pull-left" style="margin-right:0px;">
<form:select path="protocol" class="selectpicker select2 input-small" >
<form:option value="">-请选择协议-</form:option>
<c:forEach items="${fns:getDictList('SPEC_PROTOCOL')}" var="dict">
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
</c:forEach>
</form:select>
</div>
<%-- <div class="pull-left">
<button type="button" class="btn btn-default" onClick="resetx()"> <i class="fa fa-refresh"></i> <spring:message code="reset"/> </button>
2018-03-17 17:09:19 +08:00
<button class="btn btn-default btn-search" type="button" onclick="return page()"><i class="fa fa-search"></i></button>
</div> --%>
<%-- <div class="pull-left" >
<form:select path="protocol" class="selectpicker select2 input-small" >
<form:option value="">所有协议</form:option>
<c:forEach items="${fns:getDictList('SPEC_PROTOCOL')}" var="dict">
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
</c:forEach>
</form:select>
</div>
<div class="pull-left">
<form:select path="direction" class="selectpicker select2 input-small" >
<form:option value="">所有方向</form:option>
<c:forEach items="${fns:getDictList('SPEC_DIRECTION')}" var="dict">
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
</c:forEach>
</form:select>
</div>
<div class="pull-left">
<div class="input-group">
<div class="input-group-btn">
<form:select path="" class="selectpicker select2 input-small" >
<form:option value="srcIp">协议ID</form:option>
<form:option value="srcIp"><spring:message code="client_ip"></spring:message></form:option>
<form:option value="dstIp"><spring:message code="server_ip"></spring:message></form:option>
</form:select>
</div>
<input id="intype" class="form-control input-medium" type="text" value="">
</div>
</div> --%>
2018-03-17 17:09:19 +08:00
<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" onClick="resetx()"> <i class="fa fa-refresh"></i> <spring:message code="reset"/> </button>
<button type="button" class="btn btn-default" id="filter-btn"> 筛选 <i class="fa fa-angle-double-down"></i></button>
2018-03-17 17:09:19 +08:00
</div>
<div class="pull-right">
<button type="button" class="btn btn-default" onclick="edit()">
<i class="fa fa-edit"></i> <spring:message code="edit"></spring:message></button>
<button type="button" class="btn btn-default" onclick="delAll()">
<i class="fa fa-trash"></i> 删除</button>
<%-- <div class="btn-group" >
2018-03-17 17:09:19 +08:00
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
<i class="fa fa-wrench"></i> <spring:message code="examine"></spring:message>
<i class="fa fa-angle-down"></i>
</button>
<ul class="dropdown-menu pull-right">
<li><sys:delRow url="" id="contentTable" label="approved"></sys:delRow></li>
<li><sys:delRow url="" id="contentTable" label="unapproved"></sys:delRow></li>
<li><sys:delRow url="" id="contentTable" label="cancelPass"></sys:delRow></li>
2018-03-17 17:09:19 +08:00
</ul>
</div> --%>
2018-03-17 17:09:19 +08:00
<a class="btn btn-icon-only btn-default setfields tooltips"
data-container="body" data-placement="top" data-original-title="自定义列字段" 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-2">
<div class="form-group">
<label><spring:message code="config_time"/></label>
<input name="beginDate" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
value="<fmt:formatDate value='${specificServiceHostCfg.beginDate}' pattern='yyyy-MM-dd HH:mm:ss'/>" onClick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
</div>
2018-03-17 17:09:19 +08:00
</div>
<div class="col-md-2">
<div class="form-group">
<label>&nbsp;</label>
<input name="endDate" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
value="<fmt:formatDate value="${specificServiceHostCfg.endDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
2018-03-17 17:09:19 +08:00
</div>
</div>
<div class="col-md-2">
<div class="form-group">
<label><spring:message code="edit_time"/></label>
<input name="editBeginDate" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
2018-03-17 17:09:19 +08:00
value="<fmt:formatDate value="${specificServiceHostCfg.editBeginDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
2018-03-17 17:09:19 +08:00
</div>
</div>
<div class="col-md-2">
<div class="form-group">
<label>&nbsp;</label>
<input name="editEndDate" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
2018-03-17 17:09:19 +08:00
value="<fmt:formatDate value="${specificServiceHostCfg.editEndDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
2018-03-17 17:09:19 +08:00
</div>
</div>
<div class="col-md-2">
<div class="form-group">
<label><spring:message code="audit_time"/></label>
<input name="auditBeginDate" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
2018-03-17 17:09:19 +08:00
value="<fmt:formatDate value="${specificServiceHostCfg.auditBeginDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
2018-03-17 17:09:19 +08:00
</div>
</div>
<div class="col-md-2">
<div class="form-group">
<label>&nbsp;</label>
<input name="auditEndDate" type="text" readonly="readonly" maxlength="20" class="form-control Wdate"
2018-03-17 17:09:19 +08:00
value="<fmt:formatDate value="${specificServiceHostCfg.auditEndDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
2018-03-17 17:09:19 +08:00
</div>
</div>
</div>
2018-03-17 17:09:19 +08:00
</div>
<!-- /筛选搜索内容栏 结束-->
</form:form>
</div>
<div class="table-responsive">
2018-03-17 17:09:19 +08:00
<sys:message content="${message}"/>
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
2018-03-17 17:09:19 +08:00
<thead>
<tr>
<th><input type="checkbox" class="i-checks" id="checkAll"></th>
<th>协议名称</th>
2018-03-17 17:09:19 +08:00
<th>源IP地址</th>
<th>源地址掩码</th>
<th>源端口</th>
<th>源端口掩码</th>
<th>目的IP地址</th>
<th>目的地址掩码</th>
<th>目的端口</th>
<th>目的端口掩码</th>
<th>方向</th>
<th>协议</th>
<th>是否审核</th>
<th>创建人员</th>
<th class="sort-column create_time">配置时间</th>
2018-03-17 17:09:19 +08:00
<th>修改人员</th>
<th class="sort-column edit_time">修改时间</th>
<th isVisible="false">审核人员</th>
<th isVisible="false" class="sort-column audit_time">审核时间</th>
2018-03-17 17:09:19 +08:00
</tr>
</thead>
<tbody>
<c:forEach items="${page.list}" var="specificServiceHostCfg">
<tr>
<td><input type="checkbox" class="i-checks" name="check" id="${specificServiceHostCfg.hostId}" value="${specificServiceHostCfg.hostId}"></td>
<td>${fns:getBySpecServiceId(specificServiceHostCfg.specServiceId).specServiceName }</td>
<td title="${specificServiceHostCfg.srcIp}">${fns:abbr(specificServiceHostCfg.srcIp,15)}</td>
<td title="${specificServiceHostCfg.srcIpMask}">${fns:abbr(specificServiceHostCfg.srcIpMask,15) }</td>
<td>${specificServiceHostCfg.srcPort}</td>
<td>${specificServiceHostCfg.srcPortMask}</td>
<td title="${specificServiceHostCfg.dstIp}">${fns:abbr(specificServiceHostCfg.dstIp,15) }</td>
<td title="${specificServiceHostCfg.dstIpMask}">${fns:abbr(specificServiceHostCfg.dstIpMask,15) }</td>
2018-03-17 17:09:19 +08:00
<td>${specificServiceHostCfg.dstPort }</td>
<td>${specificServiceHostCfg.dstPortMask }</td>
<td>${fns:getDictLabel("SPEC_DIRECTION",specificServiceHostCfg.direction,"0")}</td>
<td>${fns:getDictLabel("SPEC_PROTOCOL",specificServiceHostCfg.protocol,"0")}</td>
<td>${fns:getDictLabel("SPEC_AUDIT",specificServiceHostCfg.isAudit,"0")}</td>
<td>${fns:getUserById(specificServiceHostCfg.creator.id).name}</td>
<td><fmt:formatDate value="${specificServiceHostCfg.createTime}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
<td>${fns:getUserById(specificServiceHostCfg.editor.id).name}</td>
<td><fmt:formatDate value="${specificServiceHostCfg.editTime}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
<td>${fns:getUserById(specificServiceHostCfg.auditor.id==null?0:specificServiceHostCfg.auditor.id).name}</td>
<td><fmt:formatDate value="${specificServiceHostCfg.auditTime}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
</tr>
</c:forEach>
</tbody>
</table>
<div class="page">${page}</div>
</div>
</div>
2018-03-17 17:09:19 +08:00
</div>
</div>
</div>
</div>
</body>
</html>