Merge branch 'develop_no_common_group' of https://git.mesalab.cn/K18_NTCS_WEB/NTC.git into develop_no_common_group
This commit is contained in:
@@ -8,6 +8,7 @@ import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.apache.commons.lang3.StringEscapeUtils;
|
||||
import org.apache.shiro.SecurityUtils;
|
||||
import org.apache.shiro.authc.UsernamePasswordToken;
|
||||
import org.apache.shiro.config.IniSecurityManagerFactory;
|
||||
@@ -39,6 +40,7 @@ import com.nis.domain.configuration.PxyObjSpoofingIpPool;
|
||||
import com.nis.domain.configuration.PxyObjTrustedCaCert;
|
||||
import com.nis.domain.configuration.PxyObjTrustedCaCrl;
|
||||
import com.nis.domain.maat.MaatCfg;
|
||||
import com.nis.domain.maat.ManipulatActionParam;
|
||||
import com.nis.domain.maat.ToMaatBean;
|
||||
import com.nis.domain.maat.ToMaatResult;
|
||||
import com.nis.domain.maat.ToUpdateMaatBeanStatus;
|
||||
@@ -238,6 +240,15 @@ public class SchedulerTaskUtil {
|
||||
userRegion = userRegion.substring(0, userRegion.length()-1);
|
||||
}
|
||||
}
|
||||
// Proxy Block --xml无法描述的user_region
|
||||
if(entity.getServiceId().equals(576)) {
|
||||
ManipulatActionParam actionParam = new ManipulatActionParam();
|
||||
actionParam.setMethod("block");
|
||||
actionParam.setCode(Integer.valueOf(cfg.getUserRegion1()));
|
||||
actionParam.setMessage(!StringUtil.isBlank(cfg.getUserRegion2()) ? cfg.getUserRegion2():"");
|
||||
actionParam.setHtml_profile(Integer.valueOf(!StringUtil.isBlank(cfg.getUserRegion3()) ? cfg.getUserRegion3():"0"));
|
||||
userRegion = StringEscapeUtils.unescapeJson(BaseService.gsonToJson(actionParam));
|
||||
}
|
||||
|
||||
// Proxy Manipulate
|
||||
if(entity.getServiceId().equals(656)) {
|
||||
|
||||
@@ -12,6 +12,7 @@ import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import net.sf.json.JSONObject;
|
||||
|
||||
import org.apache.commons.lang3.StringEscapeUtils;
|
||||
import org.apache.poi.ss.formula.functions.T;
|
||||
import org.dom4j.Node;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
@@ -55,6 +56,7 @@ import com.nis.domain.maat.MaatCfg.GroupCfg;
|
||||
import com.nis.domain.maat.MaatCfg.IpCfg;
|
||||
import com.nis.domain.maat.MaatCfg.NumBoundaryCfg;
|
||||
import com.nis.domain.maat.MaatCfg.StringCfg;
|
||||
import com.nis.domain.maat.ManipulatActionParam;
|
||||
import com.nis.domain.specific.ConfigGroupInfo;
|
||||
import com.nis.domain.specific.SpecificServiceCfg;
|
||||
import com.nis.util.ConfigServiceUtil;
|
||||
@@ -461,6 +463,16 @@ public class ConfigSynchronizationService extends BaseService{
|
||||
userRegion = userRegion.substring(0, userRegion.length()-1);
|
||||
}
|
||||
}
|
||||
// Proxy Block --xml无法描述的user_region
|
||||
if(entity.getServiceId().equals(576)) {
|
||||
ManipulatActionParam actionParam = new ManipulatActionParam();
|
||||
actionParam.setMethod("block");
|
||||
actionParam.setCode(Integer.valueOf(cfg.getUserRegion1()));
|
||||
actionParam.setMessage(!StringUtil.isBlank(cfg.getUserRegion2()) ? cfg.getUserRegion2():"");
|
||||
actionParam.setHtml_profile(Integer.valueOf(!StringUtil.isBlank(cfg.getUserRegion3()) ? cfg.getUserRegion3():"0"));
|
||||
userRegion = StringEscapeUtils.unescapeJson(gsonToJson(actionParam));
|
||||
}
|
||||
|
||||
// Proxy Manipulation
|
||||
if(entity.getServiceId().equals(656)) {
|
||||
userRegion = BaseService.setUserRegionOfMantipulateCfg(cfg, userRegion);
|
||||
|
||||
@@ -1557,6 +1557,7 @@ cert_verify_fail_method=Fail Method
|
||||
ssl_ver_min=Min SSL Version
|
||||
ssl_ver_max=Max SSL Version
|
||||
ssl_ver_mirror_client=Mirror Client
|
||||
ssl_ver_allow_http2= Allow Http2
|
||||
decrypt_mirror_enable=Mirror Enable
|
||||
decrypt_mirror_mirror_profile=Mirror Profile
|
||||
exclusions=Exclusions
|
||||
|
||||
@@ -1559,6 +1559,7 @@ cert_verify_fail_method=Fail Method
|
||||
ssl_ver_min=Min SSL Version
|
||||
ssl_ver_max=Max SSL Version
|
||||
ssl_ver_mirror_client=Mirror Client
|
||||
ssl_ver_allow_http2= Allow Http2
|
||||
decrypt_mirror_enable=Mirror Enable
|
||||
decrypt_mirror_mirror_profile=Mirror Profile
|
||||
exclusions=Exclusions
|
||||
|
||||
@@ -1557,6 +1557,7 @@ cert_verify_fail_method=\u5931\u8D25\u65B9\u6CD5
|
||||
ssl_ver_min=\u6700\u5C0FSSL\u7248\u672C
|
||||
ssl_ver_max=\u6700\u5927SSL\u7248\u672C
|
||||
ssl_ver_mirror_client=\u955C\u50CF\u5BA2\u6237\u7AEF
|
||||
ssl_ver_allow_http2= \u5141\u8BB8 Http2
|
||||
decrypt_mirror_enable=\u542F\u7528\u955C\u50CF
|
||||
decrypt_mirror_mirror_profile=\u955C\u50CF\u6982\u8981
|
||||
exclusions=\u6392\u9664
|
||||
@@ -1571,7 +1572,7 @@ approach=\u63A5\u8FD1
|
||||
cert_verify=\u8BC1\u4E66\u9A8C\u8BC1
|
||||
ssl_version=SSL\u7248\u672C
|
||||
mirror_client=\u955C\u50CF\u5BA2\u6237\u7AEF
|
||||
allow_http2=Allow Http2
|
||||
allow_http2=\u5141\u8BB8 Http2
|
||||
min=\u6700\u5C0F
|
||||
max=\u6700\u5927
|
||||
decrypt_mirror=\u89E3\u5BC6\u955C\u50CF
|
||||
|
||||
@@ -12,10 +12,19 @@
|
||||
|
||||
$("#cfgFile").on('change',function(){
|
||||
$("#urlInfo").val($("#cfgFile").val());
|
||||
});
|
||||
cfgFileValidate();
|
||||
});
|
||||
|
||||
$("#cfgFrom") .validate( {
|
||||
submitHandler : function(form) {
|
||||
|
||||
var cfgFile = $("#cfgFile").val();
|
||||
if(cfgFile!=''){
|
||||
if(!cfgFileValidate()){
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
loading('onloading...');
|
||||
form.submit();
|
||||
},
|
||||
@@ -26,6 +35,32 @@
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
function cfgFileValidate(){
|
||||
var flag=false; //状态,检测文件后缀用
|
||||
var arr=["exe","apk"];//使用是什么格式的后缀
|
||||
var cFile=$("#cfgFile").val();//文件的值
|
||||
//取出上传文件的扩展名
|
||||
var index=cFile.lastIndexOf(".");
|
||||
var ext = cFile.substr(index+1).toLowerCase();
|
||||
//循环比较
|
||||
for(var i=0;i<arr.length;i++)
|
||||
{
|
||||
if(ext == arr[i])
|
||||
{
|
||||
flag = true; //一旦找到合适的,立即退出循环
|
||||
break;
|
||||
}
|
||||
}
|
||||
//条件判断
|
||||
$("div[for='urlInfo']").empty();
|
||||
if(!flag){
|
||||
// ("文件名不合法");
|
||||
$("div[for='urlInfo']").append("<label id='level-error' class='error'><spring:message code='file_in_wrong_format'/></label>");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -12,10 +12,22 @@
|
||||
|
||||
$("#cfgFile").on('change',function(){
|
||||
$("#urlInfo").val($("#cfgFile").val());
|
||||
cfgFileValidate();
|
||||
});
|
||||
$("#format").on('change',function(){
|
||||
cfgFileValidate();
|
||||
});
|
||||
|
||||
$("#cfgFrom") .validate( {
|
||||
submitHandler : function(form) {
|
||||
|
||||
var cfgFile = $("#cfgFile").val();
|
||||
if(cfgFile!=''){
|
||||
if(!cfgFileValidate()){
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
loading('onloading...');
|
||||
form.submit();
|
||||
},
|
||||
@@ -26,6 +38,31 @@
|
||||
});
|
||||
|
||||
});
|
||||
function cfgFileValidate(){
|
||||
var flag=false; //状态,检测文件后缀用
|
||||
var arr=["js","css"];//使用是什么格式的后缀
|
||||
var cFile=$("#cfgFile").val();//文件的值
|
||||
//取出上传文件的扩展名
|
||||
var index=cFile.lastIndexOf(".");
|
||||
var ext = cFile.substr(index+1).toLowerCase();
|
||||
//循环比较
|
||||
for(var i=0;i<arr.length;i++)
|
||||
{
|
||||
if(ext == arr[i] && (ext == $("#format").val() || $("#format").val() ==""))
|
||||
{
|
||||
flag = true; //一旦找到合适的,立即退出循环
|
||||
break;
|
||||
}
|
||||
}
|
||||
//条件判断
|
||||
$("div[for='urlInfo']").empty();
|
||||
if(!flag){
|
||||
// ("文件名不合法");
|
||||
$("div[for='urlInfo']").append("<label id='level-error' class='error'><spring:message code='file_in_wrong_format'/></label>");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
@@ -150,7 +187,7 @@
|
||||
<font color="red">*</font><spring:message code="format" />
|
||||
</label>
|
||||
<div class="col-md-6">
|
||||
<select name="format" data-live-search="true" data-live-search-placeholder="search" class="selectpicker form-control required">
|
||||
<select id="format" name="format" data-live-search="true" data-live-search-placeholder="search" class="selectpicker form-control required">
|
||||
<option value=""><spring:message code="select"/></option>
|
||||
<c:forEach items="${fns:getDictList('CONTENT_TYPE_INSERTSCRIPT')}" var="dict">
|
||||
<option value="${dict.itemCode}" <c:if test="${dict.itemCode==_cfg.format}">selected</c:if>>${dict.itemCode}</option>
|
||||
|
||||
@@ -12,10 +12,21 @@
|
||||
|
||||
$("#cfgFile").on('change',function(){
|
||||
$("#urlInfo").val($("#cfgFile").val());
|
||||
cfgFileValidate();
|
||||
});
|
||||
$("#contentType").on('change',function(){
|
||||
cfgFileValidate();
|
||||
});
|
||||
|
||||
$("#cfgFrom") .validate( {
|
||||
submitHandler : function(form) {
|
||||
|
||||
var cfgFile = $("#cfgFile").val();
|
||||
if(cfgFile!=''){
|
||||
if(!cfgFileValidate()){
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
loading('onloading...');
|
||||
form.submit();
|
||||
},
|
||||
@@ -26,6 +37,31 @@
|
||||
});
|
||||
|
||||
});
|
||||
function cfgFileValidate(){
|
||||
var flag=false; //状态,检测文件后缀用
|
||||
var arr=["template","html"];//使用是什么格式的后缀
|
||||
var cFile=$("#cfgFile").val();//文件的值
|
||||
//取出上传文件的扩展名
|
||||
var index=cFile.lastIndexOf(".");
|
||||
var ext = cFile.substr(index+1).toLowerCase();
|
||||
//循环比较
|
||||
for(var i=0;i<arr.length;i++)
|
||||
{
|
||||
if(ext == arr[i] && (ext == $("#contentType").val() || $("#contentType").val() ==""))
|
||||
{
|
||||
flag = true; //一旦找到合适的,立即退出循环
|
||||
break;
|
||||
}
|
||||
}
|
||||
//条件判断
|
||||
$("div[for='urlInfo']").empty();
|
||||
if(!flag){
|
||||
// ("文件名不合法");
|
||||
$("div[for='urlInfo']").append("<label id='level-error' class='error'><spring:message code='file_in_wrong_format'/></label>");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
@@ -151,7 +187,7 @@
|
||||
<font color="red">*</font><spring:message code="content_type" />
|
||||
</label>
|
||||
<div class="col-md-6">
|
||||
<select name="contentType" data-live-search="true" data-live-search-placeholder="search" class="selectpicker form-control required">
|
||||
<select id="contentType" name="contentType" data-live-search="true" data-live-search-placeholder="search" class="selectpicker form-control required">
|
||||
<option value=""><spring:message code="select"/></option>
|
||||
<c:forEach items="${fns:getDictList('CONTENT_TYPE_FILESTRATEGY')}" var="dict">
|
||||
<option value="${dict.itemCode}" <c:if test="${dict.itemCode==_cfg.contentType}">selected</c:if>>${dict.itemCode}</option>
|
||||
|
||||
@@ -12,10 +12,21 @@
|
||||
|
||||
$("#cfgFile").on('change',function(){
|
||||
$("#urlInfo").val($("#cfgFile").val());
|
||||
cfgFileValidate();
|
||||
});
|
||||
$("#contentType").on('change',function(){
|
||||
cfgFileValidate();
|
||||
});
|
||||
|
||||
$("#cfgFrom") .validate( {
|
||||
submitHandler : function(form) {
|
||||
|
||||
var cfgFile = $("#cfgFile").val();
|
||||
if(cfgFile!=''){
|
||||
if(!cfgFileValidate()){
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
loading('onloading...');
|
||||
form.submit();
|
||||
},
|
||||
@@ -26,6 +37,31 @@
|
||||
});
|
||||
|
||||
});
|
||||
function cfgFileValidate(){
|
||||
var flag=false; //状态,检测文件后缀用
|
||||
var arr=["template","html"];//使用是什么格式的后缀
|
||||
var cFile=$("#cfgFile").val();//文件的值
|
||||
//取出上传文件的扩展名
|
||||
var index=cFile.lastIndexOf(".");
|
||||
var ext = cFile.substr(index+1).toLowerCase();
|
||||
//循环比较
|
||||
for(var i=0;i<arr.length;i++)
|
||||
{
|
||||
if(ext == arr[i] (ext == $("#contentType").val() || $("#contentType").val() ==""))
|
||||
{
|
||||
flag = true; //一旦找到合适的,立即退出循环
|
||||
break;
|
||||
}
|
||||
}
|
||||
//条件判断
|
||||
$("div[for='urlInfo']").empty();
|
||||
if(!flag){
|
||||
// ("文件名不合法");
|
||||
$("div[for='urlInfo']").append("<label id='level-error' class='error'><spring:message code='file_in_wrong_format'/></label>");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
Reference in New Issue
Block a user