修改ip通用类界面ipInfo默认值切换bug
去除common.js中switchIpInfo方法的无用参数
This commit is contained in:
@@ -2,20 +2,22 @@
|
||||
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
||||
<h3 class="form-section"><spring:message code="block_config"/></h3>
|
||||
<div class="row">
|
||||
<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">
|
||||
<option value="4" <c:if test="${_cfg.ipType==4 || _cfg.ipType==null }">selected</c:if> >V4</option>
|
||||
<option value="6" <c:if test="${_cfg.ipType==6}">selected</c:if>>V6</option>
|
||||
<c:forEach items="${fns:getDictList('IP_TYPE')}" var="ipTypeC">
|
||||
<option value="${ipTypeC.itemCode}" <c:if test="${_cfg.ipType==ipTypeC.itemCode}">selected</c:if>>${ipTypeC.itemValue}</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
</div>
|
||||
<div for="ipType"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</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>
|
||||
@@ -38,15 +40,15 @@
|
||||
<div for="srcIpAddress"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<c:choose>
|
||||
</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>
|
||||
</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="port_pattern"/></label>
|
||||
@@ -68,15 +70,15 @@
|
||||
<div for="srcPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<c:choose>
|
||||
</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>
|
||||
</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="server_ip"/></label>
|
||||
@@ -95,15 +97,15 @@
|
||||
<div for="destPort"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<c:choose>
|
||||
</div>
|
||||
<c:choose>
|
||||
<c:when test="${_cfg.cfgId==null}">
|
||||
<div class="row hidden protocol">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<div class="row protocol">
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</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="protocol"/></label>
|
||||
@@ -133,12 +135,14 @@
|
||||
<div for="direction"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<c:if test="${_cfg.cfgId==null}">
|
||||
</div>
|
||||
<c:if test="${_cfg.cfgId==null}">
|
||||
<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>
|
||||
</c:if>
|
||||
</div>
|
||||
|
||||
<%-- <c:choose>
|
||||
<c:when test="${action==5}">
|
||||
<input type="hidden" name="protocol" value="0">
|
||||
|
||||
@@ -32,12 +32,12 @@ $(function(){
|
||||
$(this).selectpicker("refresh");
|
||||
});
|
||||
obj.removeClass("hidden");
|
||||
switchIpInfo(obj.find("select[name$='ipType']"),"ipType");
|
||||
switchIpInfo(obj.find("select[name$='ipType']"));
|
||||
obj.find("select[name$='ipType']").on("change",function(){
|
||||
switchIpInfo($(this),"ipType");
|
||||
switchIpInfo($(this));
|
||||
});
|
||||
obj.find("select[name$='ipPattern']").on("change",function(){
|
||||
switchIpInfo($(this),"ipPattern");
|
||||
switchIpInfo($(this));
|
||||
});
|
||||
obj.appendTo("#areaIp");
|
||||
$("#areaIsp").find(".container-fluid").each(function(){
|
||||
@@ -175,7 +175,7 @@ var switchIpType=function(obj){
|
||||
}
|
||||
}
|
||||
//ipType、ipPattern、portPattern选项变化时调用此方法,添加默认值
|
||||
var switchIpInfo=function(obj,type){
|
||||
var switchIpInfo=function(obj){
|
||||
var ipType="";
|
||||
var ipPattern="";
|
||||
var portPattern="";
|
||||
|
||||
Reference in New Issue
Block a user