(1)IP Pattern拆分为源IP Pattern,目的IP Pattern,Port Pattern
拆分为源端口Pattern,目的端口Pattern (2)show more修改,并移动刀ipRegion.js中 (3)IP复用未作修改 (4)删除部分废弃的导入模板以及废弃的导入方法
This commit is contained in:
@@ -10,7 +10,36 @@
|
||||
<div class="row ipInfo">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="protocol"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="protocol" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<option value="${protocolC.itemCode}" <c:if test="${_cfg.protocol==protocolC.itemCode || (_cfg.protocol==null && protocolC.itemCode==0)}">selected</c:if>><spring:message code="${protocolC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
<input type="hidden" name="protocolId" value="0">
|
||||
</div>
|
||||
<div for="protocol"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="direction"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="direction" class="selectpicker show-tick form-control required" >
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<option value="${directionC.itemCode}" <c:if test="${_cfg.direction==directionC.itemCode || (_cfg.direction==null && directionC.itemCode==0)}">selected</c:if>><spring:message code="${directionC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="direction"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_type"/></label>
|
||||
<div class="col-md-6">
|
||||
@@ -30,33 +59,67 @@
|
||||
<div for="ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="protocol"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="protocol" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<option value="${protocolC.itemCode}" <c:if test="${_cfg.protocol==protocolC.itemCode || (_cfg.protocol==null && protocolC.itemCode==0)}">selected</c:if>><spring:message code="${protocolC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
<input type="hidden" name="protocolId" value="0">
|
||||
</div>
|
||||
<div for="protocol"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div>
|
||||
<div class="row ipCol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_pattern"/></label>
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="ipPattern" class="selectpicker show-tick form-control required">
|
||||
<select name="srcIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.ipPattern==ipPatternC.itemCode || (_cfg.ipPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.srcIpPattern==ipPatternC.itemCode || (_cfg.srcIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipPattern"></div>
|
||||
<div for="srcIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="srcIpAddress" value="${_cfg.srcIpAddress}">
|
||||
</div>
|
||||
<div for="srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row hidden ipCol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="srcPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.srcPortPattern==portPatternC.itemCode || (_cfg.srcPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="srcPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="srcPort" value="${_cfg.srcPort}">
|
||||
</div>
|
||||
<div for="srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row hidden ipCol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="dest_ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="destIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.destIpPattern==ipPatternC.itemCode || (_cfg.destIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="destIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
@@ -69,25 +132,18 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<c:choose>
|
||||
<c:when test="${_cfg.cfgId==null}">
|
||||
<div class="row hidden port">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<div class="row port">
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<div class="row hidden ipCol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="port_pattern"/></label>
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="dest_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="portPattern" class="selectpicker show-tick form-control required">
|
||||
<select name="destPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.portPattern==portPatternC.itemCode || (_cfg.portPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.destPortPattern==portPatternC.itemCode || (_cfg.destPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="portPattern"></div>
|
||||
<div for="destPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
@@ -100,49 +156,8 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<c:choose>
|
||||
<c:when test="${_cfg.cfgId==null}">
|
||||
<div class="row hidden destPort">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<div class="row destPort">
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="direction"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="direction" class="selectpicker show-tick form-control required" >
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<option value="${directionC.itemCode}" <c:if test="${_cfg.direction==directionC.itemCode || (_cfg.direction==null && directionC.itemCode==0)}">selected</c:if>><spring:message code="${directionC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="direction"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<c:if test="${_cfg.cfgId==null}">
|
||||
<div class="row">
|
||||
<div class="row">
|
||||
<button type="button" class="btn btn-red-hollow center-block" onClick="more(this);" data-click-times="0"><spring:message code="show_more"/></button>
|
||||
</div>
|
||||
</c:if>
|
||||
<div class="row destPort">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<div class="col-md-6">
|
||||
<input type="hidden" name="srcIpAddress" value="${_cfg.srcIpAddress}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<div class="col-md-6">
|
||||
<input type="hidden" name="srcPort" value="${_cfg.srcPort}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
<script type="text/javascript">
|
||||
var defaultIpInfo;
|
||||
$(function(){
|
||||
$("input[name$='destPort']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='portPattern']").parents(".form-group").addClass("hidden");
|
||||
//$("input[name$='destPort']").parents(".form-group").addClass("hidden");
|
||||
//$("select[name$='portPattern']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='protocol']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='direction']").parents(".form-group").addClass("hidden");
|
||||
defaultIpInfo=$(".ipInfo").clone();
|
||||
@@ -93,7 +93,7 @@ var addContent = function(obj, contentClassName) {
|
||||
$("select[name$='ipType']").on("change",function(){
|
||||
switchIpInfo(this);
|
||||
});
|
||||
$("select[name$='ipPattern']").on("change",function(){
|
||||
$("select[name$='IpPattern']").on("change",function(){
|
||||
switchIpInfo(this);
|
||||
});
|
||||
}
|
||||
@@ -165,8 +165,10 @@ var reSort=function(obj,index){
|
||||
serviceType="${region.configServiceType}"
|
||||
ipPortShow="${region.configIpPortShow}"
|
||||
ipType="${region.configIpType}"
|
||||
ipPattern="${region.configIpPattern}"
|
||||
portPattern="${region.configPortPattern}"
|
||||
srcIpPattern="${fn:split(region.configIpPattern,';')[0]}"
|
||||
destIpPattern="${fn:split(region.configIpPattern,';')[1]}"
|
||||
srcPortPattern="${fn:split(region.configPortPattern,';')[0]}"
|
||||
destPortPattern="${fn:split(region.configPortPattern,';')[1]}"
|
||||
direction="${region.configDirection}"
|
||||
protocol="${region.configProtocol}"
|
||||
regionType="${region.regionType}"
|
||||
@@ -263,96 +265,6 @@ var reSort=function(obj,index){
|
||||
onClick="delContent(this,'ipInfo');" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_type"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="asnIpCfgs[0].ipType" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}"
|
||||
<c:if test="${_cfg.asnIpCfgs[0].ipType==ipTypeC.itemCode
|
||||
|| (_cfg.asnIpCfgs[0].ipType==null && ipTypeC.itemCode==4)}">
|
||||
selected
|
||||
</c:if>
|
||||
>
|
||||
<spring:message code="${ipTypeC.itemValue}"/>
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row ip">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="asnIpCfgs[0].ipPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.asnIpCfgs[0].ipPattern==ipPatternC.itemCode || (_cfg.asnIpCfgs[0].ipPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].ipPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="asnIpCfgs[0].srcIpAddress" value="${_cfg.asnIpCfgs[0].srcIpAddress}">
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row port">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="asnIpCfgs[0].portPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.asnIpCfgs[0].portPattern==portPatternC.itemCode || (_cfg.asnIpCfgs[0].portPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].portPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="asnIpCfgs[0].srcPort" value="${_cfg.asnIpCfgs[0].srcPort}">
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row destPort">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="asnIpCfgs[0].destIpAddress" value="${_cfg.asnIpCfgs[0].destIpAddress}">
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="asnIpCfgs[0].destPort" value="${_cfg.asnIpCfgs[0].destPort}">
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row protocol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
@@ -385,6 +297,125 @@ var reSort=function(obj,index){
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_type"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="asnIpCfgs[0].ipType" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}"
|
||||
<c:if test="${_cfg.asnIpCfgs[0].ipType==ipTypeC.itemCode
|
||||
|| (_cfg.asnIpCfgs[0].ipType==null && ipTypeC.itemCode==4)}">
|
||||
selected
|
||||
</c:if>
|
||||
>
|
||||
<spring:message code="${ipTypeC.itemValue}"/>
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="asnIpCfgs[0].srcIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.asnIpCfgs[0].srcIpPattern==ipPatternC.itemCode || (_cfg.asnIpCfgs[0].srcIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].srcIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="asnIpCfgs[0].srcIpAddress" value="${_cfg.asnIpCfgs[0].srcIpAddress}">
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="asnIpCfgs[0].srcPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.asnIpCfgs[0].srcPortPattern==portPatternC.itemCode || (_cfg.asnIpCfgs[0].srcPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].srcPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="asnIpCfgs[0].srcPort" value="${_cfg.asnIpCfgs[0].srcPort}">
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="asnIpCfgs[0].destIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.asnIpCfgs[0].destIpPattern==ipPatternC.itemCode || (_cfg.asnIpCfgs[0].destIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].destIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="asnIpCfgs[0].destIpAddress" value="${_cfg.asnIpCfgs[0].destIpAddress}">
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="dest_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="asnIpCfgs[0].destPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.asnIpCfgs[0].destPortPattern==portPatternC.itemCode || (_cfg.asnIpCfgs[0].destPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].destPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="asnIpCfgs[0].destPort" value="${_cfg.asnIpCfgs[0].destPort}">
|
||||
</div>
|
||||
<div for="asnIpCfgs[0].destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%-- <div class="row">
|
||||
<button type="button" class="btn btn-red-hollow center-block"
|
||||
onClick="more(this);" data-click-times="0">
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
<title><spring:message code="asn_ip_configuration"></spring:message></title>
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
$("input[name='destPort']").parents(".form-group").addClass("hidden");
|
||||
$("select[name='portPattern']").parents(".form-group").addClass("hidden");
|
||||
//$("input[name='destPort']").parents(".form-group").addClass("hidden");
|
||||
//$("select[name='portPattern']").parents(".form-group").addClass("hidden");
|
||||
$("select[name='protocol']").parents(".form-group").addClass("hidden");
|
||||
$("select[name='direction']").parents(".form-group").addClass("hidden");
|
||||
$("#cfgFrom").validate({
|
||||
@@ -115,8 +115,10 @@ $(function(){
|
||||
serviceType="${region.configServiceType}"
|
||||
ipPortShow="${region.configIpPortShow}"
|
||||
ipType="${region.configIpType}"
|
||||
ipPattern="${region.configIpPattern}"
|
||||
portPattern="${region.configPortPattern}"
|
||||
srcIpPattern="${fn:split(region.configIpPattern,';')[0]}"
|
||||
destIpPattern="${fn:split(region.configIpPattern,';')[1]}"
|
||||
srcPortPattern="${fn:split(region.configPortPattern,';')[0]}"
|
||||
destPortPattern="${fn:split(region.configPortPattern,';')[1]}"
|
||||
direction="${region.configDirection}"
|
||||
protocol="${region.configProtocol}"
|
||||
regionType="${region.regionType}"
|
||||
@@ -211,97 +213,7 @@ $(function(){
|
||||
<!-- desc and action -->
|
||||
<%-- <%@include file="/WEB-INF/include/form/complexIpInfo.jsp" %> --%>
|
||||
<div class="row ipInfo">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_type"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="ipType" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('WHITELIST_IPTYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}"
|
||||
<c:if test="${_cfg.ipType==ipTypeC.itemCode
|
||||
|| (_cfg.ipType==null && ipTypeC.itemCode==4)}">
|
||||
selected
|
||||
</c:if>
|
||||
>
|
||||
<spring:message code="${ipTypeC.itemValue}"/>
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="ipPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.ipPattern==ipPatternC.itemCode || (_cfg.ipPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="srcIpAddress" value="${_cfg.srcIpAddress}">
|
||||
</div>
|
||||
<div for="srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row port">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="portPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.portPattern==portPatternC.itemCode || (_cfg.portPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="portPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="srcPort" value="${_cfg.srcPort}">
|
||||
</div>
|
||||
<div for="srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row destPort">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="destIpAddress" value="${_cfg.destIpAddress}">
|
||||
</div>
|
||||
<div for="destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="destPort" value="${_cfg.destPort}">
|
||||
</div>
|
||||
<div for="destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row protocol">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
@@ -333,6 +245,124 @@ $(function(){
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_type"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="ipType" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('WHITELIST_IPTYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}"
|
||||
<c:if test="${_cfg.ipType==ipTypeC.itemCode
|
||||
|| (_cfg.ipType==null && ipTypeC.itemCode==4)}">
|
||||
selected
|
||||
</c:if>
|
||||
>
|
||||
<spring:message code="${ipTypeC.itemValue}"/>
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="srcIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.srcIpPattern==ipPatternC.itemCode || (_cfg.srcIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="srcIpAddress" value="${_cfg.srcIpAddress}">
|
||||
</div>
|
||||
<div for="srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="srcPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.srcPortPattern==portPatternC.itemCode || (_cfg.srcPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="srcPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="srcPort" value="${_cfg.srcPort}">
|
||||
</div>
|
||||
<div for="srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="dest_ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="destIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.destIpPattern==ipPatternC.itemCode || (_cfg.destIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="destIpAddress" value="${_cfg.destIpAddress}">
|
||||
</div>
|
||||
<div for="destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="dest_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="destPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.destPortPattern==portPatternC.itemCode || (_cfg.destPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="destportPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="destPort" value="${_cfg.destPort}">
|
||||
</div>
|
||||
<div for="destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<%-- <div class="row">
|
||||
<button type="button" class="btn btn-red-hollow center-block"
|
||||
onClick="more(this);" data-click-times="0">
|
||||
|
||||
@@ -338,7 +338,7 @@
|
||||
<%-- <td>${cfg.destPort }</td> --%>
|
||||
<td>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</td>
|
||||
<%-- <td>
|
||||
|
||||
@@ -59,8 +59,10 @@ $(function(){
|
||||
serviceType="${region.configServiceType}"
|
||||
ipPortShow="${region.configIpPortShow}"
|
||||
ipType="${region.configIpType}"
|
||||
ipPattern="${region.configIpPattern}"
|
||||
portPattern="${region.configPortPattern}"
|
||||
srcIpPattern="${fn:split(region.configIpPattern,';')[0]}"
|
||||
destIpPattern="${fn:split(region.configIpPattern,';')[1]}"
|
||||
srcPortPattern="${fn:split(region.configPortPattern,';')[0]}"
|
||||
destPortPattern="${fn:split(region.configPortPattern,';')[1]}"
|
||||
direction="${region.configDirection}"
|
||||
protocol="${region.configProtocol}"
|
||||
regionType="${region.regionType}"
|
||||
@@ -134,33 +136,18 @@ $(function(){
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_pattern"/></label>
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="ipPattern" class="selectpicker show-tick form-control required">
|
||||
<select name="srcIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.ipPattern==ipPatternC.itemCode || (_cfg.ipPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.srcIpPattern==ipPatternC.itemCode || (_cfg.srcIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipPattern"></div>
|
||||
<div for="srcIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="portPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.portPattern==portPatternC.itemCode || (_cfg.portPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="portPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
@@ -169,6 +156,21 @@ $(function(){
|
||||
<div for="srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="srcPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.srcPortPattern==portPatternC.itemCode || (_cfg.srcPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="srcPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_port"/></label>
|
||||
@@ -181,23 +183,51 @@ $(function(){
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="dest_ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="destIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.destIpPattern==ipPatternC.itemCode || (_cfg.destIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="destIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="destIpAddress" value="${_cfg.destIpAddress}">
|
||||
</div>
|
||||
<div for="destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="dest_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="destPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.destPortPattern==portPatternC.itemCode || (_cfg.destPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="destPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="destPort" value="${_cfg.destPort}">
|
||||
</div>
|
||||
<div for="destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
|
||||
@@ -177,9 +177,9 @@ var addContent = function(obj, contentClassName) {
|
||||
/* $("."+contentClassName+"0").find("input,select").each(function(){
|
||||
$(this).removeAttr("disabled");
|
||||
}); */
|
||||
$("select[name$='portPattern']").parents(".port").removeClass("hidden");
|
||||
$("input[name$='destIpAddress']").parents(".destPort").removeClass("hidden");
|
||||
$(".moreBtn").data("click-times",2);
|
||||
//$("select[name$='PortPattern']").parents(".port").removeClass("hidden");
|
||||
//$("input[name$='destIpAddress']").parents(".destPort").removeClass("hidden");
|
||||
//$(".moreBtn").data("click-times",2);
|
||||
$(obj).addClass("hidden");
|
||||
}
|
||||
|
||||
|
||||
@@ -49,6 +49,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -60,14 +82,14 @@
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -84,10 +106,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -97,38 +119,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -52,6 +52,28 @@
|
||||
<c:forEach items="${region.ipRangeList}" var="cfg">
|
||||
<c:if test="${region.regionValue eq cfg.cfgType }">
|
||||
<div id="${region.regionValue}_${regionStatus.index}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -63,14 +85,14 @@
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div>
|
||||
<%-- <div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -87,10 +109,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -100,38 +122,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> --%>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -31,6 +31,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -42,14 +64,14 @@
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -66,10 +88,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -79,38 +101,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -32,6 +32,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -47,10 +69,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -67,10 +89,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -84,34 +106,37 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -119,8 +119,10 @@ $(function(){
|
||||
serviceType="${region.configServiceType}"
|
||||
ipPortShow="${region.configIpPortShow}"
|
||||
ipType="${region.configIpType}"
|
||||
ipPattern="${region.configIpPattern}"
|
||||
portPattern="${region.configPortPattern}"
|
||||
srcIpPattern="${fn:split(region.configIpPattern,';')[0]}"
|
||||
destIpPattern="${fn:split(region.configIpPattern,';')[1]}"
|
||||
srcPortPattern="${fn:split(region.configPortPattern,';')[0]}"
|
||||
destPortPattern="${fn:split(region.configPortPattern,';')[1]}"
|
||||
direction="${region.configDirection}"
|
||||
protocol="${region.configProtocol}"
|
||||
regionType="${region.regionType}"
|
||||
|
||||
@@ -417,7 +417,7 @@
|
||||
</td>
|
||||
<td>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</td>
|
||||
<%-- <td>${cfg.srcIpAddress }</td>
|
||||
@@ -425,7 +425,7 @@
|
||||
<td title="${cfg.destIpAddress }">${fns:abbr(cfg.destIpAddress, 42)}</td>
|
||||
<td>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</td>
|
||||
<td>${cfg.destPort }</td>
|
||||
|
||||
@@ -64,8 +64,10 @@ $(function(){
|
||||
serviceType="${region.configServiceType}"
|
||||
ipPortShow="${region.configIpPortShow}"
|
||||
ipType="${region.configIpType}"
|
||||
ipPattern="${region.configIpPattern}"
|
||||
portPattern="${region.configPortPattern}"
|
||||
srcIpPattern="${fn:split(region.configIpPattern,';')[0]}"
|
||||
destIpPattern="${fn:split(region.configIpPattern,';')[1]}"
|
||||
srcPortPattern="${fn:split(region.configPortPattern,';')[0]}"
|
||||
destPortPattern="${fn:split(region.configPortPattern,';')[1]}"
|
||||
direction="${region.configDirection}"
|
||||
protocol="${region.configProtocol}"
|
||||
regionType="${region.regionType}"
|
||||
@@ -150,97 +152,7 @@ $(function(){
|
||||
<!-- dolog end-->
|
||||
<%-- <%@include file="/WEB-INF/include/form/complexIpInfo.jsp" %> --%>
|
||||
<div class="row ipInfo">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_type"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="ipType" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}"
|
||||
<c:if test="${_cfg.ipType==ipTypeC.itemCode
|
||||
|| (_cfg.ipType==null && ipTypeC.itemCode==4)}">
|
||||
selected
|
||||
</c:if>
|
||||
>
|
||||
<spring:message code="${ipTypeC.itemValue}"/>
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row ip">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="ipPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.ipPattern==ipPatternC.itemCode || (_cfg.ipPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="srcIpAddress" value="${_cfg.srcIpAddress}">
|
||||
</div>
|
||||
<div for="srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row port">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="portPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.portPattern==portPatternC.itemCode || (_cfg.portPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="portPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="srcPort" value="${_cfg.srcPort}">
|
||||
</div>
|
||||
<div for="srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row destPort">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="destIpAddress" value="${_cfg.destIpAddress}">
|
||||
</div>
|
||||
<div for="destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="destPort" value="${_cfg.destPort}">
|
||||
</div>
|
||||
<div for="destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row protocol">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
@@ -272,6 +184,125 @@ $(function(){
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_type"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="ipType" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}"
|
||||
<c:if test="${_cfg.ipType==ipTypeC.itemCode
|
||||
|| (_cfg.ipType==null && ipTypeC.itemCode==4)}">
|
||||
selected
|
||||
</c:if>
|
||||
>
|
||||
<spring:message code="${ipTypeC.itemValue}"/>
|
||||
</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="srcIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.srcIpPattern==ipPatternC.itemCode || (_cfg.srcIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="srcIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="srcIpAddress" value="${_cfg.srcIpAddress}">
|
||||
</div>
|
||||
<div for="srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="src_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="srcPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.srcPortPattern==portPatternC.itemCode || (_cfg.srcPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="srcPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="client_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="srcPort" value="${_cfg.srcPort}">
|
||||
</div>
|
||||
<div for="srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="destIpPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${_cfg.destIpPattern==ipPatternC.itemCode || (_cfg.destIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="destIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="ip"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text" name="destIpAddress" value="${_cfg.destIpAddress}">
|
||||
</div>
|
||||
<div for="destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="dest_port_pattern"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="destPortPattern" class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${_cfg.destPortPattern==portPatternC.itemCode || (_cfg.destPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="destPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="server_port"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text" name="destPort" value="${_cfg.destPort}">
|
||||
</div>
|
||||
<div for="destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%-- <div class="row">
|
||||
<button type="button" class="btn btn-red-hollow center-block"
|
||||
onClick="more(this);" data-click-times="0">
|
||||
|
||||
@@ -387,7 +387,7 @@
|
||||
<%-- <td>${cfg.destPort }</td> --%>
|
||||
<td>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</td>
|
||||
<%-- <td>
|
||||
|
||||
@@ -49,6 +49,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -60,14 +82,14 @@
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -84,10 +106,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -97,38 +119,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -31,6 +31,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -46,10 +68,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -66,10 +88,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -79,38 +101,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -34,63 +34,14 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_type'/>:</label>
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<c:if test="${cfg.ipType==ipTypeC.itemCode}"><spring:message code="${ipTypeC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.srcIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
@@ -105,10 +56,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label><spring:message code='ip_type'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<c:if test="${cfg.ipType==ipTypeC.itemCode}"><spring:message code="${ipTypeC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -124,6 +75,80 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.srcIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
</c:forEach>
|
||||
|
||||
@@ -31,6 +31,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -46,10 +68,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -66,10 +88,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -79,38 +101,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -16,8 +16,10 @@
|
||||
serviceType="${region.configServiceType}"
|
||||
ipPortShow="${region.configIpPortShow}"
|
||||
ipType="${region.configIpType}"
|
||||
ipPattern="${region.configIpPattern}"
|
||||
portPattern="${region.configPortPattern}"
|
||||
srcIpPattern="${fn:split(region.configIpPattern,';')[0]}"
|
||||
destIpPattern="${fn:split(region.configIpPattern,';')[1]}"
|
||||
srcPortPattern="${fn:split(region.configPortPattern,';')[0]}"
|
||||
destPortPattern="${fn:split(region.configPortPattern,';')[1]}"
|
||||
direction="${region.configDirection}"
|
||||
protocol="${region.configProtocol}"
|
||||
regionType="${region.regionType}"
|
||||
@@ -51,21 +53,6 @@
|
||||
</div>
|
||||
</c:if>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="ip_type" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.ipType"
|
||||
class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}" <c:if test="${ipPort.ipType==ipTypeC.itemCode || (ipPort.ipType==null && ipTypeC.itemCode==4)}">selected</c:if>><spring:message code="${ipTypeC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="${cfgName}.ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
@@ -81,92 +68,6 @@
|
||||
<div for="${cfgName}.protocol"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row ip">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="ip_pattern" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.ipPattern"
|
||||
class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${ipPort.ipPattern==ipPatternC.itemCode || (ipPort.ipPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="${cfgName}.ipPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="client_ip" /></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text"
|
||||
name="${cfgName}.srcIpAddress"
|
||||
value="${ipPort.srcIpAddress}">
|
||||
</div>
|
||||
<div for="${cfgName}.srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row hidden port">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="port_pattern" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.portPattern"
|
||||
class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${ipPort.portPattern==portPatternC.itemCode || (ipPort.portPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="${cfgName}.portPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="client_port" /></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text"
|
||||
name="${cfgName}.srcPort"
|
||||
value="${ipPort.srcPort}">
|
||||
</div>
|
||||
<div for="${cfgName}.srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row hidden destPort">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="server_ip" /></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text"
|
||||
name="${cfgName}.destIpAddress"
|
||||
value="${ipPort.destIpAddress}">
|
||||
</div>
|
||||
<div for="${cfgName}.destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="server_port" /></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text"
|
||||
name="${cfgName}.destPort"
|
||||
value="${ipPort.destPort}">
|
||||
</div>
|
||||
<div for="${cfgName}.destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row hidden protocol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
@@ -183,6 +84,140 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="ip_type" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.ipType"
|
||||
class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}" <c:if test="${ipPort.ipType==ipTypeC.itemCode || (ipPort.ipType==null && ipTypeC.itemCode==4)}">selected</c:if>><spring:message code="${ipTypeC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="${cfgName}.ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row ipCol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="src_ip_pattern" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.srcIpPattern"
|
||||
class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${ipPort.srcIpPattern==ipPatternC.itemCode || (ipPort.srcIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="${cfgName}.srcIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="client_ip" /></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text"
|
||||
name="${cfgName}.srcIpAddress"
|
||||
value="${ipPort.srcIpAddress}">
|
||||
</div>
|
||||
<div for="${cfgName}.srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row hidden ipCol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="src_port_pattern" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.srcPortPattern"
|
||||
class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${ipPort.srcPortPattern==portPatternC.itemCode || (ipPort.srcPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="${cfgName}.srcPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="client_port" /></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text"
|
||||
name="${cfgName}.srcPort"
|
||||
value="${ipPort.srcPort}">
|
||||
</div>
|
||||
<div for="${cfgName}.srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row hidden ipCol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="dest_ip_pattern" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.destIpPattern"
|
||||
class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<option value="${ipPatternC.itemCode}" <c:if test="${ipPort.destIpPattern==ipPatternC.itemCode || (ipPort.destIpPattern==null && ipPatternC.itemCode==3)}">selected</c:if>><spring:message code="${ipPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="${cfgName}.destIpPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="server_ip" /></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required ipCheck" type="text"
|
||||
name="${cfgName}.destIpAddress"
|
||||
value="${ipPort.destIpAddress}">
|
||||
</div>
|
||||
<div for="${cfgName}.destIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="row hidden ipCol">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="dest_port_pattern" /></label>
|
||||
<div class="col-md-6">
|
||||
<select name="${cfgName}.destPortPattern"
|
||||
class="selectpicker show-tick form-control required">
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<option value="${portPatternC.itemCode}" <c:if test="${ipPort.destPortPattern==portPatternC.itemCode || (ipPort.destPortPattern==null && portPatternC.itemCode==1)}">selected</c:if>><spring:message code="${portPatternC.itemValue}"/></option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="${cfgName}.destPortPattern"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font>
|
||||
<spring:message code="server_port" /></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required portCheck" type="text"
|
||||
name="${cfgName}.destPort"
|
||||
value="${ipPort.destPort}">
|
||||
</div>
|
||||
<div for="${cfgName}.destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<button type="button" class="btn btn-red-hollow center-block moreBtn"
|
||||
|
||||
@@ -453,8 +453,10 @@ var showHideIPSECProtocol=function(obj){
|
||||
serviceType="${region.configServiceType}"
|
||||
ipPortShow="${region.configIpPortShow}"
|
||||
ipType="${region.configIpType}"
|
||||
ipPattern="${region.configIpPattern}"
|
||||
portPattern="${region.configPortPattern}"
|
||||
srcIpPattern="${fn:split(region.configIpPattern,';')[0]}"
|
||||
destIpPattern="${fn:split(region.configIpPattern,';')[1]}"
|
||||
srcPortPattern="${fn:split(region.configPortPattern,';')[0]}"
|
||||
destPortPattern="${fn:split(region.configPortPattern,';')[1]}"
|
||||
direction="${region.configDirection}"
|
||||
protocol="${region.configProtocol}"
|
||||
regionType="${region.regionType}"
|
||||
@@ -538,12 +540,12 @@ var showHideIPSECProtocol=function(obj){
|
||||
</c:forEach>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6 doBlackList">
|
||||
<div class="col-md-6 doBalckList">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><spring:message code="do_blacklist" /></label>
|
||||
<c:forEach items="${fns:getDictList('DO_BLACKLIST') }" var="dict">
|
||||
<c:choose>
|
||||
<c:when test="${not empty _cfg.doBlackList and dict.itemCode eq _cfg.doBlackList}">
|
||||
<c:when test="${dict.itemCode eq _cfg.doBlackList and not empty_cfg.doBalckList}">
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="doBlackList" checked value="${dict.itemCode}" ><spring:message code="${dict.itemValue}"/>
|
||||
</label>
|
||||
|
||||
@@ -34,6 +34,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -45,14 +67,14 @@
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -69,10 +91,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -82,38 +104,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -32,6 +32,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -47,10 +69,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -67,10 +89,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -84,34 +106,37 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -31,6 +31,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -46,10 +68,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -66,10 +88,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -79,38 +101,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -72,88 +72,113 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<div id="ipInfo${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_type'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<c:if test="${cfg.ipType==ipTypeC.itemCode}"><spring:message code="${ipTypeC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.srcIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_type'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<c:if test="${cfg.ipType==ipTypeC.itemCode}"><spring:message code="${ipTypeC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.srcIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:forEach>
|
||||
<c:forEach items="${_cfg.httpUrlList}" var="cfg">
|
||||
|
||||
@@ -31,6 +31,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -42,14 +64,14 @@
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -66,10 +88,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -79,38 +101,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -72,88 +72,113 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<div id="ipInfo${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_type'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<c:if test="${cfg.ipType==ipTypeC.itemCode}"><spring:message code="${ipTypeC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.srcIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_type'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<c:if test="${cfg.ipType==ipTypeC.itemCode}"><spring:message code="${ipTypeC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.srcIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:forEach>
|
||||
<c:forEach items="${_cfg.httpUrlList}" var="cfg">
|
||||
|
||||
@@ -31,6 +31,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -42,14 +64,14 @@
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -66,10 +88,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -79,11 +101,36 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
@@ -91,28 +138,6 @@
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
});
|
||||
$("#serviceId").val($(".action:checked").attr("serviceId"));
|
||||
$("#protocolId").val($(".action:checked").attr("protocolId"));
|
||||
$("select[name$='protocol']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='protocol']").parents(".form-group").parentsUntil(".row").addClass("hidden");
|
||||
//$("select[name$='direction']").parents(".form-group").addClass("hidden");
|
||||
$("#cfgFrom").validate(
|
||||
{
|
||||
@@ -169,8 +169,6 @@
|
||||
<input type="hidden" name="cfgId" value="${_cfg.cfgId}">
|
||||
<input type="hidden" name="compileId" value="${_cfg.compileId}">
|
||||
<input type="hidden" name="functionId" value="${_cfg.functionId}">
|
||||
<input type="hidden" name="isValid" value="${_cfg.isValid}">
|
||||
<input type="hidden" name="isAudit" value="${_cfg.isAudit}">
|
||||
<!-- <input type="hidden" name="protocol" value="0">
|
||||
<input type="hidden" name="direction" value="0"> -->
|
||||
<input type="hidden" name="isAreaEffective" value="0" >
|
||||
|
||||
@@ -31,6 +31,28 @@
|
||||
<c:forEach items="${_cfg.ipPortList}" var="cfg">
|
||||
<c:if test="${region[1] eq cfg.cfgType }">
|
||||
<div id="${region[1]}Info${index}" class="content" name="subCfg${index}">
|
||||
<div class="row">
|
||||
<div class="col-md-4 hidden">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
@@ -42,14 +64,14 @@
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='ip_pattern'/>:</label>
|
||||
<label><spring:message code='src_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.ipPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -66,10 +88,10 @@
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='port_pattern'/>:</label>
|
||||
<label><spring:message code='src_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.portPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
<c:if test="${cfg.srcPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
@@ -79,38 +101,41 @@
|
||||
<label><spring:message code='client_port'/>:</label><label>${cfg.srcPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_ip'/>:</label><label>${cfg.destIpAddress }</label>
|
||||
<label><spring:message code='dest_ip_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('IP_PATTERN')}" var="ipPatternC">
|
||||
<c:if test="${cfg.destIpPattern==ipPatternC.itemCode}"><spring:message code="${ipPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
<label><spring:message code='server_ip'/>:</label>
|
||||
<label>
|
||||
${cfg.destIpAddress}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='direction'/>:</label>
|
||||
<label><spring:message code='dest_port_pattern'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('DIRECTION')}" var="directionC">
|
||||
<c:if test="${cfg.direction eq directionC.itemCode}"><spring:message code="${directionC.itemValue }"/></c:if>
|
||||
<c:forEach items="${fns:getDictList('PORT_PATTERN')}" var="portPatternC">
|
||||
<c:if test="${cfg.destPortPattern eq portPatternC.itemCode}"><spring:message code="${portPatternC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4 hidden">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<label><spring:message code='protocol'/>:</label>
|
||||
<label>
|
||||
<c:forEach items="${fns:getDictList('PROTOCOL')}" var="protocolC">
|
||||
<c:if test="${cfg.protocol eq protocolC.itemCode}"><spring:message code="${protocolC.itemValue }"/></c:if>
|
||||
</c:forEach>
|
||||
</label>
|
||||
<label><spring:message code='server_port'/>:</label><label>${cfg.destPort }</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -297,66 +297,21 @@ jQuery.validator.addMethod("protocolPort",function(value, element) {
|
||||
return true;
|
||||
}
|
||||
});
|
||||
|
||||
//ip地址校验
|
||||
jQuery.validator.addMethod("ipCheck",function(value, element) {
|
||||
/**
|
||||
*将验证单独提出,源IP,目的IP分别调用该方法
|
||||
*/
|
||||
var validateIpPattern= function(ipType,ipPattern,value,element){
|
||||
var ipv4_ip_subnet_regexp=/^(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|[1-9])\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\/(3[0-2]|1[6-9]|2[0-9])$/;
|
||||
var ipv6_ip_subnet_regexp=/^((::)|(([0-9A-Fa-f]{1,4}:){7}[0-9A-Fa-f]{1,4})|(([0-9A-Fa-f]{1,4}:){1,7}:)|(([0-9A-Fa-f]{1,4}:){6}:[0-9A-Fa-f]{1,4})|(([0-9A-Fa-f]{1,4}:){5}(:[0-9A-Fa-f]{1,4}){1,2})|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){1,3})|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){1,4})|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){1,5})|([0-9A-Fa-f]{1,4}:(:[0-9A-Fa-f]{1,4}){1,6})|(:(:[0-9A-Fa-f]{1,4}){1,7})|(([0-9A-Fa-f]{1,4}:){6}(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){5}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){0,1}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){0,2}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){0,3}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|([0-9A-Fa-f]{1,4}:(:[0-9A-Fa-f]{1,4}){0,4}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(:(:[0-9A-Fa-f]{1,4}){0,5}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3}))\/([2-9]|[1-9][0-9]|1[0-2][0-8])$/;
|
||||
var ipv4_ip_range_regexp=/^(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|[1-9])\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)-(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|[1-9])\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)$/;
|
||||
var ipv6_ip_range_regexp= /^((::)|(([0-9A-Fa-f]{1,4}:){7}[0-9A-Fa-f]{1,4})|(([0-9A-Fa-f]{1,4}:){1,7}:)|(([0-9A-Fa-f]{1,4}:){6}:[0-9A-Fa-f]{1,4})|(([0-9A-Fa-f]{1,4}:){5}(:[0-9A-Fa-f]{1,4}){1,2})|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){1,3})|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){1,4})|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){1,5})|([0-9A-Fa-f]{1,4}:(:[0-9A-Fa-f]{1,4}){1,6})|(:(:[0-9A-Fa-f]{1,4}){1,7})|(([0-9A-Fa-f]{1,4}:){6}(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){5}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){0,1}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){0,2}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){0,3}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|([0-9A-Fa-f]{1,4}:(:[0-9A-Fa-f]{1,4}){0,4}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(:(:[0-9A-Fa-f]{1,4}){0,5}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3}))\-((::)|(([0-9A-Fa-f]{1,4}:){7}[0-9A-Fa-f]{1,4})|(([0-9A-Fa-f]{1,4}:){1,7}:)|(([0-9A-Fa-f]{1,4}:){6}:[0-9A-Fa-f]{1,4})|(([0-9A-Fa-f]{1,4}:){5}(:[0-9A-Fa-f]{1,4}){1,2})|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){1,3})|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){1,4})|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){1,5})|([0-9A-Fa-f]{1,4}:(:[0-9A-Fa-f]{1,4}){1,6})|(:(:[0-9A-Fa-f]{1,4}){1,7})|(([0-9A-Fa-f]{1,4}:){6}(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){5}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){0,1}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){0,2}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){0,3}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|([0-9A-Fa-f]{1,4}:(:[0-9A-Fa-f]{1,4}){0,4}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(:(:[0-9A-Fa-f]{1,4}){0,5}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3}))$/;
|
||||
var ipv4_ip_regexp=/^(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|[1-9])\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)$/;
|
||||
var ipv6_ip_regexp=/^((::)|(([0-9A-Fa-f]{1,4}:){7}[0-9A-Fa-f]{1,4})|(([0-9A-Fa-f]{1,4}:){1,7}:)|(([0-9A-Fa-f]{1,4}:){6}:[0-9A-Fa-f]{1,4})|(([0-9A-Fa-f]{1,4}:){5}(:[0-9A-Fa-f]{1,4}){1,2})|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){1,3})|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){1,4})|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){1,5})|([0-9A-Fa-f]{1,4}:(:[0-9A-Fa-f]{1,4}){1,6})|(:(:[0-9A-Fa-f]{1,4}){1,7})|(([0-9A-Fa-f]{1,4}:){6}(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){5}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){0,1}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){0,2}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){0,3}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|([0-9A-Fa-f]{1,4}:(:[0-9A-Fa-f]{1,4}){0,4}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3})|(:(:[0-9A-Fa-f]{1,4}){0,5}:(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])){3}))$/;
|
||||
var name=$(element).attr("name");
|
||||
if(value.length==0||value.trim().length==0){return true;}
|
||||
var ipTypeE,ipPatternE,srcIpAddressE,destIpAddressE;
|
||||
if(name.indexOf("srcIpAddress")>-1){
|
||||
srcIpAddressE=$(element);
|
||||
ipTypeE=$("select[name='"+name.replace("srcIpAddress","ipType")+"']");
|
||||
ipPatternE=$("select[name='"+name.replace("srcIpAddress","ipPattern")+"']");
|
||||
destIpAddressE=$("input[name='"+name.replace("srcIpAddress","destIpAddress")+"']");
|
||||
}else if(name.indexOf("destIpAddress")>-1){
|
||||
destIpAddressE=$(element);
|
||||
ipTypeE=$("select[name='"+name.replace("destIpAddress","ipType")+"']");
|
||||
ipPatternE=$("select[name='"+name.replace("destIpAddress","ipPattern")+"']");
|
||||
srcIpAddressE=$("input[name='"+name.replace("destIpAddress","srcIpAddress")+"']");
|
||||
}
|
||||
var typeInt=ipTypeE.val();
|
||||
var ipPattern=ipPatternE.val();
|
||||
var srcIpAddress=srcIpAddressE.val();
|
||||
var destIpAddress=destIpAddressE.val();
|
||||
var srcIpIsHidden=srcIpAddressE.is(":hidden");
|
||||
var destIpIsHidden=destIpAddressE.is(":hidden");
|
||||
var IPv4RangeDefault="0.0.0.0-0.0.0.0";
|
||||
if(ipPattern==1){//ip/掩码格式
|
||||
srcIpAddress=srcIpAddress.indexOf("/") >-1 ?srcIpAddress.split("/")[0] : srcIpAddress;
|
||||
destIpAddress=destIpAddress.indexOf("/") >-1 ?destIpAddress.split("/")[0] : destIpAddress;
|
||||
}else if (ipPattern==2){
|
||||
srcIpAddress=srcIpAddress.indexOf("-") >-1 ?srcIpAddress.split("-")[0] : srcIpAddress;
|
||||
destIpAddress=destIpAddress.indexOf("-") >-1 ?destIpAddress.split("-")[0] : destIpAddress;
|
||||
}
|
||||
if(srcIpIsHidden){
|
||||
if((srcIpAddress == destIpAddress)){
|
||||
$.validator.messages.ipCheck=$.validator.messages.destIpIsNotValue+destIpAddress;
|
||||
return false;
|
||||
}
|
||||
}else if(destIpIsHidden){
|
||||
if((srcIpAddress == destIpAddress)){
|
||||
$.validator.messages.ipCheck=$.validator.messages.srcIpIsNotValue+srcIpAddress;
|
||||
return false;
|
||||
}
|
||||
}else{
|
||||
if((srcIpAddress == destIpAddress)){
|
||||
$.validator.messages.ipCheck=$.validator.messages.srcIpNotEqDestIp+srcIpAddress
|
||||
+$.validator.messages.destIpNotEqDestIp+destIpAddress
|
||||
+$.validator.messages.IpNotEqDestIp;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if(typeInt==4){
|
||||
if(ipType==4){
|
||||
if(ipPattern){
|
||||
if(ipPattern==1){//ip/掩码格式
|
||||
if(this.optional(element)||(/^(\d+)\.(\d+)\.(\d+)\.(\d+)\/(\d+)$/.test(value) && (RegExp.$1 <256 && RegExp.$2<256 && RegExp.$3<256 && RegExp.$4<256 && RegExp.$5<=32))){
|
||||
if(jQuery.validator.prototype.optional(element)||(/^(\d+)\.(\d+)\.(\d+)\.(\d+)\/(\d+)$/.test(value) && (RegExp.$1 <256 && RegExp.$2<256 && RegExp.$3<256 && RegExp.$4<256 && RegExp.$5<=32))){
|
||||
if(ipv4_ip_subnet_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
@@ -407,7 +362,7 @@ jQuery.validator.addMethod("ipCheck",function(value, element) {
|
||||
return false;
|
||||
}
|
||||
}else if(ipPattern==3){//ip格式
|
||||
if(this.optional(element)||ipv4_ip_regexp.test(value)){
|
||||
if(jQuery.validator.prototype.optional(element)||ipv4_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
@@ -415,16 +370,16 @@ jQuery.validator.addMethod("ipCheck",function(value, element) {
|
||||
}
|
||||
}
|
||||
}else{//兼容原来的验证
|
||||
if(this.optional(element)||ipv4_ip_regexp.test(value)){
|
||||
if(jQuery.validator.prototype.optional(element)||ipv4_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}else if(typeInt==6){
|
||||
}else if(ipType==6){
|
||||
if(ipPattern==1){//ip/掩码格式
|
||||
if(this.optional(element)||ipv6_ip_subnet_regexp.test(value)){
|
||||
if(jQuery.validator.prototype.optional(element)||ipv6_ip_subnet_regexp.test(value)){
|
||||
return true;
|
||||
}else if(value.indexOf("/")==-1){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
@@ -462,326 +417,14 @@ jQuery.validator.addMethod("ipCheck",function(value, element) {
|
||||
}
|
||||
return false;
|
||||
}else if(ipPattern==3){//ip格式
|
||||
if(this.optional(element)||ipv6_ip_regexp.test(value)){
|
||||
if(jQuery.validator.prototype.optional(element)||ipv6_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}else{//兼容原来的验证
|
||||
if(this.optional(element)||ipv6_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}else if(typeInt==46){
|
||||
var name=$(element).attr("name");
|
||||
if(name.indexOf("srcIpAddress")>-1){
|
||||
if(ipPattern==1){//ip/掩码格式
|
||||
if(this.optional(element)||(/^(\d+)\.(\d+)\.(\d+)\.(\d+)\/(\d+)$/.test(value) && (RegExp.$1 <256 && RegExp.$2<256 && RegExp.$3<256 && RegExp.$4<256 && RegExp.$5<=32))){
|
||||
if(ipv4_ip_subnet_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMaskRange;
|
||||
return false;
|
||||
}
|
||||
}else if(RegExp.$5&&RegExp.$5>32){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMaskRange;
|
||||
return false;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}
|
||||
}else if(ipPattern==2){//ip range
|
||||
//A类 0.0.0.0-127.255.255.255 默认掩码255.0.0.0
|
||||
//B类128.0.0.0-191.255.255.255 默认掩码255.255.0.0
|
||||
//C类192.0.0.0-223.255.255.255 默认掩码255.255.255.0
|
||||
if(ipv4_ip_range_regexp.test(value)){
|
||||
var startIp=value.split("-")[0];
|
||||
var endIp=value.split("-")[1];
|
||||
var startPart0=startIp.split(".")[0];
|
||||
var startPart1=endIp.split(".")[0];
|
||||
if(value==IPv4RangeDefault){
|
||||
return true;
|
||||
}
|
||||
if((startPart0<128&&startPart1<128)||(startPart0>127&&startPart1>127&&startPart0<192&&startPart1<192)
|
||||
||(startPart0>191&&startPart1>191&&startPart0<224&&startPart1<224)
|
||||
||(startPart0>223&&startPart1>223&&startPart0<240&&startPart1<240)
|
||||
||(startPart0>239&&startPart1>239&&startPart0<256&&startPart1<256)){//仅允许同段IP
|
||||
if(ipToNumber(startIp)<=ipToNumber(endIp)){//比较IP大小
|
||||
if((startIp.split(".")[0]!=endIp.split(".")[0])||
|
||||
(startIp.split(".")[1]!=endIp.split(".")[1])||
|
||||
(startIp.split(".")[2]!=endIp.split(".")[2])){
|
||||
$.validator.messages.ipCheck=$.validator.messages.netAddress;
|
||||
}else{
|
||||
return true;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange1;
|
||||
return false;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange;
|
||||
return false;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange;
|
||||
return false;
|
||||
}
|
||||
}else if(ipPattern==3){//ip
|
||||
if(this.optional(element)||ipv4_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}else if(name.indexOf("destIpAddress")>-1){
|
||||
if(ipPattern==1){//ip/掩码格式
|
||||
if(this.optional(element)||ipv6_ip_subnet_regexp.test(value)){
|
||||
return true;
|
||||
}else if(value.indexOf("/")==-1){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}else{
|
||||
var ipMaskArr=value.split("/");
|
||||
if(ipMaskArr.length!=2){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}else{
|
||||
if(!ipv6_ip_regexp.test(ipMaskArr[0])){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipPart;
|
||||
return false;
|
||||
//}else if(!/^(0|2|4|8|16|32|64|128)$/.test(ipMaskArr[1])){
|
||||
}else if(!/^([2-9]|[1-9][0-9]|1[0-2][0-8])$/.test(ipMaskArr[1])){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipv6MaskPart;
|
||||
return false;
|
||||
} else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}else if(ipPattern==2){//ip range
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange;
|
||||
if(ipv6_ip_range_regexp.test(value)){
|
||||
var ipArr=value.split("-");
|
||||
var startIp=fillIp(ipArr[0]);
|
||||
var endIp=fillIp(ipArr[1]);
|
||||
//默认比较前64位
|
||||
var exp1=/^[0-9A-Fa-f]*:[0-9A-Fa-f]*:[0-9A-Fa-f]*:[0-9A-Fa-f]*/;
|
||||
var startPre=String(startIp.match(exp1));
|
||||
var endPre=String(endIp.match(exp1));
|
||||
return startPre==endPre;
|
||||
}
|
||||
return false;
|
||||
}else if(ipPattern==3){//ip格式
|
||||
if(this.optional(element)||ipv6_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}else{//兼容原来的验证
|
||||
if(this.optional(element)||ipv6_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}else if(typeInt==64){
|
||||
var name=$(element).attr("name");
|
||||
if(name.indexOf("srcIpAddress")>-1){
|
||||
if(ipPattern==1){//ip/掩码格式
|
||||
if(this.optional(element)||ipv6_ip_subnet_regexp.test(value)){
|
||||
return true;
|
||||
}else if(value.indexOf("/")==-1){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}else{
|
||||
var ipMaskArr=value.split("/");
|
||||
if(ipMaskArr.length!=2){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}else{
|
||||
if(!ipv6_ip_regexp.test(ipMaskArr[0])){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipPart;
|
||||
return false;
|
||||
//}else if(!/^(0|2|4|8|16|32|64|128)$/.test(ipMaskArr[1])){
|
||||
}else if(!/^([2-9]|[1-9][0-9]|1[0-2][0-8])$/.test(ipMaskArr[1])){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipv6MaskPart;
|
||||
return false;
|
||||
} else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}else if(ipPattern==2){//ip range
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange;
|
||||
if(ipv6_ip_range_regexp.test(value)){
|
||||
var ipArr=value.split("-");
|
||||
var startIp=fillIp(ipArr[0]);
|
||||
var endIp=fillIp(ipArr[1]);
|
||||
//默认比较前64位
|
||||
var exp1=/^[0-9A-Fa-f]*:[0-9A-Fa-f]*:[0-9A-Fa-f]*:[0-9A-Fa-f]*/;
|
||||
var startPre=String(startIp.match(exp1));
|
||||
var endPre=String(endIp.match(exp1));
|
||||
return startPre==endPre;
|
||||
}
|
||||
return false;
|
||||
}else if(ipPattern==3){//ip格式
|
||||
if(this.optional(element)||ipv6_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}else{//兼容原来的验证
|
||||
if(this.optional(element)||ipv6_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}else if(name.indexOf("destIpAddress")>-1){
|
||||
if(ipPattern==1){//ip/掩码格式
|
||||
if(this.optional(element)||(/^(\d+)\.(\d+)\.(\d+)\.(\d+)\/(\d+)$/.test(value) && (RegExp.$1 <256 && RegExp.$2<256 && RegExp.$3<256 && RegExp.$4<256 && RegExp.$5<=32))){
|
||||
if(ipv4_ip_subnet_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMaskRange;
|
||||
return false;
|
||||
}
|
||||
}else if(RegExp.$5&&RegExp.$5>32){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMaskRange;
|
||||
return false;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}
|
||||
}else if(ipPattern==2){//ip range
|
||||
//A类 0.0.0.0-127.255.255.255 默认掩码255.0.0.0
|
||||
//B类128.0.0.0-191.255.255.255 默认掩码255.255.0.0
|
||||
//C类192.0.0.0-223.255.255.255 默认掩码255.255.255.0
|
||||
if(ipv4_ip_range_regexp.test(value)){
|
||||
var startIp=value.split("-")[0];
|
||||
var endIp=value.split("-")[1];
|
||||
var startPart0=startIp.split(".")[0];
|
||||
var startPart1=endIp.split(".")[0];
|
||||
if(value==IPv4RangeDefault){
|
||||
return true;
|
||||
}
|
||||
if((startPart0<128&&startPart1<128)||(startPart0>127&&startPart1>127&&startPart0<192&&startPart1<192)
|
||||
||(startPart0>191&&startPart1>191&&startPart0<224&&startPart1<224)
|
||||
||(startPart0>223&&startPart1>223&&startPart0<240&&startPart1<240)
|
||||
||(startPart0>239&&startPart1>239&&startPart0<256&&startPart1<256)){//仅允许同段IP
|
||||
if(ipToNumber(startIp)<=ipToNumber(endIp)){//比较IP大小
|
||||
if((startIp.split(".")[0]!=endIp.split(".")[0])||
|
||||
(startIp.split(".")[1]!=endIp.split(".")[1])||
|
||||
(startIp.split(".")[2]!=endIp.split(".")[2])){
|
||||
$.validator.messages.ipCheck=$.validator.messages.netAddress;
|
||||
}else{
|
||||
return true;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange1;
|
||||
return false;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange;
|
||||
return false;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange;
|
||||
return false;
|
||||
}
|
||||
}else if(ipPattern==3){//ip
|
||||
if(this.optional(element)||ipv4_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}else if(typeInt==10){
|
||||
if(ipPattern){
|
||||
if(ipPattern==1){//ip/掩码格式
|
||||
if(ipv4_ip_subnet_regexp.test(value)){
|
||||
return true;
|
||||
}else if(ipv6_ip_subnet_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipMask;
|
||||
return false;
|
||||
}
|
||||
}else if(ipPattern==2){//ip range
|
||||
//A类 0.0.0.0-127.255.255.255 默认掩码255.0.0.0
|
||||
//B类128.0.0.0-191.255.255.255 默认掩码255.255.0.0
|
||||
//C类192.0.0.0-223.255.255.255 默认掩码255.255.255.0
|
||||
if(ipv4_ip_range_regexp.test(value)){
|
||||
var startIp=value.split("-")[0];
|
||||
var endIp=value.split("-")[1];
|
||||
var startPart0=startIp.split(".")[0];
|
||||
var startPart1=endIp.split(".")[0];
|
||||
if(value==IPv4RangeDefault){
|
||||
return true;
|
||||
}
|
||||
if((startPart0<128&&startPart1<128)||(startPart0>127&&startPart1>127&&startPart0<192&&startPart1<192)
|
||||
||(startPart0>191&&startPart1>191&&startPart0<224&&startPart1<224)
|
||||
||(startPart0>223&&startPart1>223&&startPart0<240&&startPart1<240)
|
||||
||(startPart0>239&&startPart1>239&&startPart0<256&&startPart1<256)){//仅允许同段IP
|
||||
if(ipToNumber(startIp)<=ipToNumber(endIp)){//比较IP大小
|
||||
if((startIp.split(".")[0]!=endIp.split(".")[0])||
|
||||
(startIp.split(".")[1]!=endIp.split(".")[1])||
|
||||
(startIp.split(".")[2]!=endIp.split(".")[2])){
|
||||
$.validator.messages.ipCheck=$.validator.messages.netAddress;
|
||||
}else{
|
||||
return true;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange1;
|
||||
return false;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange;
|
||||
return false;
|
||||
}
|
||||
}else if(ipv6_ip_subnet_regexp.test(value)){
|
||||
var ipArr=value.split("-");
|
||||
var startIp=fillIp(ipArr[0]);
|
||||
var endIp=fillIp(ipArr[1]);
|
||||
//默认比较前64位
|
||||
var exp1=/^[0-9A-Fa-f]*:[0-9A-Fa-f]*:[0-9A-Fa-f]*:[0-9A-Fa-f]*/;
|
||||
var startPre=String(startIp.match(exp1));
|
||||
var endPre=String(endIp.match(exp1));
|
||||
if(startPre!=endPre){
|
||||
$.validator.messages.ipCheck=$.validator.messages.ipRange;
|
||||
return false;
|
||||
}else{
|
||||
return true;
|
||||
}
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
|
||||
}else if(ipPattern==3){//ip格式
|
||||
if(ipv4_ip_regexp.test(value)||ipv6_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}else{//兼容原来的验证
|
||||
if(this.optional(element)||(/^(\d+)\.(\d+)\.(\d+)\.(\d+)$/.test(value) && (RegExp.$1 <256 && RegExp.$2<256 && RegExp.$3<256 && RegExp.$4<256))){
|
||||
if(jQuery.validator.prototype.optional(element)||ipv6_ip_regexp.test(value)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
@@ -792,6 +435,120 @@ jQuery.validator.addMethod("ipCheck",function(value, element) {
|
||||
$.validator.messages.ipCheck=$.validator.messages.ip;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 校验IP V4范围交叉
|
||||
*/
|
||||
var validateIPV4Range=function(srcIp,destIp){
|
||||
var ipv4_ip_regexp=/^(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|[1-9])\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)\.(0|1\d{2}|2[0-4]\d|25[0-5]|[1-9]\d|\d)$/;
|
||||
var srcStart=0,srcEnd=0,destStart=0,destEnd=0;
|
||||
if(srcIp.indexOf("-") >-1){
|
||||
if(ipv4_ip_regexp.test(srcIp.split('-')[0])){
|
||||
srcStart=ipToNumber(srcIp.split('-')[0]);
|
||||
}
|
||||
if(ipv4_ip_regexp.test(srcIp.split('-')[1])){
|
||||
srcEnd=ipToNumber(srcIp.split('-')[1]);
|
||||
}
|
||||
}
|
||||
if(destIp.indexOf("-") >-1){
|
||||
if(ipv4_ip_regexp.test(destIp.split('-')[0])){
|
||||
destStart=ipToNumber(destIp.split('-')[0]);
|
||||
}
|
||||
if(ipv4_ip_regexp.test(destIp.split('-')[1])){
|
||||
destEnd=ipToNumber(destIp.split('-')[1]);
|
||||
}
|
||||
}
|
||||
if(srcStart>0||srcEnd>0){
|
||||
if(destStart>0||destEnd>0){
|
||||
if(srcStart>destEnd||srcEnd<destStart){
|
||||
}else{
|
||||
var tip=$.validator.format($.validator.messages.rangeCross1);
|
||||
$.validator.messages.ipCheck=tip(srcIp,destIp);
|
||||
return false;
|
||||
}
|
||||
}else if(ipv4_ip_regexp.test(destIp)){
|
||||
if(srcStart<=ipToNumber(destIp)&&ipToNumber(destIp)<=srcEnd){
|
||||
var tip=$.validator.format($.validator.messages.rangeCross0);
|
||||
$.validator.messages.ipCheck=tip(destIp,srcIp.split('-')[0],srcIp.split('-')[1]);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}else if(destStart>0||destEnd>0){
|
||||
if(ipv4_ip_regexp.test(srcIp)){
|
||||
if(destStart<=ipToNumber(srcIp)&&ipToNumber(srcIp)<=destEnd){
|
||||
var tip=$.validator.format($.validator.messages.rangeCross0);
|
||||
$.validator.messages.ipCheck=tip(srcIp,destIp.split('-')[0],destIp.split('-')[1]);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
//$.validator.messages.ipCheck="";
|
||||
return true;
|
||||
}
|
||||
//ip地址校验
|
||||
jQuery.validator.addMethod("ipCheck",function(value, element) {
|
||||
var name=$(element).attr("name");
|
||||
if(value.length==0||value.trim().length==0){return true;}
|
||||
var ipTypeE,srcIpPatternE,descIpPatternE,srcIpAddressE,destIpAddressE;
|
||||
if(name.indexOf("srcIpAddress")>-1){
|
||||
srcIpAddressE=$(element);
|
||||
ipTypeE=$("select[name='"+name.replace("srcIpAddress","ipType")+"']");
|
||||
srcIpPatternE=$("select[name='"+name.replace("srcIpAddress","srcIpPattern")+"']");
|
||||
destIpPatternE=$("select[name='"+name.replace("srcIpAddress","destIpPattern")+"']");
|
||||
destIpAddressE=$("input[name='"+name.replace("srcIpAddress","destIpAddress")+"']");
|
||||
}else if(name.indexOf("destIpAddress")>-1){
|
||||
destIpAddressE=$(element);
|
||||
ipTypeE=$("select[name='"+name.replace("destIpAddress","ipType")+"']");
|
||||
srcIpPatternE=$("select[name='"+name.replace("destIpAddress","srcIpPattern")+"']");
|
||||
destIpPatternE=$("select[name='"+name.replace("destIpAddress","destIpPattern")+"']");
|
||||
srcIpAddressE=$("input[name='"+name.replace("destIpAddress","srcIpAddress")+"']");
|
||||
}
|
||||
var typeInt=ipTypeE.val();
|
||||
var srcIpPattern=srcIpPatternE.val();
|
||||
var destIpPattern=destIpPatternE.val();
|
||||
var srcIpAddress=srcIpAddressE.val();
|
||||
var destIpAddress=destIpAddressE.val();
|
||||
var srcIpIsHidden=srcIpAddressE.is(":hidden");
|
||||
var destIpIsHidden=destIpAddressE.is(":hidden");
|
||||
if(srcIpPattern==1){//ip/掩码格式
|
||||
srcIpAddress=srcIpAddress.indexOf("/") >-1 ?srcIpAddress.split("/")[0] : srcIpAddress;
|
||||
}else if (srcIpPattern==2){
|
||||
srcIpAddress=srcIpAddress.indexOf("-") >-1 ?srcIpAddress.split("-")[0] : srcIpAddress;
|
||||
}
|
||||
if(destIpPattern==1){//ip/掩码格式
|
||||
destIpAddress=destIpAddress.indexOf("/") >-1 ?destIpAddress.split("/")[0] : destIpAddress;
|
||||
}else if (destIpPattern==2){
|
||||
destIpAddress=destIpAddress.indexOf("-") >-1 ?destIpAddress.split("-")[0] : destIpAddress;
|
||||
}
|
||||
if(srcIpIsHidden){
|
||||
if((srcIpAddress == destIpAddress)){
|
||||
$.validator.messages.ipCheck=$.validator.messages.destIpIsNotValue+destIpAddress;
|
||||
return false;
|
||||
}
|
||||
}else if(destIpIsHidden){
|
||||
if((srcIpAddress == destIpAddress)){
|
||||
$.validator.messages.ipCheck=$.validator.messages.srcIpIsNotValue+srcIpAddress;
|
||||
return false;
|
||||
}
|
||||
}else{
|
||||
if((srcIpAddress == destIpAddress)){
|
||||
$.validator.messages.ipCheck=$.validator.messages.srcIpNotEqDestIp+srcIpAddress
|
||||
+$.validator.messages.destIpNotEqDestIp+destIpAddress
|
||||
+$.validator.messages.IpNotEqDestIp;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
var srcValid=true,destValid=true;
|
||||
if(name.indexOf("srcIpAddress")>-1){
|
||||
srcValid=validateIpPattern(typeInt,srcIpPattern,value, element);
|
||||
}else{
|
||||
destValid=validateIpPattern(typeInt,destIpPattern,value, element);
|
||||
}
|
||||
if(srcValid&&destValid){
|
||||
return validateIPV4Range(srcIpAddressE.val().indexOf("/")>-1?srcIpAddressE.val().split('/')[0]:srcIpAddressE.val(),destIpAddressE.val().indexOf("/")>-1?destIpAddressE.val().split('/')[0]:destIpAddressE.val());
|
||||
}else{
|
||||
return false;
|
||||
}
|
||||
}, $.validator.messages.ip);
|
||||
//ip地址掩码校验
|
||||
jQuery.validator.addMethod("ipMask",function(value, element) {
|
||||
@@ -817,15 +574,17 @@ jQuery.validator.addMethod("ipMask",function(value, element) {
|
||||
}, $.validator.messages.ipMask);
|
||||
jQuery.validator.addMethod("portCheck",function(value, element) {
|
||||
if(value.length==0||value.trim().length==0){return true;}
|
||||
var typeInt=$(element).parents(".row").parent(".row").find("select[name$='portPattern']").val();
|
||||
if(typeInt==1){//port 0~65535
|
||||
var name=$(element).attr("name");
|
||||
|
||||
var portPattern=$(element).parents(".row").parent(".row").find("select[name$='"+name+"Pattern']").val();
|
||||
if(portPattern==1){//port 0~65535
|
||||
if(this.optional(element)||(/^(0|[1-9][0-9]{0,4})$/.test(value)&& RegExp.$1 <=65535)){
|
||||
return true;
|
||||
}else{
|
||||
$.validator.messages.portCheck=$.validator.messages.portRange
|
||||
return false;
|
||||
}
|
||||
}else if(typeInt==2){// port -mask 0~65535/0~65535
|
||||
}else if(portPattern==2){// port -mask 0~65535/0~65535
|
||||
if(this.optional(element)||(/^(0|[1-9][0-9]{0,4})\/(0|[1-9][0-9]{0,4})$/.test(value) && RegExp.$1 <=65535 && RegExp.$2 <=65535)){
|
||||
return true;
|
||||
}else{
|
||||
@@ -855,9 +614,12 @@ jQuery.validator.addMethod("areaControl",function(value, element) {
|
||||
return true;
|
||||
}
|
||||
});
|
||||
/*
|
||||
jQuery.validator.addMethod("areaIp",function(value, element) {
|
||||
var typeInt=$(element).parents(".row").parent(".row").find("select[name$='ipType']").val();
|
||||
var ipPattern=$(element).parents(".row").parent(".row").find("select[name$='ipPattern']").val();
|
||||
var name=$(element).attr(name);
|
||||
var srcIpPattern=$(element).parents(".row").parent(".row").find("select[name$='srcIpPattern']").val();
|
||||
var destIpPattern=$(element).parents(".row").parent(".row").find("select[name$='destIpPattern']").val();
|
||||
var msg=$.validator.messages.areaIpPrefix;
|
||||
if(typeInt==4){
|
||||
if(ipPattern==3){
|
||||
@@ -907,6 +669,7 @@ jQuery.validator.addMethod("areaIp",function(value, element) {
|
||||
}
|
||||
}
|
||||
});
|
||||
*/
|
||||
jQuery.validator.addMethod("checkParent",function(value, element) {
|
||||
var parentType=$(element).attr("parent-type");
|
||||
if(parentType&&parentType!=0&&parentType!=value){
|
||||
|
||||
@@ -94,6 +94,8 @@
|
||||
expireTip:"Start time and end time interval is at least 1 minute",
|
||||
compareTip:"Start time should not be less than the current time plus 2 minutes.",
|
||||
compileIdCheck:"Please enter the correct query format",
|
||||
compileIdCheckNum:"The number of queries should not be greater than 200"
|
||||
compileIdCheckNum:"The number of queries should not be greater than 200",
|
||||
rangeCross0:"The IP {0} must not between {1} and {2}",
|
||||
rangeCross1:"The IP range {0} has intersections with {1}"
|
||||
});
|
||||
}(jQuery));
|
||||
|
||||
@@ -94,6 +94,8 @@
|
||||
expireTip:"Start time and end time interval is at least 1 minute",
|
||||
compareTip:"Start time should not be less than the current time plus 2 minutes.",
|
||||
compileIdCheck:"Please enter the correct query format",
|
||||
compileIdCheckNum:"The number of queries should not be greater than 200"
|
||||
compileIdCheckNum:"The number of queries should not be greater than 200",
|
||||
rangeCross0:"The IP {0} must not between {1} and {2}",
|
||||
rangeCross1:"The IP range {0} has intersections with {1}"
|
||||
});
|
||||
}(jQuery));
|
||||
|
||||
@@ -94,6 +94,8 @@
|
||||
expireTip:"开始时间结束时间间隔至少为1分钟",
|
||||
compareTip:"开始时间不能小于当前时间加上2分钟 ",
|
||||
compileIdCheck:"请输入正确的查询格式",
|
||||
compileIdCheckNum:"查询个数不能大于200"
|
||||
compileIdCheckNum:"查询个数不能大于200",
|
||||
rangeCross0:"IP{0}不能介于{1}和{2}",
|
||||
rangeCross1:"IP范围{0}和IP范围{1}有交集"
|
||||
});
|
||||
}(jQuery));
|
||||
|
||||
@@ -227,6 +227,14 @@ $(function(){
|
||||
$("select[name$='portPattern']").on("change",function(){
|
||||
switchIpInfo(this);
|
||||
});
|
||||
//src IP pattern dest IP pattern
|
||||
$("select[name$='IpPattern']").on("change",function(){
|
||||
switchIpInfo(this);
|
||||
});
|
||||
//src port pattern dest port pattern
|
||||
$("select[name$='PortPattern']").on("change",function(){
|
||||
switchIpInfo(this);
|
||||
});
|
||||
|
||||
switchAction($("input[name='action']:checked").val());
|
||||
|
||||
@@ -249,6 +257,9 @@ $(function(){
|
||||
obj.find("select[name$='ipPattern']").on("change",function(){
|
||||
switchIpInfo($(this));
|
||||
});
|
||||
obj.find("select[name$='IpPattern']").on("change",function(){
|
||||
switchIpInfo($(this));
|
||||
});
|
||||
obj.appendTo("#areaIp");
|
||||
$("#areaIsp").find(".container-fluid").each(function(){
|
||||
if(!$(this).hasClass("hidden")) $(this).remove();
|
||||
@@ -713,13 +724,6 @@ $(function(){
|
||||
$(".boxSolid:visible").each(function(){
|
||||
$(this).prev("h4").find(".glyphicon-plus").addClass("hidden");
|
||||
});
|
||||
//IP域修改时默认展开,不显示show more
|
||||
if($("input[name='compileId']")&&$("input[name='compileId']").val()!=0&&($(".btn-red-hollow").parents(".boxSolid").is(":visible")||$("input[name$='cfgRegionCode']").length==1)){
|
||||
$(".port").removeClass("hidden").removeClass("disabled");
|
||||
$(".destPort").removeClass("hidden").removeClass("disabled");
|
||||
$(".protocol").removeClass("hidden").removeClass("disabled");
|
||||
$(".btn-red-hollow").addClass("hidden");
|
||||
}
|
||||
|
||||
$("#messageBox .close").on("click",function(){
|
||||
heightDiv(1);
|
||||
@@ -892,52 +896,6 @@ var setDefaultMatchMethod=function (obj){
|
||||
$(obj).parents(".row").parent(".row").find("select[name$='matchMethod']").selectpicker("refresh");
|
||||
}
|
||||
}
|
||||
var switchIpType=function(obj){
|
||||
var type=$(obj).val();
|
||||
var row=$(obj).parents('.row');
|
||||
var ipPattern=row.siblings().find("input[name$='ipPattern']");
|
||||
var portPattern=row.siblings().find("input[name$='portPattern']");
|
||||
var srcIp=row.siblings().find("input[name$='srcIpAddress']");
|
||||
var dstIp=row.siblings().find("input[name$='destIpAddress']");
|
||||
var srcPort=row.siblings().find("input[name$='srcPort']");
|
||||
var dstPort=row.siblings().find("input[name$='destPort']");
|
||||
if(4==type){
|
||||
if(!$(srcIp).val()){
|
||||
$(srcIp).val("0.0.0.0");
|
||||
}else if($(srcIp).val()=="::"){
|
||||
$(srcIp).val("0.0.0.0");
|
||||
}
|
||||
if(!$(dstIp).val()){
|
||||
$(dstIp).val("0.0.0.0");
|
||||
}else if($(dstIp).val()=="::"){
|
||||
$(dstIp).val("0.0.0.0");
|
||||
}
|
||||
if(!$(srcPort).val()){
|
||||
$(srcPort).val("0");
|
||||
}
|
||||
if(!$(dstPort).val()){
|
||||
$(dstPort).val("0");
|
||||
}
|
||||
}
|
||||
if(6==type){
|
||||
if(!$(srcIp).val()){
|
||||
$(srcIp).val("::");
|
||||
}else if($(srcIp).val()=="0.0.0.0"){
|
||||
$(srcIp).val("::");
|
||||
}
|
||||
if(!$(dstIp).val()){
|
||||
$(dstIp).val("::");
|
||||
}else if($(dstIp).val()=="0.0.0.0"){
|
||||
$(dstIp).val("::");
|
||||
}
|
||||
if(!$(srcPort).val()){
|
||||
$(srcPort).val("0");
|
||||
}
|
||||
if(!$(dstPort).val()){
|
||||
$(dstPort).val("0");
|
||||
}
|
||||
}
|
||||
}
|
||||
var switchAction=function(action){
|
||||
/********************dns reject时选择策略**********************/
|
||||
if(action == 16){ //reject
|
||||
@@ -986,16 +944,16 @@ var switchAction=function(action){
|
||||
$(".doLog").removeClass("hidden");
|
||||
}*/
|
||||
}
|
||||
//ipType、ipPattern、portPattern选项变化时调用此方法,添加默认值
|
||||
//ipType、srcIpPattern,destIpPattern、srcPortPattern,destPortPattern选项变化时调用此方法,添加默认值
|
||||
var switchIpInfo=function(obj){
|
||||
var ipType="";
|
||||
var ipPattern="";
|
||||
var portPattern="";
|
||||
var ipType="",srcIpPattern="",destIpPattern="",srcPortPattern="",destPortPattern="";
|
||||
|
||||
var row=$(obj).parents('.row').parent('.row');
|
||||
ipType=row.find("select[name$='ipType']").val();
|
||||
ipPattern=row.find("select[name$='ipPattern']").val();
|
||||
portPattern=row.find("select[name$='portPattern']").val();
|
||||
srcIpPattern=row.find("select[name$='srcIpPattern']").val();
|
||||
destIpPattern=row.find("select[name$='destIpPattern']").val();
|
||||
srcPortPattern=row.find("select[name$='srcPortPattern']").val();
|
||||
destPortPattern=row.find("select[name$='destPortPattern']").val();
|
||||
var srcIp=row.find("input[name$='srcIpAddress']");
|
||||
var destIp=row.find("input[name$='destIpAddress']");
|
||||
var srcPort=row.find("input[name$='srcPort']");
|
||||
@@ -1029,25 +987,23 @@ var switchIpInfo=function(obj){
|
||||
//IPv4设置默认值
|
||||
if(4==ipType){
|
||||
if(!$(srcIp).val()){
|
||||
if(ipPattern==1){
|
||||
if(srcIpPattern==1){
|
||||
$(srcIp).val(srcIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
}else if(srcIpPattern==2){
|
||||
$(srcIp).val(srcIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
}else if(srcIpPattern==3){
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}else{
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(srcIp).val(),srcIpV4Default) > -1
|
||||
|| $.inArray($(srcIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(srcIp).val(),srcIpV6Default) > -1
|
||||
|| $.inArray($(srcIp).val(),destIpV6Default) > -1){ //是ipV4的默认值其中一个
|
||||
if(ipPattern==1){
|
||||
|| $.inArray($(srcIp).val(),srcIpV6Default) > -1 ){ //是ipV4的默认值其中一个
|
||||
if(srcIpPattern==1){
|
||||
$(srcIp).val(srcIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
}else if(srcIpPattern==2){
|
||||
$(srcIp).val(srcIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
}else if(srcIpPattern==3){
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}else{
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
@@ -1055,25 +1011,23 @@ var switchIpInfo=function(obj){
|
||||
}
|
||||
}
|
||||
if(!$(destIp).val()){
|
||||
if(ipPattern==1){
|
||||
if(destIpPattern==1){
|
||||
$(destIp).val(destIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
}else if(destIpPattern==2){
|
||||
$(destIp).val(destIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
}else if(destIpPattern==3){
|
||||
$(destIp).val(destIpV4Default[2]);
|
||||
}else{
|
||||
$(destIp).val(destIpV4Default[2]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(destIp).val(),srcIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),srcIpV6Default) > -1
|
||||
if($.inArray($(destIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),destIpV6Default) > -1){
|
||||
if(ipPattern==1){
|
||||
if(destIpPattern==1){
|
||||
$(destIp).val(destIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
}else if(destIpPattern==2){
|
||||
$(destIp).val(destIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
}else if(destIpPattern==3){
|
||||
$(destIp).val(destIpV4Default[2]);
|
||||
}else{
|
||||
$(destIp).val(destIpV4Default[2]);
|
||||
@@ -1083,25 +1037,23 @@ var switchIpInfo=function(obj){
|
||||
}
|
||||
if(6==ipType){
|
||||
if(!$(srcIp).val()){
|
||||
if(ipPattern==1){
|
||||
if(srcIpPattern==1){
|
||||
$(srcIp).val(srcIpV6Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
}else if(srcIpPattern==2){
|
||||
$(srcIp).val(srcIpV6Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
}else if(srcIpPattern==3){
|
||||
$(srcIp).val(srcIpV6Default[2]);
|
||||
}else{
|
||||
$(srcIp).val(srcIpV6Default[2]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(srcIp).val(),srcIpV4Default) > -1
|
||||
|| $.inArray($(srcIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(srcIp).val(),srcIpV6Default) > -1
|
||||
|| $.inArray($(srcIp).val(),destIpV6Default) > -1){ //是ipV6的默认值其中一个
|
||||
if(ipPattern==1){
|
||||
|| $.inArray($(srcIp).val(),srcIpV6Default) > -1 ){ //是ipV6的默认值其中一个
|
||||
if(srcIpPattern==1){
|
||||
$(srcIp).val(srcIpV6Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
}else if(srcIpPattern==2){
|
||||
$(srcIp).val(srcIpV6Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
}else if(srcIpPattern==3){
|
||||
$(srcIp).val(srcIpV6Default[2]);
|
||||
}else{
|
||||
$(srcIp).val(srcIpV6Default[2]);
|
||||
@@ -1109,25 +1061,23 @@ var switchIpInfo=function(obj){
|
||||
}
|
||||
}
|
||||
if(!$(destIp).val()){
|
||||
if(ipPattern==1){
|
||||
if(destIpPattern==1){
|
||||
$(destIp).val(destIpV6Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
}else if(destIpPattern==2){
|
||||
$(destIp).val(destIpV6Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
}else if(destIpPattern==3){
|
||||
$(destIp).val(destIpV6Default[2]);
|
||||
}else{
|
||||
$(destIp).val(srcIpV6Default[2]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(destIp).val(),srcIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),srcIpV6Default) > -1
|
||||
if($.inArray($(destIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),destIpV6Default) > -1){ //是ipV6的默认值其中一个
|
||||
if(ipPattern==1){
|
||||
if(destIpPattern==1){
|
||||
$(destIp).val(destIpV6Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
}else if(destIpPattern==2){
|
||||
$(destIp).val(destIpV6Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
}else if(destIpPattern==3){
|
||||
$(destIp).val(destIpV6Default[2]);
|
||||
}else{
|
||||
$(destIp).val(srcIpV6Default[2]);
|
||||
@@ -1135,152 +1085,20 @@ var switchIpInfo=function(obj){
|
||||
}
|
||||
}
|
||||
}
|
||||
if(46==ipType){
|
||||
if(!$(srcIp).val()){
|
||||
if(ipPattern==1){
|
||||
$(srcIp).val(srcIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(srcIp).val(srcIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}else{
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(srcIp).val(),srcIpV4Default) > -1
|
||||
|| $.inArray($(srcIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(srcIp).val(),srcIpV6Default) > -1
|
||||
|| $.inArray($(srcIp).val(),destIpV6Default) > -1){
|
||||
if(ipPattern==1){
|
||||
$(srcIp).val(srcIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(srcIp).val(srcIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}else {
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}
|
||||
}
|
||||
}
|
||||
if(!$(destIp).val()){
|
||||
if(ipPattern==1){
|
||||
$(destIp).val(destIpV6Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(destIp).val(destIpV6Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(destIp).val(destIpV6Default[2]);
|
||||
}else{
|
||||
$(destIp).val(destIpV6Default[2]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(destIp).val(),srcIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),srcIpV6Default) > -1
|
||||
|| $.inArray($(destIp).val(),destIpV6Default) > -1){
|
||||
if(ipPattern==1){
|
||||
$(destIp).val(destIpV6Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(destIp).val(destIpV6Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(destIp).val(destIpV6Default[2]);
|
||||
}else{
|
||||
$(destIp).val(destIpV6Default[2]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if(64==ipType){
|
||||
if(!$(srcIp).val()){
|
||||
if(ipPattern==1){
|
||||
$(srcIp).val(srcIpV6Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(srcIp).val(srcIpV6Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(srcIp).val(srcIpV6Default[2]);
|
||||
}else{
|
||||
$(srcIp).val(srcIpV6Default[2]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(srcIp).val(),srcIpV4Default) > -1
|
||||
|| $.inArray($(srcIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(srcIp).val(),srcIpV6Default) > -1
|
||||
|| $.inArray($(srcIp).val(),destIpV6Default) > -1){
|
||||
if(ipPattern==1){
|
||||
$(srcIp).val(srcIpV6Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(srcIp).val(srcIpV6Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(srcIp).val(srcIpV6Default[2]);
|
||||
}else{
|
||||
$(srcIp).val(srcIpV6Default[2]);
|
||||
}
|
||||
}
|
||||
}
|
||||
if(!$(destIp).val()){
|
||||
if(ipPattern==1){
|
||||
$(destIp).val(srcIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(destIp).val(srcIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(destIp).val(srcIpV4Default[2]);
|
||||
}else{
|
||||
$(destIp).val(srcIpV4Default[2]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(destIp).val(),srcIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),destIpV4Default) > -1
|
||||
|| $.inArray($(destIp).val(),srcIpV6Default) > -1
|
||||
|| $.inArray($(destIp).val(),destIpV6Default) > -1){
|
||||
if(ipPattern==1){
|
||||
$(destIp).val(destIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(destIp).val(destIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(destIp).val(destIpV4Default[2]);
|
||||
}else{
|
||||
$(destIp).val(destIpV4Default[2]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if(10==ipType){
|
||||
if(!$(srcIp).val()){
|
||||
if(ipPattern==1){
|
||||
$(srcIp).val(srcIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(srcIp).val(srcIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}else{
|
||||
$(srcIp).val(srcIpV4Default[2]);
|
||||
}
|
||||
}
|
||||
if(!$(destIp).val()){
|
||||
if(ipPattern==1){
|
||||
$(destIp).val(destIpV4Default[0]);
|
||||
}else if(ipPattern==2){
|
||||
$(destIp).val(destIpV4Default[1]);
|
||||
}else if(ipPattern==3){
|
||||
$(destIp).val(destIpV4Default[2]);
|
||||
}else{
|
||||
$(destIp).val(destIpV4Default[2]);
|
||||
}
|
||||
}
|
||||
}
|
||||
//设置源端口默认值
|
||||
if(!$(srcPort).val()){
|
||||
if(portPattern==1){
|
||||
if(srcPortPattern==1){
|
||||
$(srcPort).val(portDefault[0]);
|
||||
}else if(portPattern==2){
|
||||
}else if(srcPortPattern==2){
|
||||
$(srcPort).val(portDefault[1]);
|
||||
}else{
|
||||
$(srcPort).val(portDefault[0]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(srcPort).val(),portDefault) > -1){ //是ipV4的默认值其中一个
|
||||
if(portPattern==1){
|
||||
if(srcPortPattern==1){
|
||||
$(srcPort).val(portDefault[0]);
|
||||
}else if(portPattern==2){
|
||||
}else if(srcPortPattern==2){
|
||||
$(srcPort).val(portDefault[1]);
|
||||
}else{
|
||||
$(srcPort).val(portDefault[0]);
|
||||
@@ -1289,18 +1107,18 @@ var switchIpInfo=function(obj){
|
||||
}
|
||||
//设置目的端口默认值
|
||||
if(!$(destPort).val()){
|
||||
if(portPattern==1){
|
||||
if(destPortPattern==1){
|
||||
$(destPort).val(portDefault[0]);
|
||||
}else if(portPattern==2){
|
||||
}else if(destPortPattern==2){
|
||||
$(destPort).val(portDefault[1]);
|
||||
}else{
|
||||
$(destPort).val(portDefault[0]);
|
||||
}
|
||||
}else{
|
||||
if($.inArray($(destPort).val(),portDefault) > -1){ //是port的默认值其中一个
|
||||
if(portPattern==1){
|
||||
if(destPortPattern==1){
|
||||
$(destPort).val(portDefault[0]);
|
||||
}else if(portPattern==2){
|
||||
}else if(destPortPattern==2){
|
||||
$(destPort).val(portDefault[1]);
|
||||
}else{
|
||||
$(destPort).val(portDefault[0]);
|
||||
@@ -1336,27 +1154,6 @@ var page=function(n,s){
|
||||
return false;
|
||||
}
|
||||
|
||||
//show more 添加更多属性
|
||||
var more=function(obj){
|
||||
var clickTimes=$(obj).data("click-times");
|
||||
if(clickTimes==0){
|
||||
$(".port").removeClass("hidden").removeClass("disabled");
|
||||
$(obj).data("click-times",clickTimes+1);
|
||||
}
|
||||
if(clickTimes==1){
|
||||
$(".destPort").removeClass("hidden").removeClass("disabled");
|
||||
$(obj).data("click-times",clickTimes+1);
|
||||
}
|
||||
if(clickTimes==2){
|
||||
$(".protocol").removeClass("hidden").removeClass("disabled");
|
||||
$(obj).data("click-times",clickTimes+1);
|
||||
}
|
||||
var rows=$(obj).parent(".row").siblings(".row:hidden");
|
||||
if(rows.size()==0){
|
||||
$(obj).addClass("hidden");
|
||||
}
|
||||
}
|
||||
|
||||
var viewAreaInfo=function(path,areaEffectiveIds,compileId){
|
||||
$.ajax({
|
||||
type:'post',
|
||||
@@ -1387,6 +1184,7 @@ var viewAreaInfo=function(path,areaEffectiveIds,compileId){
|
||||
html+="</tbody>";
|
||||
html+="</table>";
|
||||
}
|
||||
/*
|
||||
if(data.areaIps.length > 0){
|
||||
title=$.validator.messages.area+" ip";
|
||||
html+="<table class='table table-striped table-bordered table-condensed' style='margin-left: 10px; width: 96%;margin-top: 15px;'>";
|
||||
@@ -1432,7 +1230,7 @@ var viewAreaInfo=function(path,areaEffectiveIds,compileId){
|
||||
}
|
||||
html+="</tbody>";
|
||||
html+="</table>";
|
||||
}
|
||||
}*/
|
||||
top.$.jBox(html,{width: $(document).width()*0.4,height: 400,title:title, buttons:false});
|
||||
}
|
||||
|
||||
|
||||
@@ -9,22 +9,71 @@
|
||||
});
|
||||
$.extend($.ipcommon, {
|
||||
ipType:[],
|
||||
ipPattern:[],
|
||||
portPattern:[],
|
||||
srcIpPattern:[],
|
||||
destIpPattern:[],
|
||||
srcPortPattern:[],
|
||||
destPortPattern:[],
|
||||
protocol:[],
|
||||
direction:[]
|
||||
});
|
||||
})(jQuery);
|
||||
$(function(){
|
||||
initCommIpVal();
|
||||
//IP域修改时默认展开,不显示show more
|
||||
if($("input[name='compileId']")&&$("input[name='compileId']").val()!=0&&($(".btn-red-hollow").parents(".boxSolid").is(":visible")||$("input[name$='cfgRegionCode']").length==1)){
|
||||
$(".port").removeClass("hidden").removeClass("disabled");
|
||||
$(".destPort").removeClass("hidden").removeClass("disabled");
|
||||
$(".protocol").removeClass("hidden").removeClass("disabled");
|
||||
$(".ipCol:hidden").removeClass("hidden").removeClass("disabled");
|
||||
$(".btn-red-hollow").addClass("hidden");
|
||||
}
|
||||
});
|
||||
window.$.ipcommon=$.ipcommon;
|
||||
/**
|
||||
* 初始化格式处理
|
||||
*/
|
||||
var processPattern=function(selector,pattern){
|
||||
if("ipType"==selector){
|
||||
$.ipcommon.ipType=$("select[name$='ipType'] option");
|
||||
}else if("srcIpPattern"==selector){
|
||||
$.ipcommon.srcIpPattern=$("select[name$='srcIpPattern'] option");
|
||||
}else if("destIpPattern"==selector){
|
||||
$.ipcommon.destIpPattern=$("select[name$='destIpPattern'] option");
|
||||
}else if("srcPortPattern"==selector){
|
||||
$.ipcommon.srcPortPattern=$("select[name$='srcPortPattern'] option");
|
||||
}else if("destPortPattern"==selector){
|
||||
$.ipcommon.destPortPattern=$("select[name$='destPortPattern'] option");
|
||||
}else if("direction"==selector){
|
||||
$.ipcommon.direction=$("select[name$='direction'] option");
|
||||
}else if("protocol"==selector){
|
||||
$.ipcommon.protocol=$("select[name$='protocol'] option");
|
||||
}
|
||||
if(pattern){
|
||||
var arr=pattern.split(',');
|
||||
$("select[name$='"+selector+"'] option").each(function(){
|
||||
var has=false;
|
||||
for(var type in arr){
|
||||
if($(this).val()==arr[type]){
|
||||
has=true;
|
||||
if($(this).attr("disabled")){
|
||||
$(this).removeAttr("disabled")
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!has){
|
||||
$(this).remove();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
/**
|
||||
* ip默认选项处理
|
||||
*/
|
||||
var initCommIpVal=function(){
|
||||
var action,regionCode,serviceType,ipPortShow,ipType,
|
||||
ipPattern,portPattern,direction,protocol,regionType;
|
||||
srcIpPattern,destIpPattern,srcPortPattern,destPortPattern,
|
||||
direction,protocol,regionType;
|
||||
if($("input[name$='action']:checked").length>0){
|
||||
regionCode=$("input[name$='action']:checked").attr("regionCode");
|
||||
action=$("input[name$='action']:checked").val();
|
||||
@@ -55,16 +104,20 @@ var initCommIpVal=function(){
|
||||
if(regionCode){//IP域大于1个,根据action获取ip属性
|
||||
ipPortShow=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("ipPortShow"),
|
||||
ipType=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("ipType"),
|
||||
ipPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("ipPattern"),
|
||||
portPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("portPattern"),
|
||||
srcIpPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("srcIpPattern"),
|
||||
destIpPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("destIpPattern"),
|
||||
srcPortPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("srcPortPattern"),
|
||||
destPortPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("destPortPattern"),
|
||||
direction=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("direction"),
|
||||
protocol=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("protocol"),
|
||||
regionType=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("regionType");
|
||||
}else{//IP域只有一个,获取regionType为1的
|
||||
ipPortShow=$("input[name$='cfgRegionCode'][regionType='1']").attr("ipPortShow"),
|
||||
ipType=$("input[name$='cfgRegionCode'][regionType='1']").attr("ipType"),
|
||||
ipPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("ipPattern"),
|
||||
portPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("portPattern"),
|
||||
srcIpPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("srcIpPattern"),
|
||||
destIpPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("destIpPattern"),
|
||||
srcPortPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("srcPortPattern"),
|
||||
destPortPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("destPortPattern"),
|
||||
direction=$("input[name$='cfgRegionCode'][regionType='1']").attr("direction"),
|
||||
protocol=$("input[name$='cfgRegionCode'][regionType='1']").attr("protocol"),
|
||||
regionType=$("input[name$='cfgRegionCode'][regionType='1']").attr("regionType");
|
||||
@@ -73,124 +126,92 @@ var initCommIpVal=function(){
|
||||
if(ipPortShow){
|
||||
if(ipPortShow.indexOf('1')>-1){//展示源IP
|
||||
$("input[name$='srcIpAddress']").parents(".form-group").removeClass("hidden");
|
||||
$("select[name$='srcIpPattern']").parents(".form-group").removeClass("hidden");
|
||||
}else{
|
||||
$("input[name$='srcIpAddress']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='srcIpPattern']").parents(".form-group").addClass("hidden");
|
||||
if(!$("input[name$='srcIpAddress']").parents(".ipCol").is(":hidden")){
|
||||
$("input[name$='srcIpAddress']").parents(".ipCol").addClass("hidden");
|
||||
}
|
||||
}
|
||||
if(ipPortShow.indexOf('2')>-1){//展示源端口
|
||||
$("input[name$='srcPort']").parents(".form-group").removeClass("hidden");
|
||||
$("select[name$='srcPortPattern']").parents(".form-group").removeClass("hidden");
|
||||
}else{
|
||||
$("input[name$='srcPort']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='srcPortPattern']").parents(".form-group").addClass("hidden");
|
||||
}
|
||||
if(ipPortShow.indexOf('3')>-1){//展示目的IP
|
||||
$("input[name$='destIpAddress']").parents(".form-group").removeClass("hidden");
|
||||
$("select[name$='destIpPattern']").parents(".form-group").removeClass("hidden");
|
||||
//当源IP不展示的时候目的IP要默认展示
|
||||
if($("input[name$='destIpAddress']").parents(".ipCol")&&ipPortShow.indexOf('1')==-1){
|
||||
$("input[name$='destIpAddress']").parents(".ipCol").removeClass("hidden");
|
||||
}
|
||||
}else{
|
||||
$("input[name$='destIpAddress']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='destIpPattern']").parents(".form-group").addClass("hidden");
|
||||
}
|
||||
if(ipPortShow.indexOf('4')>-1){//展示目的端口
|
||||
$("input[name$='destPort']").parents(".form-group").removeClass("hidden");
|
||||
$("select[name$='destPortPattern']").parents(".form-group").removeClass("hidden");
|
||||
}else{
|
||||
$("input[name$='destPort']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='destPortPattern']").parents(".form-group").addClass("hidden");
|
||||
}
|
||||
}
|
||||
//ip类型处理
|
||||
$.ipcommon.ipType=$("select[name$='ipType'] option");
|
||||
if(ipType){
|
||||
var arr=ipType.split(',');
|
||||
$("select[name$='ipType'] option").each(function(){
|
||||
var has=false;
|
||||
for(var type in arr){
|
||||
if($(this).val()==arr[type]){
|
||||
has=true;
|
||||
if($(this).attr("disabled")){
|
||||
$(this).removeAttr("disabled")
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!has){
|
||||
$(this).remove();
|
||||
}
|
||||
});
|
||||
processPattern("ipType",ipType);
|
||||
}
|
||||
//ip格式处理
|
||||
$.ipcommon.ipPattern=$("select[name$='ipPattern'] option");
|
||||
if(ipPattern){
|
||||
arr=ipPattern.split(',');
|
||||
$("select[name$='ipPattern'] option").each(function(){
|
||||
var has=false;
|
||||
for(var type in arr){
|
||||
if($(this).val()==arr[type]){
|
||||
has=true;
|
||||
if($(this).attr("disabled")){
|
||||
$(this).removeAttr("disabled")
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!has){
|
||||
$(this).remove();
|
||||
}
|
||||
});
|
||||
if(srcIpPattern){
|
||||
processPattern("srcIpPattern",srcIpPattern);
|
||||
}
|
||||
//端口格式处理
|
||||
$.ipcommon.portPattern=$("select[name$='portPattern'] option");
|
||||
if(portPattern){
|
||||
arr=portPattern.split(',');
|
||||
$("select[name$='portPattern'] option").each(function(){
|
||||
var has=false;
|
||||
for(var type in arr){
|
||||
if($(this).val()==arr[type]){
|
||||
has=true;
|
||||
if($(this).attr("disabled")){
|
||||
$(this).removeAttr("disabled")
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!has){
|
||||
$(this).remove();
|
||||
}
|
||||
});
|
||||
if(destIpPattern){
|
||||
processPattern("destIpPattern",destIpPattern);
|
||||
}
|
||||
if(srcPortPattern){
|
||||
processPattern("srcPortPattern",srcPortPattern);
|
||||
}
|
||||
if(destPortPattern){
|
||||
processPattern("destPortPattern",destPortPattern);
|
||||
}
|
||||
//方向处理
|
||||
$.ipcommon.direction=$("select[name$='direction'] option");
|
||||
if(direction){
|
||||
arr=direction.split(',');
|
||||
$("select[name$='direction'] option").each(function(){
|
||||
var has=false;
|
||||
for(var type in arr){
|
||||
if($(this).val()==arr[type]){
|
||||
has=true;
|
||||
if($(this).attr("disabled")){
|
||||
$(this).removeAttr("disabled")
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!has){
|
||||
$(this).remove();
|
||||
}
|
||||
});
|
||||
processPattern("direction",direction);
|
||||
}
|
||||
//协议处理
|
||||
$.ipcommon.protocol=$("select[name$='protocol'] option");
|
||||
if(protocol){
|
||||
arr=protocol.split(',');
|
||||
$("select[name$='protocol'] option").each(function(){
|
||||
processPattern("protocol",protocol);
|
||||
}
|
||||
}
|
||||
var changePattern=function(o,selector,pattern){
|
||||
if(pattern){
|
||||
arr=pattern.split(',');
|
||||
var ipPatternVal=o.find("select[name$='"+selector+"'] option:selected").attr("value");
|
||||
o.find("select[name$='"+selector+"']").empty();
|
||||
var patterns=selector=="srcIpPattern"?$.ipcommon.srcIpPattern:
|
||||
selector=="destIpPattern"?$.ipcommon.destIpPattern:
|
||||
selector=="srcPortPattern"?$.ipcommon.srcPortPattern:
|
||||
selector=="destPortPattern"?$.ipcommon.destPortPattern:[];
|
||||
$(patterns).each(function(){
|
||||
var has=false;
|
||||
for(var type in arr){
|
||||
if($(this).val()==arr[type]){
|
||||
has=true;
|
||||
if($(this).attr("disabled")){
|
||||
$(this).removeAttr("disabled")
|
||||
}
|
||||
o.find("select[name$='"+selector+"']").append($(this));
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!has){
|
||||
$(this).remove();
|
||||
}
|
||||
});
|
||||
o.find("select[name$='"+selector+"']").selectpicker("refresh");
|
||||
if(o.find("select[name$='"+selector+"'] option[value='"+ipPatternVal+"']").length>0){
|
||||
o.find("select[name$='"+selector+"']").selectpicker("val",ipPatternVal);
|
||||
}else{
|
||||
if(o.find("select[name$='"+selector+"'] option[value=1]").length>0){
|
||||
o.find("select[name$='"+selector+"']").selectpicker("val",1);
|
||||
}else{
|
||||
o.find("select[name$='"+selector+"']").get(0).selectedIndex=0;
|
||||
o.find("select[name$='"+selector+"']").selectpicker("refresh");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
/**
|
||||
@@ -198,7 +219,7 @@ var initCommIpVal=function(){
|
||||
*/
|
||||
var changeIPVal=function(obj){
|
||||
var action,regionCode,serviceType,ipPortShow,ipType,
|
||||
ipPattern,portPattern,direction,protocol,regionType,o;
|
||||
srcIpPattern,destIpPattern,srcPortPattern,destPortPattern,direction,protocol,regionType,o;
|
||||
o=$(obj);
|
||||
if($("input[name$='action']:checked").length>0){
|
||||
regionCode=$("input[name$='action']:checked").attr("regionCode");
|
||||
@@ -230,16 +251,20 @@ var changeIPVal=function(obj){
|
||||
if(regionCode){//IP域大于1个,根据action获取ip属性
|
||||
ipPortShow=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("ipPortShow"),
|
||||
ipType=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("ipType"),
|
||||
ipPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("ipPattern"),
|
||||
portPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("portPattern"),
|
||||
srcIpPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("srcIpPattern"),
|
||||
destIpPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("destIpPattern"),
|
||||
srcPortPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("srcPortPattern"),
|
||||
destPortPattern=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("destPortPattern"),
|
||||
direction=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("direction"),
|
||||
protocol=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("protocol"),
|
||||
regionType=$("input[name$='cfgRegionCode'][value='"+regionCode+"']").attr("regionType");
|
||||
}else{//IP域只有一个,获取regionType为1的
|
||||
ipPortShow=$("input[name$='cfgRegionCode'][regionType='1']").attr("ipPortShow"),
|
||||
ipType=$("input[name$='cfgRegionCode'][regionType='1']").attr("ipType"),
|
||||
ipPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("ipPattern"),
|
||||
portPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("portPattern"),
|
||||
srcIpPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("srcIpPattern"),
|
||||
destIpPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("destIpPattern"),
|
||||
srcPortPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("srcPortPattern"),
|
||||
destPortPattern=$("input[name$='cfgRegionCode'][regionType='1']").attr("destPortPattern"),
|
||||
direction=$("input[name$='cfgRegionCode'][regionType='1']").attr("direction"),
|
||||
protocol=$("input[name$='cfgRegionCode'][regionType='1']").attr("protocol"),
|
||||
regionType=$("input[name$='cfgRegionCode'][regionType='1']").attr("regionType");
|
||||
@@ -249,23 +274,31 @@ var changeIPVal=function(obj){
|
||||
if(ipPortShow){
|
||||
if(ipPortShow.indexOf('1')>-1){//展示源IP
|
||||
$("input[name$='srcIpAddress']").parents(".form-group").removeClass("hidden");
|
||||
$("select[name$='srcIpPattern']").parents(".form-group").removeClass("hidden");
|
||||
}else{
|
||||
$("input[name$='srcIpAddress']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='srcIpPattern']").parents(".form-group").addClass("hidden");
|
||||
}
|
||||
if(ipPortShow.indexOf('2')>-1){//展示源端口
|
||||
$("input[name$='srcPort']").parents(".form-group").removeClass("hidden");
|
||||
$("select[name$='srcPortPattern']").parents(".form-group").removeClass("hidden");
|
||||
}else{
|
||||
$("input[name$='srcPort']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='srcPortPattern']").parents(".form-group").addClass("hidden");
|
||||
}
|
||||
if(ipPortShow.indexOf('3')>-1){//展示目的IP
|
||||
$("input[name$='destIpAddress']").parents(".form-group").removeClass("hidden");
|
||||
$("select[name$='destIpPattern']").parents(".form-group").removeClass("hidden");
|
||||
}else{
|
||||
$("input[name$='destIpAddress']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='destIpPattern']").parents(".form-group").addClass("hidden");
|
||||
}
|
||||
if(ipPortShow.indexOf('4')>-1){//展示目的端口
|
||||
$("input[name$='destPort']").parents(".form-group").removeClass("hidden");
|
||||
$("select[name$='destPortPattern']").parents(".form-group").removeClass("hidden");
|
||||
}else{
|
||||
$("input[name$='destPort']").parents(".form-group").addClass("hidden");
|
||||
$("select[name$='destPortPattern']").parents(".form-group").addClass("hidden");
|
||||
}
|
||||
}
|
||||
//ip类型处理
|
||||
@@ -296,60 +329,14 @@ var changeIPVal=function(obj){
|
||||
}
|
||||
|
||||
}
|
||||
//ip格式处理
|
||||
if(ipPattern){
|
||||
arr=ipPattern.split(',');
|
||||
var ipPatternVal=o.find("select[name$='ipPattern'] option:selected").attr("value");
|
||||
o.find("select[name$='ipPattern']").empty();
|
||||
$.ipcommon.ipPattern.each(function(){
|
||||
var has=false;
|
||||
for(var type in arr){
|
||||
if($(this).val()==arr[type]){
|
||||
has=true;
|
||||
o.find("select[name$='ipPattern']").append($(this));
|
||||
break;
|
||||
}
|
||||
}
|
||||
});
|
||||
o.find("select[name$='ipPattern']").selectpicker("refresh");
|
||||
if(o.find("select[name$='ipPattern'] option[value='"+ipPatternVal+"']").length>0){
|
||||
o.find("select[name$='ipPattern']").selectpicker("val",ipPatternVal);
|
||||
}else{
|
||||
if(o.find("select[name$='ipPattern'] option[value=1]").length>0){
|
||||
o.find("select[name$='ipPattern']").selectpicker("val",1);
|
||||
}else{
|
||||
o.find("select[name$='ipPattern']").get(0).selectedIndex=0;
|
||||
o.find("select[name$='ipPattern']").selectpicker("refresh");
|
||||
}
|
||||
}
|
||||
}
|
||||
//端口格式处理
|
||||
if(portPattern){
|
||||
arr=portPattern.split(',');
|
||||
var portPatternVal=o.find("select[name$='portPattern'] option:selected").attr("value");
|
||||
o.find("select[name$='portPattern']").empty();
|
||||
$.ipcommon.portPattern.each(function(){
|
||||
var has=false;
|
||||
for(var type in arr){
|
||||
if($(this).val()==arr[type]){
|
||||
has=true;
|
||||
o.find("select[name$='portPattern']").append($(this));
|
||||
break;
|
||||
}
|
||||
}
|
||||
});
|
||||
o.find("select[name$='portPattern']").selectpicker("refresh");
|
||||
if(o.find("select[name$='portPattern'] option[value='"+portPatternVal+"']").length>0){
|
||||
o.find("select[name$='portPattern']").selectpicker("val",portPatternVal);
|
||||
}else{
|
||||
if(o.find("select[name$='portPattern'] option[value=1]").length>0){
|
||||
o.find("select[name$='portPattern']").selectpicker("val",1);
|
||||
}else{
|
||||
o.find("select[name$='portPattern']").get(0).selectedIndex=0;
|
||||
o.find("select[name$='portPattern']").selectpicker("refresh");
|
||||
}
|
||||
}
|
||||
}
|
||||
//源ip格式处理
|
||||
changePattern(o,"srcIpPattern",srcIpPattern);
|
||||
//目的ip格式处理
|
||||
changePattern(o,"destIpPattern",destIpPattern);
|
||||
//源端口格式处理
|
||||
changePattern(o,"srcPortPattern",srcPortPattern);
|
||||
//目的源端口格式处理
|
||||
changePattern(o,"destPortPattern",destPortPattern);
|
||||
//方向处理
|
||||
if(direction){
|
||||
arr=direction.split(',');
|
||||
@@ -405,4 +392,42 @@ var changeIPVal=function(obj){
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
//show more 添加更多属性
|
||||
var more=function(obj){
|
||||
var moreCols=$(obj).parents(".row").siblings(".ipCol").not(":hidden").last().nextAll(":hidden");
|
||||
if(moreCols.length==0){
|
||||
var clickTimes=$(obj).data("click-times");
|
||||
if(clickTimes==0){
|
||||
$(".port").removeClass("hidden").removeClass("disabled");
|
||||
$(obj).data("click-times",clickTimes+1);
|
||||
}
|
||||
if(clickTimes==1){
|
||||
$(".destPort").removeClass("hidden").removeClass("disabled");
|
||||
$(obj).data("click-times",clickTimes+1);
|
||||
}
|
||||
if(clickTimes==2){
|
||||
$(".protocol").removeClass("hidden").removeClass("disabled");
|
||||
$(obj).data("click-times",clickTimes+1);
|
||||
}
|
||||
var rows=$(obj).parent(".row").siblings(".row:hidden");
|
||||
if(rows.size()==0){
|
||||
$(obj).addClass("hidden");
|
||||
}
|
||||
}else{
|
||||
if(moreCols.length>0){
|
||||
//$(moreCols[0]).removeClass("hidden").removeClass("disabled");
|
||||
$(moreCols).each(function(i){
|
||||
$(this).removeClass("hidden").removeClass("disabled");
|
||||
if($(this).find("form-group:hidden").length>0){
|
||||
return true;
|
||||
}else{
|
||||
return false;
|
||||
}
|
||||
});
|
||||
if($(obj).parents(".row").siblings(".ipCol").not(":hidden").last().nextAll(":hidden").length==0){
|
||||
$(obj).addClass("hidden");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user