(1)域名页面keyword字段说明改为域名
(2)加入域名验证方法domainCheck,目前没有对现在已经存在的顶级域名进行校验,主要是顶级域名较多,枚举起来困难。
This commit is contained in:
@@ -153,9 +153,9 @@
|
||||
<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="key_word"/></label>
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="domain_name"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required" type="text" name="cfgKeywords" value="${_cfg.cfgKeywords}">
|
||||
<input class="form-control required url" type="text" name="cfgKeywords" value="${_cfg.cfgKeywords}">
|
||||
</div>
|
||||
<div for="cfgKeywords"></div>
|
||||
</div>
|
||||
|
||||
@@ -203,7 +203,7 @@
|
||||
<th><input type="checkbox" class="i-checks" id="checkAll"></th>
|
||||
<%-- <th><spring:message code="seq"/></th> --%>
|
||||
<th><spring:message code="config_describe"/></th>
|
||||
<th><spring:message code="key_word"/></th>
|
||||
<th><spring:message code="domain_name"/></th>
|
||||
<th><spring:message code="block_type"/></th>
|
||||
<th><spring:message code="expression_type"/></th>
|
||||
<th><spring:message code="match_method"/></th>
|
||||
|
||||
@@ -124,9 +124,9 @@ $(function(){
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="key_word"/></label>
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="domain_name"/></label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control required" type="text" name="cfgKeywords" value="${_cfg.cfgKeywords}">
|
||||
<input class="form-control required domainCheck" type="text" name="cfgKeywords" value="${_cfg.cfgKeywords}">
|
||||
</div>
|
||||
<div for="cfgKeywords"></div>
|
||||
</div>
|
||||
|
||||
@@ -199,7 +199,7 @@
|
||||
<th><input type="checkbox" class="i-checks" id="checkAll"></th>
|
||||
<%-- <th><spring:message code="seq"/></th> --%>
|
||||
<th><spring:message code="config_describe"/></th>
|
||||
<th><spring:message code="key_word"/></th>
|
||||
<th><spring:message code="domain_name"/></th>
|
||||
<th><spring:message code="block_type"/></th>
|
||||
<th><spring:message code="valid_identifier"/></th>
|
||||
<th><spring:message code="is_audit"/></th>
|
||||
|
||||
@@ -165,6 +165,13 @@ jQuery.validator.addMethod("notStartZero",function(value, element) {
|
||||
}
|
||||
return true;
|
||||
}, "请填写正确的数值");
|
||||
jQuery.validator.addMethod("domainCheck",function(value, element) {
|
||||
var regexp=/^(?=^.{3,255}$)[a-zA-Z0-9][-a-zA-Z0-9]{0,62}(\.[a-zA-Z0-9][-a-zA-Z0-9]{0,62})+$/;
|
||||
if(this.optional(element)||regexp.test(value)){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
});
|
||||
|
||||
//ip地址校验
|
||||
jQuery.validator.addMethod("ipCheck",function(value, element) {
|
||||
|
||||
@@ -49,6 +49,7 @@
|
||||
ip_subnet: "Subnet",
|
||||
ip_range: "ip Range",
|
||||
timeout:"timeout",
|
||||
areaIpPrefix:"Forbiden value: "
|
||||
areaIpPrefix:"Forbiden value: ",
|
||||
domainCheck:"Please enter a valid domain."
|
||||
});
|
||||
}(jQuery));
|
||||
|
||||
@@ -47,6 +47,7 @@
|
||||
ip_subnet: "Subnet",
|
||||
ip_range: "ip Range",
|
||||
timeout:"timeout",
|
||||
areaIpPrefix:"Forbiden value: "
|
||||
areaIpPrefix:"Forbiden value: ",
|
||||
domainCheck:"Please enter a valid domain."
|
||||
});
|
||||
}(jQuery));
|
||||
@@ -51,6 +51,7 @@
|
||||
ip_subnet: "Subnet",
|
||||
ip_range: "ip Range",
|
||||
timeout:"超时",
|
||||
areaIpPrefix:"禁止使用的值: "
|
||||
areaIpPrefix:"禁止使用的值: ",
|
||||
domainCheck:"请输入有效的域名"
|
||||
});
|
||||
}(jQuery));
|
||||
|
||||
Reference in New Issue
Block a user