业务配置增加勾选导出

This commit is contained in:
leijun
2018-12-17 03:30:34 +08:00
parent bb2c6b8201
commit 94eb5991af
39 changed files with 738 additions and 440 deletions

View File

@@ -34,7 +34,21 @@ public class DnsResStrategy extends BaseCfg<DnsResStrategy> {
private String miTtlmax; private String miTtlmax;
//仅作导入使用 //仅作导入使用
private String ttl; private String ttl;
@ExcelField(title="policy_number",sort=0)
private String dnsId;
public String getDnsId() {
return dnsId;
}
public void setDnsId(String dnsId) {
this.dnsId = dnsId;
}
public String getTtl() { public String getTtl() {
return ttl; return ttl;
} }

View File

@@ -1617,20 +1617,20 @@ public class AppCfgController extends BaseController {
Map<String, Class<?>> classMap=new HashMap<String, Class<?>>(); Map<String, Class<?>> classMap=new HashMap<String, Class<?>>();
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录 List<AppPolicyCfg> ipLists=new ArrayList<AppPolicyCfg>();
* if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=appCfgService.findAppByPolicyList(ids);
}else{
entity.setTableName(IpPortCfg.getTablename());
Page<AppPolicyCfg> pageInfo=new Page<AppPolicyCfg>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppPolicyCfg> page = appCfgService.findAppPolicyList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/ for(AppPolicyCfg policy:ipLists){
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<AppPolicyCfg> pageInfo=new Page<AppPolicyCfg>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppPolicyCfg> page = appCfgService.findAppPolicyList(pageInfo, entity);
for(AppPolicyCfg policy:page.getList()){
SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(policy.getSpecServiceId()); SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(policy.getSpecServiceId());
if(app!=null) { if(app!=null) {
policy.setSocialName(app.getSpecServiceName()); policy.setSocialName(app.getSpecServiceName());
@@ -1648,7 +1648,7 @@ public class AppCfgController extends BaseController {
second.setIsLeaf(1); second.setIsLeaf(1);
List<SpecificServiceCfg> secondList=specificServiceCfgService.findAllSpecificServiceCfg(second, null); List<SpecificServiceCfg> secondList=specificServiceCfgService.findAllSpecificServiceCfg(second, null);
//遍历,找到匹配项后将行为设置进去 //遍历,找到匹配项后将行为设置进去
for(AppPolicyCfg policy:page.getList()){ for(AppPolicyCfg policy:ipLists){
if(policy.getBehavCode()==null) continue; if(policy.getBehavCode()==null) continue;
for(SpecificServiceCfg secondCfg:secondList) { for(SpecificServiceCfg secondCfg:secondList) {
if(secondCfg.getSpecServiceCode()==null) continue; if(secondCfg.getSpecServiceCode()==null) continue;
@@ -1678,13 +1678,13 @@ public class AppCfgController extends BaseController {
noExportMap.put("NTC_SUBSCRIBE_ID", subscribeInfoNoExport); noExportMap.put("NTC_SUBSCRIBE_ID", subscribeInfoNoExport);
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
for (AppPolicyCfg cfg : page.getList()) { for (AppPolicyCfg cfg : ipLists) {
AppPolicyCfg cfgIndexInfo=appCfgService.exportIpInfo(cfg); AppPolicyCfg cfgIndexInfo=appCfgService.exportIpInfo(cfg);
ipList.addAll(cfgIndexInfo.getIpPortList()); ipList.addAll(cfgIndexInfo.getIpPortList());
subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList()); subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList());
} }
subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_IP", ipList); dataMap.put("NTC_IP", ipList);
dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList); dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList);
@@ -1707,21 +1707,21 @@ public class AppCfgController extends BaseController {
Map<String, Class<?>> classMap=new HashMap<String, Class<?>>(); Map<String, Class<?>> classMap=new HashMap<String, Class<?>>();
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录
* if(!StringUtil.isEmpty(ids)){ List<AppTopicDomainCfg> ipLists=new ArrayList<AppTopicDomainCfg>();
for(String id:ids.split(",")){ //导出选中记录
Long.parseLong(id); if(!StringUtil.isEmpty(ids)){
ipLists=appCfgService.findAppByTopicDomainList(ids);
}else{
Page<AppTopicDomainCfg> pageInfo=new Page<AppTopicDomainCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppTopicDomainCfg> page = appCfgService.findAppTopicDomainList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/ for (int i = 0; i < ipLists.size(); i++) {
//条件导出数据大于最大导出数,只导出最大导出条数 AppTopicDomainCfg appTop=ipLists.get(i);
entity.setTableName(IpPortCfg.getTablename());
Page<AppTopicDomainCfg> pageInfo=new Page<AppTopicDomainCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppTopicDomainCfg> page = appCfgService.findAppTopicDomainList(pageInfo, entity);
for (int i = 0; i < page.getList().size(); i++) {
AppTopicDomainCfg appTop=page.getList().get(i);
appTop.setIsHex(appTop.getIsHexbin()); appTop.setIsHex(appTop.getIsHexbin());
appTop.setIsCaseInsenstive(appTop.getIsHexbin()); appTop.setIsCaseInsenstive(appTop.getIsHexbin());
} }
@@ -1729,7 +1729,7 @@ public class AppCfgController extends BaseController {
classMap.put(entity.getMenuNameCode(), AppTopicDomainCfg.class); classMap.put(entity.getMenuNameCode(), AppTopicDomainCfg.class);
String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {
@@ -1750,21 +1750,20 @@ public class AppCfgController extends BaseController {
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<AppIpCfg> ipLists=new ArrayList<AppIpCfg>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=appCfgService.findAppByIpList(ids);
Long.parseLong(id); }else{
Page<AppIpCfg> pageInfo=new Page<AppIpCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppIpCfg> page = appCfgService.findAppIpList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数 for(AppIpCfg appIp:ipLists){
entity.setTableName(IpPortCfg.getTablename());
Page<AppIpCfg> pageInfo=new Page<AppIpCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppIpCfg> page = appCfgService.findAppIpList(pageInfo, entity);
for(AppIpCfg appIp:page.getList()){
SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(appIp.getSpecServiceId()); SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(appIp.getSpecServiceId());
appIp.setAppName(app.getSpecServiceName()); appIp.setAppName(app.getSpecServiceName());
} }
@@ -1772,7 +1771,7 @@ public class AppCfgController extends BaseController {
classMap.put(entity.getMenuNameCode(), AppIpCfg.class); classMap.put(entity.getMenuNameCode(), AppIpCfg.class);
String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(),ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {
@@ -1792,22 +1791,19 @@ public class AppCfgController extends BaseController {
Map<String, Class<?>> classMap=new HashMap<String, Class<?>>(); Map<String, Class<?>> classMap=new HashMap<String, Class<?>>();
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<AppHttpCfg> ipLists=new ArrayList<AppHttpCfg>();
//导出选中记录
/*//导出选中记录 if(!StringUtil.isEmpty(ids)){
* if(!StringUtil.isEmpty(ids)){ ipLists=appCfgService.findAppByHttpList(ids);
for(String id:ids.split(",")){ }else{
Long.parseLong(id); Page<AppHttpCfg> pageInfo=new Page<AppHttpCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppHttpCfg> page = appCfgService.findAppHttpList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/ for(AppHttpCfg http:ipLists){
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<AppHttpCfg> pageInfo=new Page<AppHttpCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppHttpCfg> page = appCfgService.findAppHttpList(pageInfo, entity);
for(AppHttpCfg http:page.getList()){
http.setIsHex(http.getIsHexbin()); http.setIsHex(http.getIsHexbin());
http.setIsCaseInsenstive(http.getIsHexbin()); http.setIsCaseInsenstive(http.getIsHexbin());
http.setCfgKeywords(Functions.replace(http.getCfgKeywords(), "***and***"," ")); http.setCfgKeywords(Functions.replace(http.getCfgKeywords(), "***and***"," "));
@@ -1819,7 +1815,7 @@ public class AppCfgController extends BaseController {
classMap.put(entity.getMenuNameCode(), AppHttpCfg.class); classMap.put(entity.getMenuNameCode(), AppHttpCfg.class);
String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {
@@ -1840,21 +1836,17 @@ public class AppCfgController extends BaseController {
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<AppDomainCfg> ipLists= new ArrayList<AppDomainCfg>();
/*//导出选中记录 if(!StringUtil.isEmpty(ids)){
* if(!StringUtil.isEmpty(ids)){ ipLists=appCfgService.findAppByDomainList(ids);
for(String id:ids.split(",")){ }else{
Long.parseLong(id); Page<AppDomainCfg> pageInfo=new Page<AppDomainCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppDomainCfg> page = appCfgService.findAppDomainList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids); for(AppDomainCfg domain:ipLists){
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<AppDomainCfg> pageInfo=new Page<AppDomainCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppDomainCfg> page = appCfgService.findAppDomainList(pageInfo, entity);
for(AppDomainCfg domain:page.getList()){
domain.setIsHex(domain.getIsHexbin()); domain.setIsHex(domain.getIsHexbin());
domain.setIsCaseInsenstive(domain.getIsHexbin()); domain.setIsCaseInsenstive(domain.getIsHexbin());
SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(domain.getSpecServiceId()); SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(domain.getSpecServiceId());
@@ -1865,7 +1857,7 @@ public class AppCfgController extends BaseController {
classMap.put(entity.getMenuNameCode(), AppDomainCfg.class); classMap.put(entity.getMenuNameCode(), AppDomainCfg.class);
String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {
@@ -1886,21 +1878,18 @@ public class AppCfgController extends BaseController {
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<AppSslCertCfg> ipLists= new ArrayList<AppSslCertCfg>();
/*//导出选中记录 if(!StringUtil.isEmpty(ids)){
* if(!StringUtil.isEmpty(ids)){ ipLists=appCfgService.findAppBySslList(ids);
for(String id:ids.split(",")){ }else{
Long.parseLong(id);
}
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<AppSslCertCfg> pageInfo=new Page<AppSslCertCfg>(request, response,"r"); Page<AppSslCertCfg> pageInfo=new Page<AppSslCertCfg>(request, response,"r");
pageInfo.setPageNo(1); pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE); pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppSslCertCfg> page = appCfgService.findAppSslList(pageInfo, entity); Page<AppSslCertCfg> page = appCfgService.findAppSslList(pageInfo, entity);
for(AppSslCertCfg ssl:page.getList()){ ipLists=page.getList();
}
for(AppSslCertCfg ssl:ipLists){
ssl.setIsHex(ssl.getIsHexbin()); ssl.setIsHex(ssl.getIsHexbin());
ssl.setIsCaseInsenstive(ssl.getIsHexbin()); ssl.setIsCaseInsenstive(ssl.getIsHexbin());
ssl.setCfgKeywords(Functions.replace(ssl.getCfgKeywords(), "***and***"," ")); ssl.setCfgKeywords(Functions.replace(ssl.getCfgKeywords(), "***and***"," "));
@@ -1911,7 +1900,7 @@ public class AppCfgController extends BaseController {
classMap.put(entity.getMenuNameCode(), AppSslCertCfg.class); classMap.put(entity.getMenuNameCode(), AppSslCertCfg.class);
String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",letter,whether_area_block,classification,attribute,label,do_log,block_type,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(),ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {

View File

@@ -46,6 +46,7 @@ import com.nis.domain.configuration.BaseStringCfg;
import com.nis.domain.configuration.CfgIndexInfo; import com.nis.domain.configuration.CfgIndexInfo;
import com.nis.domain.configuration.IpPortCfg; import com.nis.domain.configuration.IpPortCfg;
import com.nis.domain.configuration.NtcSubscribeIdCfg; import com.nis.domain.configuration.NtcSubscribeIdCfg;
import com.nis.domain.configuration.PxyObjTrustedCaCert;
import com.nis.domain.configuration.WebsiteDomainTopic; import com.nis.domain.configuration.WebsiteDomainTopic;
import com.nis.domain.maat.ToMaatResult; import com.nis.domain.maat.ToMaatResult;
import com.nis.domain.maat.ToMaatResult.ResponseData; import com.nis.domain.maat.ToMaatResult.ResponseData;
@@ -300,22 +301,19 @@ public class AppFeatureCfgController extends BaseController {
Map<String, Class<?>> classMap=new HashMap<String, Class<?>>(); Map<String, Class<?>> classMap=new HashMap<String, Class<?>>();
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<AppFeatureIndex> ipLists=new ArrayList<AppFeatureIndex>();
//导出选中记录
/*//导出选中记录 if(!StringUtil.isEmpty(ids)){
* if(!StringUtil.isEmpty(ids)){ ipLists=appMultiFeatureCfgService.findAppByFeatureIndexList(ids);
for(String id:ids.split(",")){ }else{
Long.parseLong(id);
}
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<AppFeatureIndex> pageInfo=new Page<AppFeatureIndex>(request, response,"r"); Page<AppFeatureIndex> pageInfo=new Page<AppFeatureIndex>(request, response,"r");
pageInfo.setPageNo(1); pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE); pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppFeatureIndex> page = appMultiFeatureCfgService.findAppFeatureIndexList(pageInfo, entity); Page<AppFeatureIndex> page = appMultiFeatureCfgService.findAppFeatureIndexList(pageInfo, entity);
for(AppFeatureIndex feature:page.getList()){ ipLists=page.getList();
}
for(AppFeatureIndex feature:ipLists){
SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(feature.getSpecServiceId()); SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(feature.getSpecServiceId());
feature.setAppName(app.getSpecServiceName()); feature.setAppName(app.getSpecServiceName());
} }
@@ -334,7 +332,7 @@ public class AppFeatureCfgController extends BaseController {
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<AppComplexFeatureCfg> keywordList=new ArrayList<AppComplexFeatureCfg>(); List<AppComplexFeatureCfg> keywordList=new ArrayList<AppComplexFeatureCfg>();
List<AppStringFeatureCfg> strList=new ArrayList<AppStringFeatureCfg>(); List<AppStringFeatureCfg> strList=new ArrayList<AppStringFeatureCfg>();
for (AppFeatureIndex cfg : page.getList()) { for (AppFeatureIndex cfg : ipLists) {
Map<String, List> maps=appMultiFeatureCfgService.exportFeature(cfg); Map<String, List> maps=appMultiFeatureCfgService.exportFeature(cfg);
if(entity.getFunctionId()!=567){ if(entity.getFunctionId()!=567){
keywordList.addAll(maps.get("APP_KEYWORDS")); keywordList.addAll(maps.get("APP_KEYWORDS"));
@@ -343,7 +341,7 @@ public class AppFeatureCfgController extends BaseController {
} }
ipList.addAll(maps.get("APP_IP_RANGE")); ipList.addAll(maps.get("APP_IP_RANGE"));
} }
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
if(entity.getFunctionId()!=564 && entity.getFunctionId()!=567 ){ if(entity.getFunctionId()!=564 && entity.getFunctionId()!=567 ){
keywordList=replaceKeyList(keywordList); keywordList=replaceKeyList(keywordList);
titleList.add("APP_IP_RANGE"); titleList.add("APP_IP_RANGE");

View File

@@ -258,20 +258,20 @@ public class BasicProtocolController extends BaseController {
Map<String, Class<?>> classMap=new HashMap<String, Class<?>>(); Map<String, Class<?>> classMap=new HashMap<String, Class<?>>();
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录
* if(!StringUtil.isEmpty(ids)){ List<AppPolicyCfg> ipLists=new ArrayList<AppPolicyCfg>();
for(String id:ids.split(",")){ //导出选中记录
Long.parseLong(id); if(!StringUtil.isEmpty(ids)){
ipLists=appCfgService.findAppByPolicyList(ids);
}else{
entity.setTableName(IpPortCfg.getTablename());
Page<AppPolicyCfg> pageInfo=new Page<AppPolicyCfg>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppPolicyCfg> page = appCfgService.findAppPolicyList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids); for(AppPolicyCfg policy:ipLists){
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<AppPolicyCfg> pageInfo=new Page<AppPolicyCfg>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppPolicyCfg> page = appCfgService.findAppPolicyList(pageInfo, entity);
for(AppPolicyCfg policy:page.getList()){
SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(policy.getSpecServiceId()); SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(policy.getSpecServiceId());
if(app!=null) { if(app!=null) {
policy.setAppName(app.getSpecServiceName()); policy.setAppName(app.getSpecServiceName());
@@ -298,13 +298,13 @@ public class BasicProtocolController extends BaseController {
noExportMap.put("NTC_SUBSCRIBE_ID", subscribeInfoNoExport); noExportMap.put("NTC_SUBSCRIBE_ID", subscribeInfoNoExport);
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
for (AppPolicyCfg cfg : page.getList()) { for (AppPolicyCfg cfg : ipLists) {
AppPolicyCfg cfgIndexInfo=appCfgService.exportIpInfo(cfg); AppPolicyCfg cfgIndexInfo=appCfgService.exportIpInfo(cfg);
ipList.addAll(cfgIndexInfo.getIpPortList()); ipList.addAll(cfgIndexInfo.getIpPortList());
subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList()); subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList());
} }
subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_IP", ipList); dataMap.put("NTC_IP", ipList);
dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList); dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList);

View File

@@ -278,20 +278,19 @@ public class EncryptedTunnelBehaviorController extends BaseController {
Map<String, Class<?>> classMap=new HashMap<String, Class<?>>(); Map<String, Class<?>> classMap=new HashMap<String, Class<?>>();
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录 List<AppPolicyCfg> ipLists=new ArrayList<AppPolicyCfg>();
* if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=appCfgService.findAppByPolicyList(ids);
}else{
entity.setTableName(IpPortCfg.getTablename());
Page<AppPolicyCfg> pageInfo=new Page<AppPolicyCfg>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppPolicyCfg> page = appCfgService.findAppPolicyList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids); for(AppPolicyCfg policy:ipLists){
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<AppPolicyCfg> pageInfo=new Page<AppPolicyCfg>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<AppPolicyCfg> page = appCfgService.findAppPolicyList(pageInfo, entity);
for(AppPolicyCfg policy:page.getList()){
SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(policy.getSpecServiceId()); SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(policy.getSpecServiceId());
if(app!=null) { if(app!=null) {
policy.setBehaviorName(app.getSpecServiceName()); policy.setBehaviorName(app.getSpecServiceName());
@@ -309,7 +308,7 @@ public class EncryptedTunnelBehaviorController extends BaseController {
second.setIsLeaf(1); second.setIsLeaf(1);
List<SpecificServiceCfg> secondList=specificServiceCfgService.findAllSpecificServiceCfg(second, null); List<SpecificServiceCfg> secondList=specificServiceCfgService.findAllSpecificServiceCfg(second, null);
//遍历,找到匹配项后将行为设置进去 //遍历,找到匹配项后将行为设置进去
for(AppPolicyCfg policy:page.getList()){ for(AppPolicyCfg policy:ipLists){
if(policy.getBehavCode()==null) continue; if(policy.getBehavCode()==null) continue;
for(SpecificServiceCfg secondCfg:secondList) { for(SpecificServiceCfg secondCfg:secondList) {
if(secondCfg.getSpecServiceCode()==null) continue; if(secondCfg.getSpecServiceCode()==null) continue;
@@ -339,13 +338,13 @@ public class EncryptedTunnelBehaviorController extends BaseController {
noExportMap.put("NTC_SUBSCRIBE_ID", subscribeInfoNoExport); noExportMap.put("NTC_SUBSCRIBE_ID", subscribeInfoNoExport);
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
for (AppPolicyCfg cfg : page.getList()) { for (AppPolicyCfg cfg : ipLists) {
AppPolicyCfg cfgIndexInfo=appCfgService.exportIpInfo(cfg); AppPolicyCfg cfgIndexInfo=appCfgService.exportIpInfo(cfg);
ipList.addAll(cfgIndexInfo.getIpPortList()); ipList.addAll(cfgIndexInfo.getIpPortList());
subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList()); subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList());
} }
subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_IP", ipList); dataMap.put("NTC_IP", ipList);
dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList); dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList);

View File

@@ -24,6 +24,7 @@ import com.nis.domain.Page;
import com.nis.domain.basics.PolicyGroupInfo; import com.nis.domain.basics.PolicyGroupInfo;
import com.nis.domain.basics.ServiceDictInfo; import com.nis.domain.basics.ServiceDictInfo;
import com.nis.domain.configuration.BaseIpCfg; import com.nis.domain.configuration.BaseIpCfg;
import com.nis.domain.configuration.CfgIndexInfo;
import com.nis.domain.configuration.DnsIpCfg; import com.nis.domain.configuration.DnsIpCfg;
import com.nis.domain.configuration.DnsResStrategy; import com.nis.domain.configuration.DnsResStrategy;
import com.nis.domain.configuration.IpPortCfg; import com.nis.domain.configuration.IpPortCfg;
@@ -212,32 +213,30 @@ public class DnsIpCfgController extends BaseController {
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录 List<DnsIpCfg> ipLists=new ArrayList<DnsIpCfg>();
* if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=dnsIpCfgService.findByPage(ids);
}else{
Page<DnsIpCfg> pageInfo=new Page<DnsIpCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<DnsIpCfg> page = dnsIpCfgService.findPage(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/ for (int i = 0; i < ipLists.size(); i++) {
//条件导出数据大于最大导出数,只导出最大导出条数 if(StringUtil.isEmpty(ipLists.get(i).getDnsStrategyName())){
entity.setTableName(IpPortCfg.getTablename());
Page<DnsIpCfg> pageInfo=new Page<DnsIpCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<DnsIpCfg> page = dnsIpCfgService.findPage(pageInfo, entity);
for (int i = 0; i < page.getList().size(); i++) {
if(StringUtil.isEmpty(page.getList().get(i).getDnsStrategyName())){
Properties msgProp = getMsgProp(); Properties msgProp = getMsgProp();
page.getList().get(i).setDnsStrategyName(msgProp.getProperty("default_group")); ipLists.get(i).setDnsStrategyName(msgProp.getProperty("default_group"));
} }
} }
model.addAttribute("page", page);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
classMap.put(entity.getMenuNameCode(), DnsIpCfg.class); classMap.put(entity.getMenuNameCode(), DnsIpCfg.class);
String cfgIndexInfoNoExport=",whether_area_block,client_ip,port_pattern,client_port,server_port,ir_type,direction,protocol,do_log,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",whether_area_block,client_ip,port_pattern,client_port,server_port,ir_type,direction,protocol,do_log,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {

View File

@@ -22,6 +22,7 @@ import org.springframework.web.servlet.mvc.support.RedirectAttributes;
import com.nis.domain.Page; import com.nis.domain.Page;
import com.nis.domain.basics.PolicyGroupInfo; import com.nis.domain.basics.PolicyGroupInfo;
import com.nis.domain.configuration.AppSslCertCfg; import com.nis.domain.configuration.AppSslCertCfg;
import com.nis.domain.configuration.CfgIndexInfo;
import com.nis.domain.configuration.DnsResStrategy; import com.nis.domain.configuration.DnsResStrategy;
import com.nis.domain.configuration.IpPortCfg; import com.nis.domain.configuration.IpPortCfg;
import com.nis.domain.specific.SpecificServiceCfg; import com.nis.domain.specific.SpecificServiceCfg;
@@ -184,29 +185,27 @@ public class DnsResStrategyController extends BaseController {
Map<String, Class<?>> classMap=new HashMap<String, Class<?>>(); Map<String, Class<?>> classMap=new HashMap<String, Class<?>>();
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<DnsResStrategy> ipLists=new ArrayList<DnsResStrategy>();
//导出选中记录
/*//导出选中记录 if(!StringUtil.isEmpty(ids)){
* if(!StringUtil.isEmpty(ids)){ ipLists=dnsResStrategyService.findByPage(ids);
for(String id:ids.split(",")){ }else{
Long.parseLong(id); Page<DnsResStrategy> pageInfo=new Page<DnsResStrategy>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<DnsResStrategy> page = dnsResStrategyService.findPage(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/ for (int i = 0; i < ipLists.size(); i++) {
//条件导出数据大于最大导出数,只导出最大导出条数 ipLists.get(i).setMiTtlmax(String.valueOf(ipLists.get(i).getMinTtl())+"-"+String.valueOf(ipLists.get(i).getMaxTtl()));
entity.setTableName(IpPortCfg.getTablename()); ipLists.get(i).setDnsId( String.valueOf(ipLists.get(i).getCfgId()));
Page<DnsResStrategy> pageInfo=new Page<DnsResStrategy>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<DnsResStrategy> page = dnsResStrategyService.findPage(pageInfo, entity);
for (int i = 0; i < page.getList().size(); i++) {
page.getList().get(i).setMiTtlmax(String.valueOf(page.getList().get(i).getMinTtl())+"-"+String.valueOf(page.getList().get(i).getMaxTtl()));
} }
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
classMap.put(entity.getMenuNameCode(), DnsResStrategy.class); classMap.put(entity.getMenuNameCode(), DnsResStrategy.class);
String cfgIndexInfoNoExport=",valid_identifier,do_log,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",cfg_id,valid_identifier,do_log,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(),ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {

View File

@@ -148,7 +148,18 @@ public class DdosCfgController extends BaseController {
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<DdosIpCfg> ipLists=new ArrayList<DdosIpCfg>();
//导出选中记录
if(!StringUtil.isEmpty(ids)){
ipLists=ddosCfgService.findByPage(ids);
}else{
entity.setTableName(IpPortCfg.getTablename());
Page<DdosIpCfg> pageInfo=new Page<DdosIpCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<DdosIpCfg> page = ddosCfgService.findPage(pageInfo, entity);
ipLists=page.getList();
}
/*//导出选中记录 /*//导出选中记录
* if(!StringUtil.isEmpty(ids)){ * if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ for(String id:ids.split(",")){
@@ -157,16 +168,12 @@ public class DdosCfgController extends BaseController {
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids); //List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/ }else{*/
//条件导出数据大于最大导出数,只导出最大导出条数 //条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<DdosIpCfg> pageInfo=new Page<DdosIpCfg>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<DdosIpCfg> page = ddosCfgService.findPage(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
classMap.put(entity.getMenuNameCode(), DdosIpCfg.class); classMap.put(entity.getMenuNameCode(), DdosIpCfg.class);
String cfgIndexInfoNoExport=",do_log,client_ip,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",do_log,client_ip,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {

View File

@@ -968,29 +968,27 @@ public class AvContentController extends BaseController {
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=ipCfgService.getByIdsList(ids);
Long.parseLong(id); }else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
if(entity.getIpPort()== null){
entity.setIpPort(new IpPortCfg());
}
if(entity.getAvContUrlCfgList()== null){
entity.setAvContUrlCfg(new AvContUrlCfg());;
}
if(entity.getNtcSubscribeIdCfg()==null){
entity.setNtcSubscribeIdCfg(new NtcSubscribeIdCfg());
}
Page<CfgIndexInfo> page = avContentCfgService.findPage(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
if(entity.getIpPort()== null){
entity.setIpPort(new IpPortCfg());
}
if(entity.getAvContUrlCfgList()== null){
entity.setAvContUrlCfg(new AvContUrlCfg());;
}
if(entity.getNtcSubscribeIdCfg()==null){
entity.setNtcSubscribeIdCfg(new NtcSubscribeIdCfg());
}
Page<CfgIndexInfo> page = avContentCfgService.findPage(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_UNIVERSAL_IP"); titleList.add("NTC_UNIVERSAL_IP");
titleList.add("NTC_STREAMING_MEDIA_URL"); titleList.add("NTC_STREAMING_MEDIA_URL");
@@ -1021,7 +1019,7 @@ public class AvContentController extends BaseController {
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
List<BaseStringCfg> streamurlList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> streamurlList=new ArrayList<BaseStringCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=avContentCfgService.exportstream(cfg); Map<String, List> maps=avContentCfgService.exportstream(cfg);
ipList.addAll(maps.get("NTC_UNIVERSAL_IP")); ipList.addAll(maps.get("NTC_UNIVERSAL_IP"));
streamurlList.addAll(maps.get("NTC_STREAMING_MEDIA_URL")); streamurlList.addAll(maps.get("NTC_STREAMING_MEDIA_URL"));
@@ -1029,7 +1027,7 @@ public class AvContentController extends BaseController {
} }
subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
streamurlList=BaseStringCfg.replaceBaseKeyList(streamurlList); streamurlList=BaseStringCfg.replaceBaseKeyList(streamurlList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_UNIVERSAL_IP", ipList); dataMap.put("NTC_UNIVERSAL_IP", ipList);
dataMap.put("NTC_STREAMING_MEDIA_URL", streamurlList); dataMap.put("NTC_STREAMING_MEDIA_URL", streamurlList);
dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList); dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList);
@@ -1054,28 +1052,28 @@ public class AvContentController extends BaseController {
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录 List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
* if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=ipCfgService.getByIdsList(ids);
}else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
if(entity.getIpPort()== null){
entity.setIpPort(new IpPortCfg());
}
if(entity.getVoipAccount()== null){
entity.setVoipAccount(new AvVoipAccountCfg());
}
if(entity.getNtcSubscribeIdCfg()==null){
entity.setNtcSubscribeIdCfg(new NtcSubscribeIdCfg());
}
Page<CfgIndexInfo> page = avContentCfgService.findPage(new Page<CfgIndexInfo>(request, response,"r"), entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
if(entity.getIpPort()== null){
entity.setIpPort(new IpPortCfg());
}
if(entity.getVoipAccount()== null){
entity.setVoipAccount(new AvVoipAccountCfg());
}
if(entity.getNtcSubscribeIdCfg()==null){
entity.setNtcSubscribeIdCfg(new NtcSubscribeIdCfg());
}
Page<CfgIndexInfo> page = avContentCfgService.findPage(new Page<CfgIndexInfo>(request, response,"r"), entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_UNIVERSAL_IP"); titleList.add("NTC_UNIVERSAL_IP");
titleList.add("NTC_VOIP_ACCOUNT"); titleList.add("NTC_VOIP_ACCOUNT");
@@ -1106,7 +1104,7 @@ public class AvContentController extends BaseController {
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
List<BaseStringCfg> countlList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> countlList=new ArrayList<BaseStringCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=avContentCfgService.exportvoip(cfg); Map<String, List> maps=avContentCfgService.exportvoip(cfg);
ipList.addAll(maps.get("NTC_UNIVERSAL_IP")); ipList.addAll(maps.get("NTC_UNIVERSAL_IP"));
countlList.addAll(maps.get("NTC_VOIP_ACCOUNT")); countlList.addAll(maps.get("NTC_VOIP_ACCOUNT"));
@@ -1114,7 +1112,7 @@ public class AvContentController extends BaseController {
} }
countlList=BaseStringCfg.replaceBaseKeyList(countlList); countlList=BaseStringCfg.replaceBaseKeyList(countlList);
subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(),ipLists);
dataMap.put("NTC_UNIVERSAL_IP", ipList); dataMap.put("NTC_UNIVERSAL_IP", ipList);
dataMap.put("NTC_VOIP_ACCOUNT", countlList); dataMap.put("NTC_VOIP_ACCOUNT", countlList);
dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList); dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList);

View File

@@ -195,19 +195,18 @@ public class BgpCfgController extends BaseController{
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录 List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
* if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=ipCfgService.getByIdsList(ids);
}else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = bgpCfgService.getBgpList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = bgpCfgService.getBgpList(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_IP"); titleList.add("NTC_IP");
titleList.add("NTC_BGP_AS"); titleList.add("NTC_BGP_AS");
@@ -236,7 +235,7 @@ public class BgpCfgController extends BaseController{
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
// List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); // List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
List<BaseStringCfg> asInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> asInfoList=new ArrayList<BaseStringCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
CfgIndexInfo cfgIndexInfo=bgpCfgService.exportbgp(cfg); CfgIndexInfo cfgIndexInfo=bgpCfgService.exportbgp(cfg);
ipList.addAll(cfgIndexInfo.getIpPortList()); ipList.addAll(cfgIndexInfo.getIpPortList());
// subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList()); // subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList());
@@ -244,7 +243,7 @@ public class BgpCfgController extends BaseController{
} }
asInfoList=BaseStringCfg.replaceBaseKeyList(asInfoList); asInfoList=BaseStringCfg.replaceBaseKeyList(asInfoList);
// subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); // subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_IP", ipList); dataMap.put("NTC_IP", ipList);
dataMap.put("NTC_BGP_AS", asInfoList); dataMap.put("NTC_BGP_AS", asInfoList);
// dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList); // dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList);

View File

@@ -617,20 +617,19 @@ public class FileTransferCfgController extends BaseController{
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=ipCfgService.getByIdsList(ids);
Long.parseLong(id); }else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = fileTransferCfgService.getFtpList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = fileTransferCfgService.getFtpList(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_UNIVERSAL_IP"); titleList.add("NTC_UNIVERSAL_IP");
titleList.add("NTC_FTP_URL"); titleList.add("NTC_FTP_URL");
@@ -665,7 +664,7 @@ public class FileTransferCfgController extends BaseController{
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
List<BaseStringCfg> ftpkeyList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> ftpkeyList=new ArrayList<BaseStringCfg>();
List<BaseStringCfg> ftpurlList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> ftpurlList=new ArrayList<BaseStringCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=fileTransferCfgService.exportftp(cfg); Map<String, List> maps=fileTransferCfgService.exportftp(cfg);
ftpkeyList.addAll(maps.get("NTC_FTP_CONTENT")); ftpkeyList.addAll(maps.get("NTC_FTP_CONTENT"));
ftpurlList.addAll(maps.get("NTC_FTP_URL")); ftpurlList.addAll(maps.get("NTC_FTP_URL"));
@@ -675,7 +674,7 @@ public class FileTransferCfgController extends BaseController{
subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
ftpkeyList=BaseStringCfg.replaceBaseKeyList(ftpkeyList); ftpkeyList=BaseStringCfg.replaceBaseKeyList(ftpkeyList);
ftpurlList=BaseStringCfg.replaceBaseKeyList(ftpurlList); ftpurlList=BaseStringCfg.replaceBaseKeyList(ftpurlList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_UNIVERSAL_IP", ipList); dataMap.put("NTC_UNIVERSAL_IP", ipList);
dataMap.put("NTC_FTP_URL", ftpurlList); dataMap.put("NTC_FTP_URL", ftpurlList);
dataMap.put("NTC_FTP_CONTENT", ftpkeyList); dataMap.put("NTC_FTP_CONTENT", ftpkeyList);
@@ -701,19 +700,19 @@ public class FileTransferCfgController extends BaseController{
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录 List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
* if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=ipCfgService.getByIdsList(ids);
}else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = fileTransferCfgService.getP2pList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = fileTransferCfgService.getP2pList(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_UNIVERSAL_IP"); titleList.add("NTC_UNIVERSAL_IP");
@@ -753,7 +752,7 @@ public class FileTransferCfgController extends BaseController{
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
List<BaseStringCfg> hashList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> hashList=new ArrayList<BaseStringCfg>();
List<BaseStringCfg> keywordList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> keywordList=new ArrayList<BaseStringCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=fileTransferCfgService.exportp2p(cfg); Map<String, List> maps=fileTransferCfgService.exportp2p(cfg);
keywordList.addAll(maps.get("NTC_P2P_KEYWORDS")); keywordList.addAll(maps.get("NTC_P2P_KEYWORDS"));
hashList.addAll(maps.get("NTC_P2P_HASH_BIN")); hashList.addAll(maps.get("NTC_P2P_HASH_BIN"));
@@ -763,7 +762,7 @@ public class FileTransferCfgController extends BaseController{
subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
keywordList=BaseStringCfg.replaceBaseKeyList(keywordList); keywordList=BaseStringCfg.replaceBaseKeyList(keywordList);
hashList=BaseStringCfg.replaceBaseKeyList(hashList); hashList=BaseStringCfg.replaceBaseKeyList(hashList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_UNIVERSAL_IP", ipList); dataMap.put("NTC_UNIVERSAL_IP", ipList);
dataMap.put("NTC_P2P_KEYWORDS", keywordList); dataMap.put("NTC_P2P_KEYWORDS", keywordList);
dataMap.put("NTC_P2P_HASH_BIN", hashList); dataMap.put("NTC_P2P_HASH_BIN", hashList);

View File

@@ -435,19 +435,18 @@ public class IpController extends BaseController{
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
/*//导出选中记录 List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
* if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=ipCfgService.getByIdsList(ids);
}else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = ipCfgService.getIpCfgList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = ipCfgService.getIpCfgList(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_IP"); titleList.add("NTC_IP");
titleList.add("asn_policy"); titleList.add("asn_policy");
@@ -465,7 +464,7 @@ public class IpController extends BaseController{
noExportMap.put("asn_policy", asnGroupInfoNoExport); noExportMap.put("asn_policy", asnGroupInfoNoExport);
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<ConfigGroupInfo> groupInfoList=new ArrayList<ConfigGroupInfo>(); List<ConfigGroupInfo> groupInfoList=new ArrayList<ConfigGroupInfo>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
CfgIndexInfo cfgIndexInfo=ipCfgService.exportIpInfo(cfg); CfgIndexInfo cfgIndexInfo=ipCfgService.exportIpInfo(cfg);
ipList.addAll(cfgIndexInfo.getIpPortList()); ipList.addAll(cfgIndexInfo.getIpPortList());
if(!StringUtil.isEmpty(cfgIndexInfo.getAsnIpGroupName())){ if(!StringUtil.isEmpty(cfgIndexInfo.getAsnIpGroupName())){
@@ -475,7 +474,7 @@ public class IpController extends BaseController{
groupInfoList.add(group); groupInfoList.add(group);
} }
} }
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_IP", ipList); dataMap.put("NTC_IP", ipList);
dataMap.put("asn_policy", groupInfoList); dataMap.put("asn_policy", groupInfoList);

View File

@@ -234,20 +234,19 @@ public class MailCfgController extends BaseController{
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=ipCfgService.getByIdsList(ids);
Long.parseLong(id); }else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = mailCfgService.getMailList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = mailCfgService.getMailList(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
String cfgIndexInfoNoExport=",policy_name,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",policy_name,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
String ipPortInfoNoExport=",do_log,action,config_describe,valid_identifier,is_audit,creator,creator" String ipPortInfoNoExport=",do_log,action,config_describe,valid_identifier,is_audit,creator,creator"
@@ -287,7 +286,7 @@ public class MailCfgController extends BaseController{
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
List<ComplexkeywordCfg> mailBodyList=new ArrayList<ComplexkeywordCfg>(); List<ComplexkeywordCfg> mailBodyList=new ArrayList<ComplexkeywordCfg>();
List<ComplexkeywordCfg> mailReqHdrList=new ArrayList<ComplexkeywordCfg>(); List<ComplexkeywordCfg> mailReqHdrList=new ArrayList<ComplexkeywordCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=mailCfgService.exportmail(cfg); Map<String, List> maps=mailCfgService.exportmail(cfg);
mailReqHdrList.addAll(maps.get("NTC_MAIL_HDR")); mailReqHdrList.addAll(maps.get("NTC_MAIL_HDR"));
mailBodyList.addAll(maps.get("NTC_MAIL_BODY")); mailBodyList.addAll(maps.get("NTC_MAIL_BODY"));
@@ -304,7 +303,7 @@ public class MailCfgController extends BaseController{
} }
} }
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_MAIL_HDR", mailReqHdrList); dataMap.put("NTC_MAIL_HDR", mailReqHdrList);
dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList); dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList);
/*}*/ /*}*/

View File

@@ -638,18 +638,19 @@ public class WebsiteController extends BaseController{
List<FunctionRegionDict> regionList = DictUtils.getFunctionRegionDictList(entity.getFunctionId()); List<FunctionRegionDict> regionList = DictUtils.getFunctionRegionDictList(entity.getFunctionId());
/*//导出选中记录 List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=ipCfgService.getByIdsList(ids);
}else{
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = httpRedirectCfgService.getHttpRedirectList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数 //条件导出数据大于最大导出数,只导出最大导出条数
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = httpRedirectCfgService.getHttpRedirectList(pageInfo, entity);
String cfgIndexInfoNoExport=",policy_name,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",policy_name,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
String httpUrlCfgNoExport=",do_log,action,config_describe,valid_identifier,is_audit,creator,creator" String httpUrlCfgNoExport=",do_log,action,config_describe,valid_identifier,is_audit,creator,creator"
+ ",config_time,editor,edit_time,auditor,audit_time" + ",config_time,editor,edit_time,auditor,audit_time"
@@ -686,7 +687,7 @@ public class WebsiteController extends BaseController{
List<BaseStringCfg> httpResBodyList = new ArrayList<>(); List<BaseStringCfg> httpResBodyList = new ArrayList<>();
List<IpPortCfg> ipPortList = new ArrayList<>(); List<IpPortCfg> ipPortList = new ArrayList<>();
List<BaseStringCfg> subscribeIdList = new ArrayList<>(); List<BaseStringCfg> subscribeIdList = new ArrayList<>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=websiteCfgService.exportHttpCfg(cfg); Map<String, List> maps=websiteCfgService.exportHttpCfg(cfg);
httpUrlList.addAll(maps.get("NTC_HTTP_URL")); httpUrlList.addAll(maps.get("NTC_HTTP_URL"));
httpReqHdrList.addAll(maps.get("NTC_HTTP_REQ_HDR")); httpReqHdrList.addAll(maps.get("NTC_HTTP_REQ_HDR"));
@@ -705,7 +706,7 @@ public class WebsiteController extends BaseController{
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
classMap.put(entity.getMenuNameCode(), CfgIndexInfo.class); classMap.put(entity.getMenuNameCode(), CfgIndexInfo.class);
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(),ipLists);
if(entity.getFunctionId()!=635){ if(entity.getFunctionId()!=635){
titleList.add("NTC_HTTP_URL"); titleList.add("NTC_HTTP_URL");
@@ -759,36 +760,35 @@ public class WebsiteController extends BaseController{
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=ipCfgService.getByIdsList(ids);
Long.parseLong(id); }else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = websiteCfgService.getWebsiteList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/ for (int i = 0; i < ipLists.size(); i++) {
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = websiteCfgService.getWebsiteList(pageInfo, entity);
for (int i = 0; i < page.getList().size(); i++) {
Properties msgProp = getMsgProp(); Properties msgProp = getMsgProp();
if(page.getList().get(i).getDnsStrategyId()!=null && page.getList().get(i).getDnsStrategyId()!=0){ if(ipLists.get(i).getDnsStrategyId()!=null && ipLists.get(i).getDnsStrategyId()!=0){
List<DnsResStrategy> resStrategys=dnsResStrategyService.findDnsResStrategys(page.getList().get(i).getDnsStrategyId(), 1,1); List<DnsResStrategy> resStrategys=dnsResStrategyService.findDnsResStrategys(ipLists.get(i).getDnsStrategyId(), 1,1);
if(resStrategys!=null && resStrategys.size()>0){ if(resStrategys!=null && resStrategys.size()>0){
String msg= msgProp.getProperty(resStrategys.get(0).getCfgDesc()); String msg= msgProp.getProperty(resStrategys.get(0).getCfgDesc());
if(!StringUtil.isEmpty(msg)){ if(!StringUtil.isEmpty(msg)){
page.getList().get(i).setDnsStrategyName(msg); ipLists.get(i).setDnsStrategyName(msg);
}else{ }else{
page.getList().get(i).setDnsStrategyName(resStrategys.get(0).getCfgDesc()); ipLists.get(i).setDnsStrategyName(resStrategys.get(0).getCfgDesc());
} }
}else{ }else{
page.getList().get(i).setDnsStrategyName(msgProp.getProperty("no_strategy")); ipLists.get(i).setDnsStrategyName(msgProp.getProperty("no_strategy"));
} }
}else{ }else{
page.getList().get(i).setDnsStrategyName(msgProp.getProperty("no_strategy")); ipLists.get(i).setDnsStrategyName(msgProp.getProperty("no_strategy"));
} }
} }
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
@@ -819,7 +819,7 @@ public class WebsiteController extends BaseController{
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeInfoList=new ArrayList<BaseStringCfg>();
List<ComplexkeywordCfg> regionInfoList=new ArrayList<ComplexkeywordCfg>(); List<ComplexkeywordCfg> regionInfoList=new ArrayList<ComplexkeywordCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
CfgIndexInfo cfgIndexInfo=websiteCfgService.exportdns(cfg); CfgIndexInfo cfgIndexInfo=websiteCfgService.exportdns(cfg);
ipList.addAll(cfgIndexInfo.getIpPortList()); ipList.addAll(cfgIndexInfo.getIpPortList());
subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList()); subscribeInfoList.addAll(cfgIndexInfo.getNtcSubscribeIdCfgList());
@@ -827,7 +827,7 @@ public class WebsiteController extends BaseController{
} }
subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList); subscribeInfoList=BaseStringCfg.baseHexList(subscribeInfoList);
regionInfoList=ComplexkeywordCfg.replaceComplexKeyList(regionInfoList); regionInfoList=ComplexkeywordCfg.replaceComplexKeyList(regionInfoList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(),ipLists);
dataMap.put("NTC_IP", ipList); dataMap.put("NTC_IP", ipList);
dataMap.put("NTC_DNS_REGION", regionInfoList); dataMap.put("NTC_DNS_REGION", regionInfoList);
dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList); dataMap.put("NTC_SUBSCRIBE_ID", subscribeInfoList);
@@ -854,18 +854,18 @@ public class WebsiteController extends BaseController{
List<FunctionRegionDict> regionList = DictUtils.getFunctionRegionDictList(entity.getFunctionId()); List<FunctionRegionDict> regionList = DictUtils.getFunctionRegionDictList(entity.getFunctionId());
/*//导出选中记录 List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=ipCfgService.getByIdsList(ids);
}else{
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = websiteCfgService.getWebsiteList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = websiteCfgService.getWebsiteList(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_UNIVERSAL_IP"); titleList.add("NTC_UNIVERSAL_IP");
titleList.add("NTC_SSL_SNI"); titleList.add("NTC_SSL_SNI");
@@ -903,7 +903,7 @@ public class WebsiteController extends BaseController{
List<BaseStringCfg> sslCnList = new ArrayList<>(); List<BaseStringCfg> sslCnList = new ArrayList<>();
List<IpPortCfg> ipPortList = new ArrayList<>(); List<IpPortCfg> ipPortList = new ArrayList<>();
List<BaseStringCfg> subscribeIdList = new ArrayList<BaseStringCfg>(); List<BaseStringCfg> subscribeIdList = new ArrayList<BaseStringCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=websiteCfgService.exportssl(cfg); Map<String, List> maps=websiteCfgService.exportssl(cfg);
sslSniList.addAll(maps.get("NTC_SSL_SNI")); sslSniList.addAll(maps.get("NTC_SSL_SNI"));
sslSnaList.addAll(maps.get("NTC_SSL_SAN")); sslSnaList.addAll(maps.get("NTC_SSL_SAN"));
@@ -915,7 +915,7 @@ public class WebsiteController extends BaseController{
sslSnaList=BaseStringCfg.replaceBaseKeyList(sslSnaList); sslSnaList=BaseStringCfg.replaceBaseKeyList(sslSnaList);
sslCnList=BaseStringCfg.replaceBaseKeyList(sslCnList); sslCnList=BaseStringCfg.replaceBaseKeyList(sslCnList);
subscribeIdList=BaseStringCfg.baseHexList(subscribeIdList); subscribeIdList=BaseStringCfg.baseHexList(subscribeIdList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_UNIVERSAL_IP", ipPortList); dataMap.put("NTC_UNIVERSAL_IP", ipPortList);
dataMap.put("NTC_SSL_SNI", sslSniList); dataMap.put("NTC_SSL_SNI", sslSniList);
dataMap.put("NTC_SSL_SAN", sslSnaList); dataMap.put("NTC_SSL_SAN", sslSnaList);

View File

@@ -343,20 +343,18 @@ public class WhiteListController extends CommonController{
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=ipCfgService.getByIdsList(ids);
Long.parseLong(id); }else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = ipCfgService.getIpCfgList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = ipCfgService.getIpCfgList(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_IP"); titleList.add("NTC_IP");
classMap.put(entity.getMenuNameCode(), CfgIndexInfo.class); classMap.put(entity.getMenuNameCode(), CfgIndexInfo.class);
@@ -369,11 +367,11 @@ public class WhiteListController extends CommonController{
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
noExportMap.put("NTC_IP", ipPortInfoNoExport); noExportMap.put("NTC_IP", ipPortInfoNoExport);
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg :ipLists) {
CfgIndexInfo cfgIndexInfo=ipCfgService.exportIpInfo(cfg); CfgIndexInfo cfgIndexInfo=ipCfgService.exportIpInfo(cfg);
ipList.addAll(cfgIndexInfo.getIpPortList()); ipList.addAll(cfgIndexInfo.getIpPortList());
} }
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_IP", ipList); dataMap.put("NTC_IP", ipList);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
@@ -394,20 +392,19 @@ public class WhiteListController extends CommonController{
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=ipCfgService.getByIdsList(ids);
Long.parseLong(id); }else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = domainService.getDomainList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = domainService.getDomainList(pageInfo, entity);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
titleList.add("NTC_HTTP_URL"); titleList.add("NTC_HTTP_URL");
classMap.put(entity.getMenuNameCode(), CfgIndexInfo.class); classMap.put(entity.getMenuNameCode(), CfgIndexInfo.class);
@@ -420,12 +417,12 @@ public class WhiteListController extends CommonController{
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
noExportMap.put("NTC_HTTP_URL", httpUrlInfoNoExport); noExportMap.put("NTC_HTTP_URL", httpUrlInfoNoExport);
List<BaseStringCfg> httpurlList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> httpurlList=new ArrayList<BaseStringCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
CfgIndexInfo cfgIndexInfo=domainService.exportDomainInfo(cfg); CfgIndexInfo cfgIndexInfo=domainService.exportDomainInfo(cfg);
httpurlList.addAll(cfgIndexInfo.getHttpUrlList()); httpurlList.addAll(cfgIndexInfo.getHttpUrlList());
} }
httpurlList=BaseStringCfg.replaceBaseKeyList(httpurlList); httpurlList=BaseStringCfg.replaceBaseKeyList(httpurlList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_HTTP_URL", httpurlList); dataMap.put("NTC_HTTP_URL", httpurlList);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);

View File

@@ -292,21 +292,20 @@ public class HttpRedirectPolicyController extends BaseController{
List<FunctionRegionDict> regionList = DictUtils.getFunctionRegionDictList(entity.getFunctionId()); List<FunctionRegionDict> regionList = DictUtils.getFunctionRegionDictList(entity.getFunctionId());
/*//导出选中记录 List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
if(!StringUtil.isEmpty(ids)){ //导出选中记录
for(String id:ids.split(",")){ if(!StringUtil.isEmpty(ids)){
Long.parseLong(id); ipLists=ipCfgService.getByIdsList(ids);
}else{
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = httpRedirectCfgService.getHttpRedirectList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = httpRedirectCfgService.getHttpRedirectList(pageInfo, entity);
Properties prop = getMsgProp(); Properties prop = getMsgProp();
for (CfgIndexInfo str : page.getList()) { for (CfgIndexInfo str :ipLists) {
if(entity.getFunctionId()!=210 && entity.getFunctionId()!=211){ if(entity.getFunctionId()!=210 && entity.getFunctionId()!=211){
String type="RESPONSE_CODE"; String type="RESPONSE_CODE";
if(entity.getFunctionId()==207){ if(entity.getFunctionId()==207){
@@ -377,7 +376,7 @@ public class HttpRedirectPolicyController extends BaseController{
List<BaseStringCfg> httpResBodyList = new ArrayList<>(); List<BaseStringCfg> httpResBodyList = new ArrayList<>();
List<IpPortCfg> ipPortList = new ArrayList<>(); List<IpPortCfg> ipPortList = new ArrayList<>();
List<BaseStringCfg> subscribeIdList = new ArrayList<>(); List<BaseStringCfg> subscribeIdList = new ArrayList<>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=httpRedirectCfgService.exportHttpCfg(cfg); Map<String, List> maps=httpRedirectCfgService.exportHttpCfg(cfg);
httpUrlList.addAll(maps.get("NTC_HTTP_URL")); httpUrlList.addAll(maps.get("NTC_HTTP_URL"));
httpReqHdrList.addAll(maps.get("NTC_HTTP_REQ_HDR")); httpReqHdrList.addAll(maps.get("NTC_HTTP_REQ_HDR"));
@@ -402,7 +401,7 @@ public class HttpRedirectPolicyController extends BaseController{
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
noExportMap.put("NTC_HTTP_URL", httpUrlCfgNoExport); noExportMap.put("NTC_HTTP_URL", httpUrlCfgNoExport);
noExportMap.put("NTC_HTTP_REQ_HDR", httpReqHeadCfgNoExport); noExportMap.put("NTC_HTTP_REQ_HDR", httpReqHeadCfgNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
dataMap.put("NTC_HTTP_URL", httpUrlList); dataMap.put("NTC_HTTP_URL", httpUrlList);
dataMap.put("NTC_HTTP_REQ_HDR", httpReqHdrList); dataMap.put("NTC_HTTP_REQ_HDR", httpReqHdrList);
if(entity.getFunctionId()!=208 && entity.getFunctionId()!=211){ if(entity.getFunctionId()!=208 && entity.getFunctionId()!=211){

View File

@@ -241,21 +241,18 @@ public class InterceptController extends CommonController{
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
Map<String, String> replaceExportMap=new HashMap<String, String>(); Map<String, String> replaceExportMap=new HashMap<String, String>();
List<CfgIndexInfo> ipLists=new ArrayList<CfgIndexInfo>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=ipCfgService.getByIdsList(ids);
Long.parseLong(id); }else{
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = ipCfgService.getIpCfgList(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<CfgIndexInfo> pageInfo=new Page<CfgIndexInfo>(request, response,"a");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<CfgIndexInfo> page = ipCfgService.getIpCfgList(pageInfo, entity);
//获取证书信息 //获取证书信息
List<PxyObjKeyring> certificateList=new ArrayList<PxyObjKeyring>(); List<PxyObjKeyring> certificateList=new ArrayList<PxyObjKeyring>();
if(entity.getFunctionId().equals(200)){ if(entity.getFunctionId().equals(200)){
@@ -264,7 +261,7 @@ public class InterceptController extends CommonController{
if(entity.getFunctionId().equals(201)){ if(entity.getFunctionId().equals(201)){
certificateList=pxyObjKeyringService.findPxyObjKeyrings(null, 1, 1, "domain"); certificateList=pxyObjKeyringService.findPxyObjKeyrings(null, 1, 1, "domain");
} }
for (CfgIndexInfo str : page.getList()) { for (CfgIndexInfo str : ipLists) {
if(!StringUtil.isEmpty(str.getUserRegion5())){ if(!StringUtil.isEmpty(str.getUserRegion5())){
Properties prop = getMsgProp(); Properties prop = getMsgProp();
String cs= DictUtils.getDictLabel("INTERCEPT_DOMAIN_INTENSITY", str.getUserRegion5()); String cs= DictUtils.getDictLabel("INTERCEPT_DOMAIN_INTENSITY", str.getUserRegion5());
@@ -308,7 +305,7 @@ public class InterceptController extends CommonController{
List<IpPortCfg> ipList=new ArrayList<IpPortCfg>(); List<IpPortCfg> ipList=new ArrayList<IpPortCfg>();
List<BaseStringCfg> httpUrlList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> httpUrlList=new ArrayList<BaseStringCfg>();
List<BaseStringCfg> pktBinList=new ArrayList<BaseStringCfg>(); List<BaseStringCfg> pktBinList=new ArrayList<BaseStringCfg>();
for (CfgIndexInfo cfg : page.getList()) { for (CfgIndexInfo cfg : ipLists) {
Map<String, List> maps=interceptCfgService.exportIpInfo(cfg); Map<String, List> maps=interceptCfgService.exportIpInfo(cfg);
httpUrlList.addAll(maps.get("NTC_HTTP_URL")); httpUrlList.addAll(maps.get("NTC_HTTP_URL"));
ipList.addAll(maps.get("PXY_INTERCEPT_IP")); ipList.addAll(maps.get("PXY_INTERCEPT_IP"));
@@ -316,7 +313,7 @@ public class InterceptController extends CommonController{
} }
pktBinList=BaseStringCfg.replaceBaseKeyList(pktBinList); pktBinList=BaseStringCfg.replaceBaseKeyList(pktBinList);
httpUrlList=BaseStringCfg.baseHexList(httpUrlList); httpUrlList=BaseStringCfg.baseHexList(httpUrlList);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
if(entity.getFunctionId()==212){ //IP Payload if(entity.getFunctionId()==212){ //IP Payload
cfgIndexInfoNoExport=",do_log,log_total,policy_name,group_name,userregion4,userregion5,&userregion1:replace_zone-userregion2:replaced_content-userregion3:replace_content-"; cfgIndexInfoNoExport=",do_log,log_total,policy_name,group_name,userregion4,userregion5,&userregion1:replace_zone-userregion2:replaced_content-userregion3:replace_content-";
titleList.add("PXY_INTERCEPT_IP"); titleList.add("PXY_INTERCEPT_IP");

View File

@@ -39,6 +39,7 @@ import org.springframework.web.servlet.mvc.support.RedirectAttributes;
import com.google.common.collect.Maps; import com.google.common.collect.Maps;
import com.nis.domain.Page; import com.nis.domain.Page;
import com.nis.domain.basics.PolicyGroupInfo; import com.nis.domain.basics.PolicyGroupInfo;
import com.nis.domain.configuration.CfgIndexInfo;
import com.nis.domain.configuration.DnsResStrategy; import com.nis.domain.configuration.DnsResStrategy;
import com.nis.domain.configuration.IpPortCfg; import com.nis.domain.configuration.IpPortCfg;
import com.nis.domain.configuration.PxyObjKeyring; import com.nis.domain.configuration.PxyObjKeyring;
@@ -410,29 +411,27 @@ public class PxyObjKeyringController extends BaseController {
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<PxyObjKeyring> ipLists=new ArrayList<PxyObjKeyring>();
/*//导出选中记录 //导出选中记录
* if(!StringUtil.isEmpty(ids)){ if(!StringUtil.isEmpty(ids)){
for(String id:ids.split(",")){ ipLists=pxyObjKeyringService.findByList(ids);
Long.parseLong(id); }else{
entity.setTableName(IpPortCfg.getTablename());
Page<PxyObjKeyring> pageInfo=new Page<PxyObjKeyring>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<PxyObjKeyring> page = pxyObjKeyringService.findPage(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids);
}else{*/ for (int i = 0; i <ipLists.size(); i++) {
//条件导出数据大于最大导出数,只导出最大导出条数 ipLists.get(i).setKeyringName(ipLists.get(i).getCfgDesc());
entity.setTableName(IpPortCfg.getTablename());
Page<PxyObjKeyring> pageInfo=new Page<PxyObjKeyring>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<PxyObjKeyring> page = pxyObjKeyringService.findPage(pageInfo, entity);
for (int i = 0; i <page.getList().size(); i++) {
page.getList().get(i).setKeyringName(page.getList().get(i).getCfgDesc());
} }
model.addAttribute("page", page);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
classMap.put(entity.getMenuNameCode(), PxyObjKeyring.class); classMap.put(entity.getMenuNameCode(), PxyObjKeyring.class);
String cfgIndexInfoNoExport=",config_describe,whether_area_block,block_type,valid_identifier,do_log,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,"; String cfgIndexInfoNoExport=",config_describe,whether_area_block,block_type,valid_identifier,do_log,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {
@@ -452,32 +451,27 @@ public class PxyObjKeyringController extends BaseController {
Map<String, Class<?>> classMap=new HashMap<String, Class<?>>(); Map<String, Class<?>> classMap=new HashMap<String, Class<?>>();
Map<String, List> dataMap=new HashMap<String, List>(); Map<String, List> dataMap=new HashMap<String, List>();
Map<String, String> noExportMap=new HashMap<String, String>(); Map<String, String> noExportMap=new HashMap<String, String>();
List<PxyObjTrustedCaCert> ipLists=new ArrayList<PxyObjTrustedCaCert>();
//导出选中记录
/*//导出选中记录 if(!StringUtil.isEmpty(ids)){
* if(!StringUtil.isEmpty(ids)){ ipLists=pxyObjKeyringService.findByCertList(ids);
for(String id:ids.split(",")){ }else{
Long.parseLong(id); Page<PxyObjTrustedCaCert> pageInfo=new Page<PxyObjTrustedCaCert>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<PxyObjTrustedCaCert> page = pxyObjKeyringService.findTrustedCertPage(pageInfo, entity);
ipLists=page.getList();
} }
//List<CfgIndexInfo> list=ipCfgService.getListByCfgIdWithName(IpPortCfg.getTablename(), entity.getFunctionId(), ids); for (PxyObjTrustedCaCert cert:ipLists) {
}else{*/
//条件导出数据大于最大导出数,只导出最大导出条数
entity.setTableName(IpPortCfg.getTablename());
Page<PxyObjTrustedCaCert> pageInfo=new Page<PxyObjTrustedCaCert>(request, response,"r");
pageInfo.setPageNo(1);
pageInfo.setPageSize(Constants.MAX_EXPORT_SIZE);
Page<PxyObjTrustedCaCert> page = pxyObjKeyringService.findTrustedCertPage(pageInfo, entity);
for (PxyObjTrustedCaCert cert:page.getList()) {
if(!StringUtil.isEmpty(cert.getCompileId())){ if(!StringUtil.isEmpty(cert.getCompileId())){
cert.setCrlFile(ConfigDictUtils.getTrustedCrlByCerId(cert.getCompileId())); cert.setCrlFile(ConfigDictUtils.getTrustedCrlByCerId(cert.getCompileId()));
} }
} }
model.addAttribute("page", page);
titleList.add(entity.getMenuNameCode()); titleList.add(entity.getMenuNameCode());
classMap.put(entity.getMenuNameCode(), PxyObjTrustedCaCert.class); classMap.put(entity.getMenuNameCode(), PxyObjTrustedCaCert.class);
String cfgIndexInfoNoExport=",whether_area_block,block_type,valid_identifier,do_log,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,&config_describe:cert_name-"; String cfgIndexInfoNoExport=",whether_area_block,block_type,valid_identifier,do_log,client_port,ir_type,group_name,userregion1,userregion2,userregion3,userregion4,userregion5,&config_describe:cert_name-";
noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport); noExportMap.put(entity.getMenuNameCode(),cfgIndexInfoNoExport);
dataMap.put(entity.getMenuNameCode(), page.getList()); dataMap.put(entity.getMenuNameCode(), ipLists);
/*}*/ /*}*/
this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap); this._export(model, request, response, redirectAttributes,entity.getMenuNameCode(),titleList,classMap,dataMap,noExportMap);
} catch (Exception e) { } catch (Exception e) {

View File

@@ -35,8 +35,11 @@ import com.nis.web.dao.MyBatisDao;
*/ */
@MyBatisDao @MyBatisDao
public interface AppCfgDao { public interface AppCfgDao {
//app策略配置增删改查
public List<AppPolicyCfg> findAppPolicyList(AppPolicyCfg entity) ; public List<AppPolicyCfg> findAppPolicyList(AppPolicyCfg entity) ;
//app策略配置增删改查
public List<AppPolicyCfg> findAppByPolicyList(@Param("ids")String ids) ;
public AppPolicyCfg getAppPolicyCfg(@Param("cfgId")Long cfgId,@Param("compileId")Integer compileId) ; public AppPolicyCfg getAppPolicyCfg(@Param("cfgId")Long cfgId,@Param("compileId")Integer compileId) ;
public IpPortCfg getAppPolicyIpCfg(AppPolicyCfg entity) ; public IpPortCfg getAppPolicyIpCfg(AppPolicyCfg entity) ;
public List<IpPortCfg> getAppPolicyIpList(AppPolicyCfg entity); public List<IpPortCfg> getAppPolicyIpList(AppPolicyCfg entity);
@@ -106,4 +109,17 @@ public interface AppCfgDao {
// 导入配置时数据批量入库使用 // 导入配置时数据批量入库使用
public void insertAppDomainCfgBatch(AppDomainCfg cfg); public void insertAppDomainCfgBatch(AppDomainCfg cfg);
public void insertAppHttpCfgBatch(AppHttpCfg cfg); public void insertAppHttpCfgBatch(AppHttpCfg cfg);
//app 主题网站配置查
public List<AppTopicDomainCfg> findAppByTopicDomainList(@Param("ids")String ids) ;
//app协议IP配置查
public List<AppIpCfg> findAppByIpList(@Param("ids")String ids) ;
//app http特征查
public List<AppHttpCfg> findAppByHttpList(@Param("ids")String ids) ;
//app 域名配置增删改查
public List<AppDomainCfg> findAppByDomainList(@Param("ids")String ids) ;
//app ssl证书特征配置CRUD
public List<AppSslCertCfg> findAppBySslList(@Param("ids")String ids);
} }

View File

@@ -3004,4 +3004,95 @@
) )
</insert> </insert>
<select id="findAppByPolicyList" resultMap="AppPolicyCfgMap" parameterType="com.nis.domain.configuration.AppPolicyCfg" >
select
<include refid="AppPolicyCfg_Column"/>
<trim prefix="," prefixOverrides=",">
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
from app_policy_cfg r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
<!-- 主题网站列表 -->
<select id="findAppByTopicDomainList" resultMap="AppTopicDomainCfgMap">
select
<include refid="AppTopicDomainCfg_Column"/>
<trim prefix="," prefixOverrides=",">
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
from app_topic_domain_cfg r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
<select id="findAppByIpList" resultMap="AppIpCfgMap">
select
<include refid="AppIpCfg_Column"/>
<trim prefix="," prefixOverrides=",">
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
from app_ip_cfg r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
<select id="findAppByHttpList" resultMap="AppHttpCfgMap">
select
<include refid="AppHttpCfg_Column"/>
<trim prefix="," prefixOverrides=",">
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
from app_http_cfg r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
<select id="findAppByDomainList" resultMap="AppDomainCfgMap">
select
<include refid="AppDomainCfg_Column"/>
<trim prefix="," prefixOverrides=",">
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
from app_domain_cfg r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
<select id="findAppBySslList" resultMap="AppSslCfgMap">
select
<include refid="AppSslCfg_Column"/>
<trim prefix="," prefixOverrides=",">
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
from app_ssl_cert_cfg r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
</mapper> </mapper>

View File

@@ -62,4 +62,6 @@ public interface AppMultiFeatureCfgDao {
public List<AppIpCfg> getAppIpRangeCfg(@Param("compileId")Integer compileId,@Param("functionId")Integer functionId) ; public List<AppIpCfg> getAppIpRangeCfg(@Param("compileId")Integer compileId,@Param("functionId")Integer functionId) ;
public int insertAppIpRangeCfg(AppIpCfg entity); public int insertAppIpRangeCfg(AppIpCfg entity);
public void deleteAppIpRangeCfg(BaseCfg entity); public void deleteAppIpRangeCfg(BaseCfg entity);
public List<AppFeatureIndex> findAppByFeatureIndexList(@Param("ids")String ids);
} }

View File

@@ -521,4 +521,21 @@
<delete id="deleteAppComplexFeatureCfg" > <delete id="deleteAppComplexFeatureCfg" >
delete from app_complex_feature_cfg where compile_id=#{compileId} and function_id=#{functionId} delete from app_complex_feature_cfg where compile_id=#{compileId} and function_id=#{functionId}
</delete> </delete>
<select id="findAppByFeatureIndexList" resultMap="AppFeatureIndexMap">
select
<include refid="AppFeatureIndex_Column"/>
<trim prefix="," prefixOverrides=",">
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
from app_feature_index r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
</mapper> </mapper>

View File

@@ -13,4 +13,6 @@ import com.nis.web.dao.MyBatisDao;
public interface DdosCfgDao extends CrudDao<DdosIpCfg> { public interface DdosCfgDao extends CrudDao<DdosIpCfg> {
List<DdosIpCfg> findPage(DdosIpCfg cfg); List<DdosIpCfg> findPage(DdosIpCfg cfg);
DdosIpCfg getDdosIpCfg(@Param("cfgId")Long cfgId,@Param("compileId")Integer compileId); DdosIpCfg getDdosIpCfg(@Param("cfgId")Long cfgId,@Param("compileId")Integer compileId);
List<DdosIpCfg> findByPage(@Param("ids")String ids);
} }

View File

@@ -372,4 +372,19 @@
</where> </where>
</update> </update>
<select id="findByPage" resultMap="ddosIpCfgMap">
select
<include refid="columns"></include>
<trim prefix="," prefixOverrides=",">
,s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
from ddos_ip_cfg r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
</mapper> </mapper>

View File

@@ -14,4 +14,5 @@ public interface DnsIpCfgDao extends CrudDao<DnsIpCfg> {
DnsIpCfg getDnsIpCfg(Long cfgId); DnsIpCfg getDnsIpCfg(Long cfgId);
List<DnsIpCfg> findDnsIpCfg(DnsIpCfg entity); List<DnsIpCfg> findDnsIpCfg(DnsIpCfg entity);
List<DnsIpCfg> getValidCfgInfo(DnsIpCfg cfg); List<DnsIpCfg> getValidCfgInfo(DnsIpCfg cfg);
List<DnsIpCfg> findByPage(@Param("ids")String ids);
} }

View File

@@ -377,4 +377,21 @@
</where> </where>
</update> </update>
<select id="findByPage" resultMap="dnsIpCfgMap">
select
<include refid="columns"></include>
<trim prefix="," prefixOverrides=",">
,s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName,dns.group_name as dns_strategy_name
</trim>
from dns_ip_cfg r
left join policy_group_info dns on dns.group_id=r.dns_strategy_id
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
</mapper> </mapper>

View File

@@ -18,4 +18,6 @@ public interface DnsResStrategyDao extends CrudDao<DnsResStrategy> {
,@Param("isAudit")Integer isAudit ,@Param("isAudit")Integer isAudit
,@Param("isValid")Integer isValid); ,@Param("isValid")Integer isValid);
List<DnsResStrategy> findByPage(@Param("ids")String ids);
} }

View File

@@ -368,4 +368,21 @@ LEFT JOIN dns_res_strategy r ON a.dns_strategy_id=r.res_group_1_id
</where> </where>
</update> </update>
<!-- 查出所有 有效数据-->
<select id="findByPage" resultMap="DnsResStrategyMap">
SELECT
<include refid="DnsResStrategyColumns"/>
<trim prefix="," prefixOverrides=",">
, a.group_name group_1_name,s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
FROM dns_res_strategy r
left join policy_group_info a on r.res_group_1_id=a.group_Id
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
</mapper> </mapper>

View File

@@ -46,5 +46,7 @@ public interface IpCfgDao extends CrudDao<BaseIpCfg>{
public void updateCfgValid(BaseCfg entity); public void updateCfgValid(BaseCfg entity);
public void auditCfg(BaseCfg entity); public void auditCfg(BaseCfg entity);
public List<CfgIndexInfo> getIpCfgList(CfgIndexInfo entity); public List<CfgIndexInfo> getIpCfgList(CfgIndexInfo entity);
public List<CfgIndexInfo> getByIdsList(@Param("ids")String ids);
} }

View File

@@ -1143,4 +1143,20 @@
</choose> </choose>
</select> </select>
<select id="getByIdsList" resultMap="CfgIndexInfoMap" parameterType="com.nis.domain.configuration.CfgIndexInfo" >
SELECT
<include refid="ConfigIndex_Column" />
<trim prefix="," prefixOverrides=",">
, s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName,dns.cfg_desc as dns_strategy_name
</trim>
FROM cfg_index_info a
left join dns_res_strategy dns on a.dns_strategy_id=dns.cfg_id
left join sys_user s on a.creator_id=s.id
left join sys_user e on a.editor_id=e.id
left join sys_user u on a.auditor_id=u.id
left join request_info ri on a.request_id=ri.id
where a.CFG_ID in (${ids})
</select>
</mapper> </mapper>

View File

@@ -13,6 +13,10 @@ import com.nis.web.dao.MyBatisDao;
@MyBatisDao @MyBatisDao
public interface PxyObjKeyringDao extends CrudDao<PxyObjKeyring>{ public interface PxyObjKeyringDao extends CrudDao<PxyObjKeyring>{
List<PxyObjKeyring> findPage( PxyObjKeyring pxyObjKeyring); List<PxyObjKeyring> findPage( PxyObjKeyring pxyObjKeyring);
List<PxyObjKeyring> findByList(@Param("ids")String ids);
List<PxyObjTrustedCaCert> findByCertList(@Param("ids")String ids);
List<PxyObjTrustedCaCert> findTrustedCertPage( PxyObjTrustedCaCert PxyObjTrustedCaCert); List<PxyObjTrustedCaCert> findTrustedCertPage( PxyObjTrustedCaCert PxyObjTrustedCaCert);
List<PxyObjKeyring> findList(@Param("cfgId")Long cfgId List<PxyObjKeyring> findList(@Param("cfgId")Long cfgId
,@Param("isAudit")Integer isAudit ,@Param("isAudit")Integer isAudit

View File

@@ -797,4 +797,38 @@
</where> </where>
</update> </update>
<!-- 查出所有 有效数据-->
<select id="findByList" resultMap="PxyObjKeyringMap">
SELECT
<include refid="PxyObjKeyringColumns"/>
<trim prefix="," prefixOverrides=",">
,s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
FROM pxy_obj_keyring r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
<!-- 查出所有 有效数据-->
<select id="findByCertList" resultMap="PxyObjTrustedCaCertMap">
SELECT
<include refid="PxyObjTrustedCaCertColumns"/>
<trim prefix="," prefixOverrides=",">
,s.name as creator_name,e.name as editor_name,u.name as auditor_name
,ri.request_title as requestName
</trim>
FROM pxy_obj_trusted_ca_cert r
left join sys_user s on r.creator_id=s.id
left join sys_user e on r.editor_id=e.id
left join sys_user u on r.auditor_id=u.id
left join request_info ri on r.request_id=ri.id
where r.CFG_ID in (${ids})
</select>
</mapper> </mapper>

View File

@@ -30,6 +30,7 @@ import com.nis.domain.configuration.AppTopicDomainCfg;
import com.nis.domain.configuration.AreaIpCfg; import com.nis.domain.configuration.AreaIpCfg;
import com.nis.domain.configuration.BaseIpCfg; import com.nis.domain.configuration.BaseIpCfg;
import com.nis.domain.configuration.BaseStringCfg; import com.nis.domain.configuration.BaseStringCfg;
import com.nis.domain.configuration.CfgIndexInfo;
import com.nis.domain.configuration.ComplexkeywordCfg; import com.nis.domain.configuration.ComplexkeywordCfg;
import com.nis.domain.configuration.IpPortCfg; import com.nis.domain.configuration.IpPortCfg;
import com.nis.domain.configuration.NtcSubscribeIdCfg; import com.nis.domain.configuration.NtcSubscribeIdCfg;
@@ -94,6 +95,12 @@ public class AppCfgService extends BaseService {
return page; return page;
} }
public List<AppPolicyCfg> findAppByPolicyList(String ids) {
List<AppPolicyCfg> list = appCfgDao.findAppByPolicyList(ids);
return list;
}
public Page<AppIpCfg> findAppIpList(Page<AppIpCfg> page, AppIpCfg entity) { public Page<AppIpCfg> findAppIpList(Page<AppIpCfg> page, AppIpCfg entity) {
entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r")); entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r"));
entity.setPage(page); entity.setPage(page);
@@ -101,6 +108,11 @@ public class AppCfgService extends BaseService {
page.setList(list); page.setList(list);
return page; return page;
} }
public List<AppIpCfg> findAppByIpList(String ids) {
List<AppIpCfg> list = appCfgDao.findAppByIpList(ids);
return list;
}
public Page<AppHttpCfg> findAppHttpList(Page<AppHttpCfg> page, AppHttpCfg entity) { public Page<AppHttpCfg> findAppHttpList(Page<AppHttpCfg> page, AppHttpCfg entity) {
entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r")); entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r"));
@@ -109,6 +121,11 @@ public class AppCfgService extends BaseService {
page.setList(list); page.setList(list);
return page; return page;
} }
public List<AppHttpCfg> findAppByHttpList(String ids ) {
List<AppHttpCfg> list = appCfgDao.findAppByHttpList(ids);
return list;
}
public Page<AppDomainCfg> findAppDomainList(Page<AppDomainCfg> page, AppDomainCfg entity) { public Page<AppDomainCfg> findAppDomainList(Page<AppDomainCfg> page, AppDomainCfg entity) {
entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r")); entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r"));
@@ -118,6 +135,11 @@ public class AppCfgService extends BaseService {
return page; return page;
} }
public List<AppDomainCfg> findAppByDomainList(String ids) {
List<AppDomainCfg> list = appCfgDao.findAppByDomainList(ids);
return list;
}
public AppPolicyCfg exportIpInfo(AppPolicyCfg policy){ public AppPolicyCfg exportIpInfo(AppPolicyCfg policy){
List<IpPortCfg> ipPortList = appCfgDao.getAppPolicyIpList(policy); List<IpPortCfg> ipPortList = appCfgDao.getAppPolicyIpList(policy);
policy.setIpPortList(ipPortList); policy.setIpPortList(ipPortList);
@@ -136,6 +158,14 @@ public class AppCfgService extends BaseService {
page.setList(list); page.setList(list);
return page; return page;
} }
// 主题网站列表
public List<AppTopicDomainCfg> findAppByTopicDomainList(String ids) {
List<AppTopicDomainCfg> list = appCfgDao.findAppByTopicDomainList(ids);
return list;
}
public Page<AppByteCfg> findAppByteList(Page<AppByteCfg> page, AppByteCfg entity) { public Page<AppByteCfg> findAppByteList(Page<AppByteCfg> page, AppByteCfg entity) {
entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r")); entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r"));
@@ -152,6 +182,11 @@ public class AppCfgService extends BaseService {
page.setList(list); page.setList(list);
return page; return page;
} }
public List<AppSslCertCfg> findAppBySslList(String ids) {
List<AppSslCertCfg> list = appCfgDao.findAppBySslList(ids);
return list;
}
public Page<AppTcpCfg> findAppTcpList(Page<AppTcpCfg> page, AppTcpCfg entity) { public Page<AppTcpCfg> findAppTcpList(Page<AppTcpCfg> page, AppTcpCfg entity) {
entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r")); entity.getSqlMap().put("dsf", configScopeFilter(entity.getCurrentUser(), "r"));

View File

@@ -60,6 +60,14 @@ public class AppMultiFeatureCfgService extends BaseService {
page.setList(list); page.setList(list);
return page; return page;
} }
//分页查询
public List<AppFeatureIndex> findAppByFeatureIndexList(String ids) {
List<AppFeatureIndex> list = appMultiFeatureCfgDao.findAppByFeatureIndexList(ids);
return list;
}
public AppFeatureIndex getAppFeatureIndex(Long cfgId) { public AppFeatureIndex getAppFeatureIndex(Long cfgId) {
return appMultiFeatureCfgDao.getAppFeatureIndex(cfgId); return appMultiFeatureCfgDao.getAppFeatureIndex(cfgId);
} }

View File

@@ -62,6 +62,11 @@ public class DdosCfgService extends BaseService{
return page; return page;
} }
public List<DdosIpCfg> findByPage(String ids) {
List<DdosIpCfg> list=ddosCfgDao.findByPage(ids);
return list;
}
public DdosIpCfg getDdosIpCfg(Long cfgId,Integer compileId) { public DdosIpCfg getDdosIpCfg(Long cfgId,Integer compileId) {
return ddosCfgDao.getDdosIpCfg(cfgId,compileId); return ddosCfgDao.getDdosIpCfg(cfgId,compileId);
} }

View File

@@ -48,6 +48,11 @@ public class DnsIpCfgService extends BaseService{
return page; return page;
} }
public List<DnsIpCfg> findByPage(String ids) {
List<DnsIpCfg> list=dnsIpCfgDao.findByPage(ids);
return list;
}
public List<DnsIpCfg> findDnsIpCfg(DnsIpCfg entity) { public List<DnsIpCfg> findDnsIpCfg(DnsIpCfg entity) {
return dnsIpCfgDao.findDnsIpCfg(entity); return dnsIpCfgDao.findDnsIpCfg(entity);
} }

View File

@@ -52,6 +52,13 @@ public class DnsResStrategyService extends BaseService{
page.setList(list); page.setList(list);
return page; return page;
} }
public List<DnsResStrategy> findByPage(String ids ) {
List<DnsResStrategy> list=dnsResStrategyDao.findByPage(ids);
return list;
}
public List<DnsResStrategy> findDnsResStrategys(Long cfgId,Integer isValid,Integer isAudit) { public List<DnsResStrategy> findDnsResStrategys(Long cfgId,Integer isValid,Integer isAudit) {
List<DnsResStrategy> list=dnsResStrategyDao.findList(cfgId,isValid,isAudit); List<DnsResStrategy> list=dnsResStrategyDao.findList(cfgId,isValid,isAudit);
return list; return list;

View File

@@ -932,4 +932,9 @@ public class IpCfgService extends CrudService<IpCfgDao,BaseIpCfg> {
return page; return page;
} }
public List<CfgIndexInfo> getByIdsList(String ids) {
List<CfgIndexInfo> list = ipCfgDao.getByIdsList(ids);
return list;
}
} }

View File

@@ -56,6 +56,17 @@ public class PxyObjKeyringService extends BaseService{
page.setList(list); page.setList(list);
return page; return page;
} }
public List<PxyObjKeyring> findByList(String ids) {
List<PxyObjKeyring> list=pxyObjKeyringDao.findByList(ids);
return list;
}
public List<PxyObjTrustedCaCert> findByCertList(String ids) {
List<PxyObjTrustedCaCert> list=pxyObjKeyringDao.findByCertList(ids);
return list;
}
/** /**
* 查询分页数据 * 查询分页数据
* @param page 分页对象 * @param page 分页对象