diff --git a/src/main/java/com/nis/web/controller/configuration/AppCfgController.java b/src/main/java/com/nis/web/controller/configuration/AppCfgController.java index 6eeb5d100..9eceff3de 100644 --- a/src/main/java/com/nis/web/controller/configuration/AppCfgController.java +++ b/src/main/java/com/nis/web/controller/configuration/AppCfgController.java @@ -357,7 +357,9 @@ public class AppCfgController extends BaseController { Page page = appCfgService.findAppIpList(searchPage, cfg); for (AppIpCfg entity : page.getList()) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(entity.getSpecServiceId()); - entity.setAppName(app.getSpecServiceName()); + if(app!=null){ + entity.setAppName(app.getSpecServiceName()); + } } model.addAttribute("page", page); initPageCondition(model, cfg); @@ -552,7 +554,9 @@ public class AppCfgController extends BaseController { Page page = appCfgService.findAppHttpList(searchPage, cfg); for (AppHttpCfg entity : page.getList()) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(entity.getSpecServiceId()); - entity.setAppName(app.getSpecServiceName()); + if(app!=null){ + entity.setAppName(app.getSpecServiceName()); + } // entity.setCfgKeywords(entity.getCfgKeywords().replace(Constants.KEYWORD_EXPR, // "&")); } @@ -715,7 +719,9 @@ public class AppCfgController extends BaseController { Page page = appCfgService.findAppDomainList(searchPage, cfg); for (AppDomainCfg entity : page.getList()) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(entity.getSpecServiceId()); - entity.setAppName(app.getSpecServiceName()); + if(app!=null){ + entity.setAppName(app.getSpecServiceName()); + } } model.addAttribute("page", page); initPageCondition(model, cfg); @@ -898,7 +904,9 @@ public class AppCfgController extends BaseController { Page page = appCfgService.findAppByteList(searchPage, cfg); for (AppByteCfg entity : page.getList()) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(entity.getSpecServiceId()); - entity.setAppName(app.getSpecServiceName()); + if(app!=null){ + entity.setAppName(app.getSpecServiceName()); + } } model.addAttribute("page", page); initPageCondition(model, cfg); @@ -1035,7 +1043,9 @@ public class AppCfgController extends BaseController { Page page = appCfgService.findAppSslList(searchPage, cfg); for (AppSslCertCfg entity : page.getList()) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(entity.getSpecServiceId()); - entity.setAppName(app.getSpecServiceName()); + if(app!=null){ + entity.setAppName(app.getSpecServiceName()); + } } model.addAttribute("page", page); initPageCondition(model, cfg); @@ -1196,7 +1206,9 @@ public class AppCfgController extends BaseController { Page page = appCfgService.findAppTcpList(searchPage, cfg); for (AppTcpCfg entity : page.getList()) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(entity.getSpecServiceId()); - entity.setAppName(app.getSpecServiceName()); + if(app!=null){ + entity.setAppName(app.getSpecServiceName()); + } } model.addAttribute("page", page); initPageCondition(model, cfg); @@ -1332,7 +1344,9 @@ public class AppCfgController extends BaseController { Page page = appCfgService.findAppHeaderList(searchPage, cfg); for (AppHeaderCfg entity : page.getList()) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(entity.getSpecServiceId()); - entity.setAppName(app.getSpecServiceName()); + if(app!=null){ + entity.setAppName(app.getSpecServiceName()); + } } model.addAttribute("page", page); initPageCondition(model, cfg); @@ -2059,7 +2073,9 @@ public class AppCfgController extends BaseController { for (AppIpCfg appIp : ipLists) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(appIp.getSpecServiceId()); - appIp.setAppName(app.getSpecServiceName()); + if(app!=null){ + appIp.setAppName(app.getSpecServiceName()); + } } titleList.add(entity.getMenuNameCode()); classMap.put(entity.getMenuNameCode(), AppIpCfg.class); @@ -2133,7 +2149,9 @@ public class AppCfgController extends BaseController { } http.setCfgKeywords(Functions.replace(http.getCfgKeywords(), "***and***", " ")); SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(http.getSpecServiceId()); - http.setAppName(app.getSpecServiceName()); + if(app!=null){ + http.setAppName(app.getSpecServiceName()); + } } titleList.add(entity.getMenuNameCode()); @@ -2206,7 +2224,9 @@ public class AppCfgController extends BaseController { domain.setIsCaseInsenstive(0); } SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(domain.getSpecServiceId()); - domain.setAppName(app.getSpecServiceName()); + if(app!=null){ + domain.setAppName(app.getSpecServiceName()); + } } titleList.add(entity.getMenuNameCode()); @@ -2281,7 +2301,9 @@ public class AppCfgController extends BaseController { } ssl.setCfgKeywords(Functions.replace(ssl.getCfgKeywords(), "***and***", " ")); SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(ssl.getSpecServiceId()); - ssl.setAppName(app.getSpecServiceName()); + if(app!=null){ + ssl.setAppName(app.getSpecServiceName()); + } } titleList.add(entity.getMenuNameCode()); classMap.put(entity.getMenuNameCode(), AppSslCertCfg.class); diff --git a/src/main/java/com/nis/web/controller/configuration/AppFeatureCfgController.java b/src/main/java/com/nis/web/controller/configuration/AppFeatureCfgController.java index 75ef78768..85d2e73b0 100644 --- a/src/main/java/com/nis/web/controller/configuration/AppFeatureCfgController.java +++ b/src/main/java/com/nis/web/controller/configuration/AppFeatureCfgController.java @@ -88,7 +88,9 @@ public class AppFeatureCfgController extends BaseController { Page page = appMultiFeatureCfgService.findAppFeatureIndexList(searchPage, cfg); for (AppFeatureIndex entity : page.getList()) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(entity.getSpecServiceId()); - entity.setAppName(app.getSpecServiceName()); + if(app!=null){ + entity.setAppName(app.getSpecServiceName()); + } } model.addAttribute("page", page); initPageCondition(model, cfg); @@ -352,7 +354,9 @@ public class AppFeatureCfgController extends BaseController { for (AppFeatureIndex feature : ipLists) { SpecificServiceCfg app = specificServiceCfgService.getBySpecServiceId(feature.getSpecServiceId()); - feature.setAppName(app.getSpecServiceName()); + if(app!=null){ + feature.setAppName(app.getSpecServiceName()); + } } 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 appComplexNoExport = ",do_log,block_type,config_describe,valid_identifier,is_audit,creator,creator"