diff --git a/src/main/webapp/WEB-INF/include/form/areaInfo.jsp b/src/main/webapp/WEB-INF/include/form/areaInfo.jsp index 767a0e72b..6579a4311 100644 --- a/src/main/webapp/WEB-INF/include/form/areaInfo.jsp +++ b/src/main/webapp/WEB-INF/include/form/areaInfo.jsp @@ -12,12 +12,12 @@ $(function(){
diff --git a/src/main/webapp/WEB-INF/views/cfg/iplist/form.jsp b/src/main/webapp/WEB-INF/views/cfg/iplist/form.jsp index cb22e6e69..01ceb91c8 100644 --- a/src/main/webapp/WEB-INF/views/cfg/iplist/form.jsp +++ b/src/main/webapp/WEB-INF/views/cfg/iplist/form.jsp @@ -21,6 +21,11 @@ $(function(){ if($(this).val()==0x20||$(this).val()==0x60){ $("#cfgRegionCode").val($("#cfgRegionCodeCallback").val()); $("#cfgType").val($("#cfgTypeCallback").val()); + $("input[name='isAreaEffective']").each(function(){ + if($(this).val()==0){ + $(this).click(); + } + }) }else{ $("#cfgRegionCode").val($("#cfgRegionCodeMaat").val()); $("#cfgType").val($("#cfgTypeMaat").val()); 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 e6434a544..867a2d7b8 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 @@ -323,6 +323,15 @@ jQuery.validator.addMethod("chooseAreaOrIsp",function(value, element) { return true; }); +jQuery.validator.addMethod("areaControl",function(value, element) { + var action=$(element).closest(".row").siblings(".row").find("input[name$=action]:radio:checked").val(); + if((action==0x20||action==0x60)&&value==1){ + $.validator.messages.areaControl=$.validator.messages.areaControl + return false; + }else{ + return true; + } +}); //ip v4转数字 var ipToNumber=function (ip){ var num =0; 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 db1b3602b..7d141e30e 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 @@ -33,6 +33,7 @@ notStartZero:"Please enter a valid Integer", portRange:"Please enter a valid Integer", portMaskRange:"Port must be a valid Integer and mask must between 0 and 65535.The correct pattern is \"port/mask\".", - chooseAreaOrIsp:"The region and the oprater must choose one" + chooseAreaOrIsp:"The region and the oprater must choose one", + areaControl:"Action drop and loop do not need area control" }); }(jQuery)); 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 e14e428f8..1ed702cda 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 @@ -31,6 +31,7 @@ portCheck: " Пожалуйста, введите  правильный  порт.", portRange:"Please enter a valid Integer", portMaskRange:"Port must be a valid Integer and mask must between 0 and 65535.The correct pattern is \"port/mask\".", - chooseAreaOrIsp:"The region and the oprater must choose one" + chooseAreaOrIsp:"The region and the oprater must choose one", + areaControl:"Action drop and loop do not need area control" }); }(jQuery)); \ No newline at end of file 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 3e5da1b0b..2362d4560 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:"端口必须为整数,非0数字不能以0开头", portMaskRange:"端口必须为整数,掩码范围0-65535,非0数字不能以0开头。格式为\"端口/掩码\"", - chooseAreaOrIsp:"区域和运营商必选一个" + chooseAreaOrIsp:"区域和运营商必选一个", + areaControl:"丢弃和回流动作不能区域管控" }); }(jQuery));