修改拦截策略配置导入模板;修正http(s) 重定向配置导入校验
This commit is contained in:
@@ -193,7 +193,7 @@ public class ExportExcel {
|
||||
commentStr=commentStr+msgProp.getProperty(sysDataDictionaryItem.getItemValue(),sysDataDictionaryItem.getItemValue())+"\n";
|
||||
index++;
|
||||
}
|
||||
defaultValue=ratelimit.get(0).getItemCode();
|
||||
defaultValue="0.1";
|
||||
}
|
||||
commentStr=msgProp.getProperty("select")+":\n"+commentStr;
|
||||
index++;
|
||||
@@ -215,18 +215,18 @@ public class ExportExcel {
|
||||
commentStr=commentStr+sysDataDictionaryItem.getItemCode()+"("+msgProp.getProperty(sysDataDictionaryItem.getItemValue(),sysDataDictionaryItem.getItemValue())+")\n";
|
||||
index++;
|
||||
}
|
||||
//defaultValue=dict.get(0).getItemCode();
|
||||
defaultValue = "1";
|
||||
}
|
||||
commentStr=msgProp.getProperty("select")+":\n"+commentStr;
|
||||
index++;
|
||||
/*commentStr=commentStr+"\n"+msgProp.getProperty("rule_desc_tip")+":\n";
|
||||
commentStr=commentStr+"\n"+msgProp.getProperty("rule_desc_tip")+":\n";
|
||||
index++;
|
||||
if(!StringUtil.isEmpty(defaultValue)){
|
||||
//1、默认值说明
|
||||
commentStr=commentStr+"▶"+msgProp.getProperty("default_value")+":"+defaultValue+"\n";
|
||||
index++;
|
||||
index++;
|
||||
}*/
|
||||
}
|
||||
}
|
||||
/*** HTTP(s)重定向 重定向应答码 ***/
|
||||
if("redirect_response_code".equals(headerStr)){
|
||||
@@ -237,7 +237,7 @@ public class ExportExcel {
|
||||
commentStr=commentStr+sysDataDictionaryItem.getItemCode()+"("+msgProp.getProperty(sysDataDictionaryItem.getItemValue(),sysDataDictionaryItem.getItemValue())+")\n";
|
||||
index++;
|
||||
}
|
||||
defaultValue = "1";
|
||||
defaultValue = dict.get(0).getItemCode();
|
||||
}
|
||||
commentStr=msgProp.getProperty("select")+":\n"+commentStr;
|
||||
index++;
|
||||
@@ -908,8 +908,13 @@ public class ExportExcel {
|
||||
commentStr="";
|
||||
List<SysDataDictionaryItem> protocol=DictUtils.getDictList("PROTOCOL");
|
||||
if(protocol !=null && protocol.size()>0){
|
||||
// 拦截策略(限速)
|
||||
if(region.getFunctionId().equals(200) && service.getAction().equals(64)) {
|
||||
commentStr=commentStr+"0("+msgProp.getProperty("arbitrary")+")"+"\n";
|
||||
index++;
|
||||
}
|
||||
for (SysDataDictionaryItem sysDataDictionaryItem : protocol) {
|
||||
// IP拦截 监测
|
||||
// 拦截策略(监测)
|
||||
if((sysDataDictionaryItem.getItemCode().equals("17")) && (region.getFunctionId().equals(200) && service.getAction().equals(1))){
|
||||
continue;
|
||||
}
|
||||
@@ -936,7 +941,10 @@ public class ExportExcel {
|
||||
defaultValue=region.getConfigProtocol().split(",")[0];
|
||||
}
|
||||
|
||||
|
||||
// 拦截策略(限速)
|
||||
if(region.getFunctionId().equals(200) && service.getAction().equals(64)) {
|
||||
defaultValue="0";
|
||||
}
|
||||
}
|
||||
/*}*/
|
||||
}
|
||||
@@ -1263,7 +1271,11 @@ public class ExportExcel {
|
||||
commentStr=commentStr+msgProp.getProperty("rule_desc_tip")+":\n";
|
||||
index++;
|
||||
//2、默认值说明
|
||||
commentStr=commentStr+"▶"+msgProp.getProperty("default_value")+":0\n";
|
||||
if(region.getFunctionId().equals(200)) {
|
||||
commentStr=commentStr+"▶"+msgProp.getProperty("default_value")+":1\n";
|
||||
}else {
|
||||
commentStr=commentStr+"▶"+msgProp.getProperty("default_value")+":0\n";
|
||||
}
|
||||
index++;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user