diff --git a/src/main/webapp/WEB-INF/views/cfg/av/voip/voipForm.jsp b/src/main/webapp/WEB-INF/views/cfg/av/voip/voipForm.jsp
index 154cd6886..2bf459b3a 100644
--- a/src/main/webapp/WEB-INF/views/cfg/av/voip/voipForm.jsp
+++ b/src/main/webapp/WEB-INF/views/cfg/av/voip/voipForm.jsp
@@ -211,7 +211,7 @@ var delContent=function(contentClassName,addBtnClassName){
diff --git a/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/jquery.validate.method.js b/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/jquery.validate.method.js
index 4e531aa9e..68681b24b 100644
--- a/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/jquery.validate.method.js
+++ b/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/jquery.validate.method.js
@@ -181,17 +181,23 @@ jQuery.validator.addMethod("ipCheck",function(value, element) {
var ipPattern=$(element).parents(".row").parent(".row").find("select[name$='ipPattern']").val();
var srcIpAddress=$(element).parents(".row").parent(".row").find("input[name$='srcIpAddress']").val();
var destIpAddress=$(element).parents(".row").parent(".row").find("input[name$='destIpAddress']").val();
+ var srcIpIsHidden=$(element).parents(".row").parent(".row").find("input[name$='srcIpAddress']").is(":hidden");
var destIpIsHidden=$(element).parents(".row").parent(".row").find("input[name$='destIpAddress']").is(":hidden");
if(ipPattern==1){//ip/掩码格式
srcIpAddress=srcIpAddress.indexOf("/") >-1 ?srcIpAddress.split("/")[0] : srcIpAddress;
- destIpAddress=destIpAddress.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 ?srcIpAddress.split("-")[0] : srcIpAddress;
+ destIpAddress=destIpAddress.indexOf("-") >-1 ?destIpAddress.split("-")[0] : destIpAddress;
}
- if(destIpIsHidden){
+ if(srcIpIsHidden){
if((srcIpAddress == destIpAddress)){
- $.validator.messages.ipCheck=$.validator.messages.srcIpIsNotValue+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{
diff --git a/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_en.js b/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_en.js
index a77235439..0bdc04959 100644
--- a/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_en.js
+++ b/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_en.js
@@ -31,6 +31,7 @@
destIpNotEqDestIp:" and destination IP ",
IpNotEqDestIp:" can't the same",
srcIpIsNotValue:"Sourse IP can't be ",
+ destIpIsNotValue:"Destination IP can't be ",
ipRange:"Wrong IP format or start IP and end IP in two subnet",
ipRange1:"start IP should smaller than end IP",
portCheck:"Please enter a correct port",
diff --git a/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_ru.js b/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_ru.js
index c43d39468..ba63d23c4 100644
--- a/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_ru.js
+++ b/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_ru.js
@@ -34,6 +34,7 @@
srcIpNotEqDestIp:"Sourse IP ",
destIpNotEqDestIp:" and destination IP ",
srcIpIsNotValue:"Sourse IP can't be ",
+ destIpIsNotValue:"Destination IP can't be ",
IpNotEqDestIp:" can't the same",
portMaskRange:"Port and mask must between 0 and 65535.The correct pattern is \"port/mask\".",
chooseAreaOrIsp:"The region and the oprater must choose one",
diff --git a/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_zh.js b/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_zh.js
index 6f9bc8c28..987811a3c 100644
--- a/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_zh.js
+++ b/src/main/webapp/static/global/plugins/jquery-validation/1.11.0/localization/messages_zh.js
@@ -34,6 +34,7 @@
ipRange1:"起始IP值应小于结束IP值",
portRange:"端口应小于65536,非0数字不能以0开头",
srcIpIsNotValue:"源IP不能为 ",
+ destIpIsNotValue:"目的IP不能为",
srcIpNotEqDestIp:"源IP ",
destIpNotEqDestIp:" 与目的IP ",
IpNotEqDestIp:" 不能相同",