Dao object moved from dao packege to package by component in service folder 22/99722/2
authorDominik Mizyn <d.mizyn@samsung.com>
Tue, 17 Dec 2019 15:14:10 +0000 (16:14 +0100)
committerDominik Mizyn <d.mizyn@samsung.com>
Tue, 17 Dec 2019 15:15:29 +0000 (16:15 +0100)
This patch move all services from single folder to separete folders.
All DAO classes are noc package-private and moved too to this folders,
providing encapsulation mechanism. DAO object schould not be directly
call from any where else that package type class.

Issue-ID: PORTAL-710
Change-Id: I3c0edd9eaa8260849ca716dd6244cf4c83ec783c
Signed-off-by: Dominik Mizyn <d.mizyn@samsung.com>
116 files changed:
portal-BE/src/main/java/org/onap/portal/PortalApplication.java
portal-BE/src/main/java/org/onap/portal/aop/service/FnLanguageServiceAOP.java
portal-BE/src/main/java/org/onap/portal/aop/service/FnUserServiceAOP.java
portal-BE/src/main/java/org/onap/portal/aop/service/WidgetServiceAOP.java
portal-BE/src/main/java/org/onap/portal/configuration/DBInitializingBean.java
portal-BE/src/main/java/org/onap/portal/configuration/SecurityConfig.java
portal-BE/src/main/java/org/onap/portal/configuration/WebMvcConfiguration.java
portal-BE/src/main/java/org/onap/portal/controller/LanguageController.java
portal-BE/src/main/java/org/onap/portal/controller/UserController.java
portal-BE/src/main/java/org/onap/portal/controller/UserRolesController.java
portal-BE/src/main/java/org/onap/portal/controller/WidgetsCatalogController.java
portal-BE/src/main/java/org/onap/portal/controller/WidgetsController.java
portal-BE/src/main/java/org/onap/portal/logging/aop/EPEELFLoggerAdvice.java
portal-BE/src/main/java/org/onap/portal/service/AdminRolesService.java
portal-BE/src/main/java/org/onap/portal/service/AppsCacheService.java
portal-BE/src/main/java/org/onap/portal/service/EPRoleFunctionService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/old/EPRoleFunctionService.java with 98% similarity]
portal-BE/src/main/java/org/onap/portal/service/ExternalAccessRolesService.java
portal-BE/src/main/java/org/onap/portal/service/PersUserWidgetService.java
portal-BE/src/main/java/org/onap/portal/service/app/FnAppDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnAppDao.java with 84% similarity]
portal-BE/src/main/java/org/onap/portal/service/app/FnAppService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/FnAppService.java with 95% similarity]
portal-BE/src/main/java/org/onap/portal/service/appContactUs/FnAppContactUsDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnAppContactUsDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/appContactUs/FnAppContactUsService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/appFunction/EpAppFunctionDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpAppFunctionDao.java with 95% similarity]
portal-BE/src/main/java/org/onap/portal/service/appFunction/EpAppFunctionService.java [moved from portal-BE/src/main/java/org/onap/portal/service/ep/EpAppFunctionService.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/appRoleFunction/EpAppRoleFunctionDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpAppRoleFunctionDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/appRoleFunction/EpAppRoleFunctionService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/auditLog/FnAuditLogDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnAuditLogDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/auditLog/FnAuditLogService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/basicAuthAccount/EpBasicAuthAccountDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpBasicAuthAccountDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/basicAuthAccount/EpBasicAuthAccountService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/commonWidgetData/FnCommonWidgetDataDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnCommonWidgetDataDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/commonWidgetData/FnCommonWidgetDataService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/displayText/FnDisplayTextDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnDisplayTextDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/displayText/FnDisplayTextService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/function/FnFunctionDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnFunctionDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/function/FnFunctionService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/language/FnLanguageDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnLanguageDao.java with 95% similarity]
portal-BE/src/main/java/org/onap/portal/service/language/FnLanguageService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/FnLanguageService.java with 90% similarity]
portal-BE/src/main/java/org/onap/portal/service/luActivity/FnLuActivityDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnLuActivityDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/luActivity/FnLuActivityService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/luAlertMethod/FnLuAlertMethodDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnLuAlertMethodDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/luAlertMethod/FnLuAlertMethodService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/luMenuSet/FnLuMenuSetDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnLuMenuSetDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/luMenuSet/FnLuMenuSetService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/luPriority/FnLuPriorityDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnLuPriorityDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/luPriority/FnLuPriorityService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/luTabSet/FnLuTabSetDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnLuTabSetDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/luTabSet/FnLuTabSetService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/luTimezone/FnLuTimezoneDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnLuTimezoneDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/luTimezone/FnLuTimezoneService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/FnLuTimezoneService.java with 92% similarity]
portal-BE/src/main/java/org/onap/portal/service/menu/FnMenuDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnMenuDao.java with 95% similarity]
portal-BE/src/main/java/org/onap/portal/service/menu/FnMenuService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/menuFunctional/FnMenuFunctionalDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnMenuFunctionalDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/menuFunctional/FnMenuFunctionalService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/FnMenuFunctionalService.java with 92% similarity]
portal-BE/src/main/java/org/onap/portal/service/menuFunctionalAncestors/FnMenuFunctionalAncestorsDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnMenuFunctionalAncestorsDao.java with 93% similarity]
portal-BE/src/main/java/org/onap/portal/service/menuFunctionalAncestors/FnMenuFunctionalAncestorsService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/menuFunctionalRoles/FnMenuFunctionalRolesDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnMenuFunctionalRolesDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/menuFunctionalRoles/FnMenuFunctionalRolesService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/FnMenuFunctionalRolesService.java with 93% similarity]
portal-BE/src/main/java/org/onap/portal/service/microservice/EpMicroserviceDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpMicroserviceDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/microservice/EpMicroserviceService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/microserviceParameter/EpMicroserviceParameterDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpMicroserviceParameterDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/microserviceParameter/EpMicroserviceParameterService.java [moved from portal-BE/src/main/java/org/onap/portal/service/ep/EpMicroserviceParameterService.java with 93% similarity]
portal-BE/src/main/java/org/onap/portal/service/persUserAppSel/FnPersUserAppSelDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnPersUserAppSelDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/persUserAppSel/FnPersUserAppSelService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/persUserAppSort/EpPersUserAppSortDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpPersUserAppSortDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/persUserAppSort/EpPersUserAppSortService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/persUserWidgetSel/EpPersUserWidgetSelDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpPersUserWidgetSelDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/persUserWidgetSel/EpPersUserWidgetSelService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/qzCronTriggers/FnQzCronTriggersDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnQzCronTriggersDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/qzCronTriggers/FnQzCronTriggersService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/qzJobDetails/FnQzJobDetailsDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnQzJobDetailsDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/qzJobDetails/FnQzJobDetailsService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/qzLocks/FnQzLocksDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnQzLocksDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/qzLocks/FnQzLocksService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/qzSchedulerState/FnQzSchedulerStateDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnQzSchedulerStateDao.java with 93% similarity]
portal-BE/src/main/java/org/onap/portal/service/qzSchedulerState/FnQzSchedulerStateService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/qzTriggers/FnQzTriggersDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnQzTriggersDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/qzTriggers/FnQzTriggersService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/restrictedUrl/FnRestrictedUrlDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnRestrictedUrlDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/restrictedUrl/FnRestrictedUrlService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/role/FnRoleDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnRoleDao.java with 96% similarity]
portal-BE/src/main/java/org/onap/portal/service/role/FnRoleService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/FnRoleService.java with 97% similarity]
portal-BE/src/main/java/org/onap/portal/service/roleComposite/FnRoleCompositeDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnRoleCompositeDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/roleComposite/FnRoleCompositeService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/roleFunction/FnRoleFunctionDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnRoleFunctionDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/roleFunction/FnRoleFunctionService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/sharedContext/FnSharedContextDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnSharedContextDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/sharedContext/FnSharedContextService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/tab/FnTabDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnTabDao.java with 95% similarity]
portal-BE/src/main/java/org/onap/portal/service/tab/FnTabService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/tabSelected/FnTabSelectedDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnTabSelectedDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/tabSelected/FnTabSelectedService.java [new file with mode: 0644]
portal-BE/src/main/java/org/onap/portal/service/user/FnUserDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnUserDao.java with 96% similarity]
portal-BE/src/main/java/org/onap/portal/service/user/FnUserService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/FnUserService.java with 89% similarity]
portal-BE/src/main/java/org/onap/portal/service/userRole/FnUserRoleDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnUserRoleDao.java with 96% similarity]
portal-BE/src/main/java/org/onap/portal/service/userRole/FnUserRoleService.java [moved from portal-BE/src/main/java/org/onap/portal/service/fn/FnUserRoleService.java with 98% similarity]
portal-BE/src/main/java/org/onap/portal/service/userRolesRequest/EpUserRolesRequestDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpUserRolesRequestDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/userRolesRequest/EpUserRolesRequestService.java [moved from portal-BE/src/main/java/org/onap/portal/service/ep/EpUserRolesRequestService.java with 96% similarity]
portal-BE/src/main/java/org/onap/portal/service/userRolesRequestDet/EpUserRolesRequestDetDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpUserRolesRequestDetDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/userRolesRequestDet/EpUserRolesRequestDetService.java [moved from portal-BE/src/main/java/org/onap/portal/service/ep/EpUserRolesRequestDetService.java with 96% similarity]
portal-BE/src/main/java/org/onap/portal/service/widget/FnWidgetDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/FnWidgetDao.java with 95% similarity]
portal-BE/src/main/java/org/onap/portal/service/widget/WidgetService.java [moved from portal-BE/src/main/java/org/onap/portal/service/WidgetService.java with 98% similarity]
portal-BE/src/main/java/org/onap/portal/service/widgetCatalog/EpWidgetCatalogDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/fn/EpWidgetCatalogDao.java with 94% similarity]
portal-BE/src/main/java/org/onap/portal/service/widgetCatalog/EpWidgetCatalogService.java [moved from portal-BE/src/main/java/org/onap/portal/service/ep/EpWidgetCatalogService.java with 59% similarity]
portal-BE/src/main/java/org/onap/portal/service/widgetCatalogParameter/EpWidgetCatalogParameterDao.java [moved from portal-BE/src/main/java/org/onap/portal/dao/ep/EpWidgetCatalogParameterDao.java with 85% similarity]
portal-BE/src/main/java/org/onap/portal/service/widgetCatalogParameter/EpWidgetCatalogParameterService.java [moved from portal-BE/src/main/java/org/onap/portal/service/ep/EpWidgetCatalogParameterService.java with 97% similarity]
portal-BE/src/main/java/org/onap/portal/utils/EPUserUtils.java
portal-BE/src/test/java/org/onap/portal/controller/LanguageControllerTest.java
portal-BE/src/test/java/org/onap/portal/controller/UserControllerTest.java
portal-BE/src/test/java/org/onap/portal/controller/UserRolesControllerTest.java
portal-BE/src/test/java/org/onap/portal/controller/WidgetsCatalogControllerTest.java
portal-BE/src/test/java/org/onap/portal/controller/WidgetsControllerTest.java
portal-BE/src/test/java/org/onap/portal/service/ep/EpMicroserviceParameterServiceTest.java
portal-BE/src/test/java/org/onap/portal/service/ep/EpWidgetCatalogParameterServiceTest.java
portal-BE/src/test/java/org/onap/portal/service/fn/FnUserRoleServiceTest.java
portal-BE/src/test/java/org/onap/portal/service/fn/FnUserServiceTest.java

index cf6f9d7..047880a 100644 (file)
@@ -48,7 +48,7 @@ import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
 
 @SpringBootApplication
 @EntityScan("org.onap.portal.domain")
-@EnableJpaRepositories("org.onap.portal.dao")
+@EnableJpaRepositories("org.onap.portal.service")
 public class PortalApplication {
 
        public static void main(String[] args) {
index 4b48ae4..b62e7f7 100644 (file)
@@ -60,7 +60,7 @@ public class FnLanguageServiceAOP {
        @Autowired
        private DataValidator dataValidator;
 
-       @Before("execution(* org.onap.portal.service.fn.FnLanguageService.save(..)) && args(fnLanguage)")
+       @Before("execution(* org.onap.portal.service.language.FnLanguageService.save(..)) && args(fnLanguage)")
        public void save(final FnLanguage fnLanguage) {
               if (fnLanguage == null) {
                      LOGGER.info("User " +  " try to save NULL fnLanguage");
@@ -75,7 +75,7 @@ public class FnLanguageServiceAOP {
               }
        }
 
-       @Before("execution(* org.onap.portal.service.fn.FnLanguageService.getLanguageList(..)) && args(principal)")
+       @Before("execution(* org.onap.portal.service.language.FnLanguageService.getLanguageList(..)) && args(principal)")
        public void getLanguageList(final Principal principal) {
               LOGGER.info("User " + principal.getName() + " try requested for all language list");
        }
index f891392..5cbec71 100644 (file)
@@ -68,7 +68,7 @@ public class FnUserServiceAOP {
               this.fnUserMapper = fnUserMapper;
        }
 
-       @Before("execution(* org.onap.portal.service.fn.FnUserService.saveFnUser(..)) && args(principal, fnUser)")
+       @Before("execution(* org.onap.portal.service.user.FnUserService.saveFnUser(..)) && args(principal, fnUser)")
        public void save(final Principal principal, final FnUser fnUser) {
               FnUser user;
               if (fnUser == null) {
index 1417293..c1357e2 100644 (file)
@@ -23,7 +23,7 @@ public class WidgetServiceAOP {
               this.dataValidator = dataValidator;
        }
 
-       @Before("execution(* org.onap.portal.service.WidgetService.setOnboardingWidget(..)) && args(userId, onboardingWidget)")
+       @Before("execution(* org.onap.portal.service.widget.WidgetService.setOnboardingWidget(..)) && args(userId, onboardingWidget)")
        public void setOnboardingWidget(final Long userId, OnboardingWidget onboardingWidget) {
               if (!dataValidator.isValid(onboardingWidget)) {
                      throw new IllegalArgumentException(dataValidator.getConstraintViolationsString(onboardingWidget));
index ebd23cd..3f5b388 100644 (file)
 
 package org.onap.portal.configuration;
 
+import org.onap.portal.domain.db.ep.*;
+import org.onap.portal.domain.db.fn.*;
+import org.onap.portal.service.app.FnAppService;
+import org.onap.portal.service.appContactUs.FnAppContactUsService;
+import org.onap.portal.service.appFunction.EpAppFunctionService;
+import org.onap.portal.service.appRoleFunction.EpAppRoleFunctionService;
+import org.onap.portal.service.auditLog.FnAuditLogService;
+import org.onap.portal.service.basicAuthAccount.EpBasicAuthAccountService;
+import org.onap.portal.service.commonWidgetData.FnCommonWidgetDataService;
+import org.onap.portal.service.displayText.FnDisplayTextService;
+import org.onap.portal.service.function.FnFunctionService;
+import org.onap.portal.service.language.FnLanguageService;
+import org.onap.portal.service.luActivity.FnLuActivityService;
+import org.onap.portal.service.luAlertMethod.FnLuAlertMethodService;
+import org.onap.portal.service.luMenuSet.FnLuMenuSetService;
+import org.onap.portal.service.luPriority.FnLuPriorityService;
+import org.onap.portal.service.luTabSet.FnLuTabSetService;
+import org.onap.portal.service.luTimezone.FnLuTimezoneService;
+import org.onap.portal.service.menu.FnMenuService;
+import org.onap.portal.service.menuFunctional.FnMenuFunctionalService;
+import org.onap.portal.service.menuFunctionalAncestors.FnMenuFunctionalAncestorsService;
+import org.onap.portal.service.menuFunctionalRoles.FnMenuFunctionalRolesService;
+import org.onap.portal.service.microservice.EpMicroserviceService;
+import org.onap.portal.service.microserviceParameter.EpMicroserviceParameterService;
+import org.onap.portal.service.persUserAppSel.FnPersUserAppSelService;
+import org.onap.portal.service.persUserAppSort.EpPersUserAppSortService;
+import org.onap.portal.service.qzCronTriggers.FnQzCronTriggersService;
+import org.onap.portal.service.qzJobDetails.FnQzJobDetailsService;
+import org.onap.portal.service.qzLocks.FnQzLocksService;
+import org.onap.portal.service.qzSchedulerState.FnQzSchedulerStateService;
+import org.onap.portal.service.qzTriggers.FnQzTriggersService;
+import org.onap.portal.service.restrictedUrl.FnRestrictedUrlService;
+import org.onap.portal.service.role.FnRoleService;
+import org.onap.portal.service.roleComposite.FnRoleCompositeService;
+import org.onap.portal.service.roleFunction.FnRoleFunctionService;
+import org.onap.portal.service.sharedContext.FnSharedContextService;
+import org.onap.portal.service.tab.FnTabService;
+import org.onap.portal.service.tabSelected.FnTabSelectedService;
+import org.onap.portal.service.user.FnUserService;
+import org.onap.portal.service.userRole.FnUserRoleService;
+import org.onap.portal.service.widgetCatalog.EpWidgetCatalogService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.ComponentScan;
+import org.springframework.context.annotation.Configuration;
+import org.springframework.stereotype.Component;
+
 import java.math.BigInteger;
 import java.time.LocalDateTime;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.List;
-import org.onap.portal.dao.ep.EpAppFunctionDao;
-import org.onap.portal.dao.ep.EpAppRoleFunctionDao;
-import org.onap.portal.dao.ep.EpBasicAuthAccountDao;
-import org.onap.portal.dao.ep.EpMicroserviceDao;
-import org.onap.portal.dao.ep.EpMicroserviceParameterDao;
-import org.onap.portal.dao.ep.EpPersUserAppSortDao;
-import org.onap.portal.dao.fn.EpWidgetCatalogDao;
-import org.onap.portal.dao.fn.FnAppContactUsDao;
-import org.onap.portal.dao.fn.FnAppDao;
-import org.onap.portal.dao.fn.FnAuditLogDao;
-import org.onap.portal.dao.fn.FnCommonWidgetDataDao;
-import org.onap.portal.dao.fn.FnDisplayTextDao;
-import org.onap.portal.dao.fn.FnFunctionDao;
-import org.onap.portal.dao.fn.FnLanguageDao;
-import org.onap.portal.dao.fn.FnLuActivityDao;
-import org.onap.portal.dao.fn.FnLuAlertMethodDao;
-import org.onap.portal.dao.fn.FnLuMenuSetDao;
-import org.onap.portal.dao.fn.FnLuPriorityDao;
-import org.onap.portal.dao.fn.FnLuTabSetDao;
-import org.onap.portal.dao.fn.FnLuTimezoneDao;
-import org.onap.portal.dao.fn.FnMenuDao;
-import org.onap.portal.dao.fn.FnMenuFunctionalAncestorsDao;
-import org.onap.portal.dao.fn.FnMenuFunctionalDao;
-import org.onap.portal.dao.fn.FnMenuFunctionalRolesDao;
-import org.onap.portal.dao.fn.FnPersUserAppSelDao;
-import org.onap.portal.dao.fn.FnQzCronTriggersDao;
-import org.onap.portal.dao.fn.FnQzJobDetailsDao;
-import org.onap.portal.dao.fn.FnQzLocksDao;
-import org.onap.portal.dao.fn.FnQzSchedulerStateDao;
-import org.onap.portal.dao.fn.FnQzTriggersDao;
-import org.onap.portal.dao.fn.FnRestrictedUrlDao;
-import org.onap.portal.dao.fn.FnRoleCompositeDao;
-import org.onap.portal.dao.fn.FnRoleDao;
-import org.onap.portal.dao.fn.FnRoleFunctionDao;
-import org.onap.portal.dao.fn.FnSharedContextDao;
-import org.onap.portal.dao.fn.FnTabDao;
-import org.onap.portal.dao.fn.FnTabSelectedDao;
-import org.onap.portal.dao.fn.FnUserDao;
-import org.onap.portal.dao.fn.FnUserRoleDao;
-import org.onap.portal.domain.db.ep.EpAppFunction;
-import org.onap.portal.domain.db.ep.EpAppRoleFunction;
-import org.onap.portal.domain.db.ep.EpBasicAuthAccount;
-import org.onap.portal.domain.db.ep.EpMicroservice;
-import org.onap.portal.domain.db.ep.EpMicroserviceParameter;
-import org.onap.portal.domain.db.ep.EpPersUserAppSort;
-import org.onap.portal.domain.db.ep.EpWidgetCatalog;
-import org.onap.portal.domain.db.fn.FnApp;
-import org.onap.portal.domain.db.fn.FnAppContactUs;
-import org.onap.portal.domain.db.fn.FnAuditLog;
-import org.onap.portal.domain.db.fn.FnCommonWidgetData;
-import org.onap.portal.domain.db.fn.FnDisplayText;
-import org.onap.portal.domain.db.fn.FnFunction;
-import org.onap.portal.domain.db.fn.FnLanguage;
-import org.onap.portal.domain.db.fn.FnLuActivity;
-import org.onap.portal.domain.db.fn.FnLuAlertMethod;
-import org.onap.portal.domain.db.fn.FnLuMenuSet;
-import org.onap.portal.domain.db.fn.FnLuPriority;
-import org.onap.portal.domain.db.fn.FnLuTabSet;
-import org.onap.portal.domain.db.fn.FnLuTimezone;
-import org.onap.portal.domain.db.fn.FnMenu;
-import org.onap.portal.domain.db.fn.FnMenuFunctional;
-import org.onap.portal.domain.db.fn.FnMenuFunctionalAncestors;
-import org.onap.portal.domain.db.fn.FnMenuFunctionalRoles;
-import org.onap.portal.domain.db.fn.FnPersUserAppSel;
-import org.onap.portal.domain.db.fn.FnQzCronTriggers;
-import org.onap.portal.domain.db.fn.FnQzJobDetails;
-import org.onap.portal.domain.db.fn.FnQzLocks;
-import org.onap.portal.domain.db.fn.FnQzSchedulerState;
-import org.onap.portal.domain.db.fn.FnQzTriggers;
-import org.onap.portal.domain.db.fn.FnRestrictedUrl;
-import org.onap.portal.domain.db.fn.FnRole;
-import org.onap.portal.domain.db.fn.FnRoleComposite;
-import org.onap.portal.domain.db.fn.FnRoleFunction;
-import org.onap.portal.domain.db.fn.FnSharedContext;
-import org.onap.portal.domain.db.fn.FnTab;
-import org.onap.portal.domain.db.fn.FnTabSelected;
-import org.onap.portal.domain.db.fn.FnUser;
-import org.onap.portal.domain.db.fn.FnUserRole;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Component;
 
 @Component
 public class DBInitializingBean implements org.springframework.beans.factory.InitializingBean {
 
-  private final FnAppDao fnAppDao;
-  private final EpAppFunctionDao epAppFunctionDao;
-  private final FnRoleDao fnRoleDao;
-  private final EpAppRoleFunctionDao epAppRoleFunctionDao;
-  private final EpBasicAuthAccountDao epBasicAuthAccountDao;
-  private final EpMicroserviceDao epMicroserviceDao;
-  private final EpMicroserviceParameterDao epMicroserviceParameterDao;
-  private final EpWidgetCatalogDao epWidgetCatalogDao;
-  private final FnAppContactUsDao fnAppContactUsDao;
-  private final FnCommonWidgetDataDao fnCommonWidgetDataDao;
-  private final FnLanguageDao fnLanguageDao;
-  private final FnDisplayTextDao fnDisplayTextDao;
-  private final FnFunctionDao fnFunctionDao;
-  private final FnLuActivityDao fnLuActivityDao;
-  private final FnLuAlertMethodDao fnLuAlertMethodDao;
-  private final FnLuMenuSetDao fnLuMenuSetDao;
-  private final FnLuPriorityDao fnLuPriorityDao;
-  private final FnLuTimezoneDao fnLuTimezoneDao;
-  private final FnMenuDao fnMenuDao;
-  private final FnMenuFunctionalDao fnMenuFunctionalDao;
-  private final FnMenuFunctionalAncestorsDao fnMenuFunctionalAncestorsDao;
-  private final FnMenuFunctionalRolesDao fnMenuFunctionalRolesDao;
-  private final FnQzJobDetailsDao fnQzJobDetailsDao;
-  private final FnQzLocksDao fnQzLocksDao;
-  private final FnQzSchedulerStateDao fnQzSchedulerStateDao;
-  private final FnQzTriggersDao fnQzTriggersDao;
-  private final FnQzCronTriggersDao fnQzCronTriggersDao;
-  private final FnRestrictedUrlDao fnRestrictedUrlDao;
-  private final FnRoleCompositeDao fnRoleCompositeDao;
-  private final FnRoleFunctionDao fnRoleFunctionDao;
-  private final FnSharedContextDao fnSharedContextDao;
-  private final FnLuTabSetDao fnLuTabSetDao;
-  private final FnTabDao fnTabDao;
-  private final FnTabSelectedDao fnTabSelectedDao;
-  private final FnUserDao fnUserDao;
-  private final EpPersUserAppSortDao epPersUserAppSortDao;
-  private final FnPersUserAppSelDao fnPersUserAppSelDao;
-  private final FnAuditLogDao fnAuditLogDao;
-  private final FnUserRoleDao fnUserRoleDao;
+  private final FnAppService fnAppService;
+  private final EpAppFunctionService epAppFunctionService;
+  private final FnRoleService fnRoleService;
+  private final EpAppRoleFunctionService epAppRoleFunctionService;
+  private final EpBasicAuthAccountService epBasicAuthAccountService;
+  private final EpMicroserviceService epMicroserviceService;
+  private final EpMicroserviceParameterService epMicroserviceParameterService;
+  private final EpWidgetCatalogService epWidgetCatalogService;
+  private final FnAppContactUsService fnAppContactUsService;
+  private final FnCommonWidgetDataService fnCommonWidgetDataService;
+  private final FnLanguageService fnLanguageService;
+  private final FnDisplayTextService fnDisplayTextService;
+  private final FnFunctionService fnFunctionService;
+  private final FnLuActivityService fnLuActivityService;
+  private final FnLuAlertMethodService fnLuAlertMethodService;
+  private final FnLuMenuSetService fnLuMenuSetService;
+  private final FnLuPriorityService fnLuPriorityService;
+  private final FnLuTimezoneService fnLuTimezoneService;
+  private final FnMenuService fnMenuService;
+  private final FnMenuFunctionalService fnMenuFunctionalService;
+  private final FnMenuFunctionalAncestorsService fnMenuFunctionalAncestorsService;
+  private final FnMenuFunctionalRolesService fnMenuFunctionalRolesService;
+  private final FnQzJobDetailsService fnQzJobDetailsService;
+  private final FnQzLocksService fnQzLocksService;
+  private final FnQzSchedulerStateService fnQzSchedulerStateService;
+  private final FnQzTriggersService fnQzTriggersService;
+  private final FnQzCronTriggersService fnQzCronTriggersService;
+  private final FnRestrictedUrlService fnRestrictedUrlService;
+  private final FnRoleCompositeService fnRoleCompositeService;
+  private final FnRoleFunctionService fnRoleFunctionService;
+  private final FnSharedContextService fnSharedContextService;
+  private final FnLuTabSetService fnLuTabSetService;
+  private final FnTabService fnTabService;
+  private final FnTabSelectedService fnTabSelectedService;
+  private final FnUserService fnUserService;
+  private final EpPersUserAppSortService epPersUserAppSortService;
+  private final FnPersUserAppSelService fnPersUserAppSelService;
+  private final FnAuditLogService fnAuditLogService;
+  private final FnUserRoleService fnUserRoleService;
 
   @Autowired
-  public DBInitializingBean(FnAppDao fnAppDao, EpAppFunctionDao epAppFunctionDao,
-      FnRoleDao fnRoleDao, EpAppRoleFunctionDao epAppRoleFunctionDao,
-      EpBasicAuthAccountDao epBasicAuthAccountDao, EpMicroserviceDao epMicroserviceDao,
-      EpMicroserviceParameterDao epMicroserviceParameterDao,
-      EpWidgetCatalogDao epWidgetCatalogDao, FnAppContactUsDao fnAppContactUsDao,
-      FnCommonWidgetDataDao fnCommonWidgetDataDao, FnLanguageDao fnLanguageDao,
-      FnDisplayTextDao fnDisplayTextDao, FnFunctionDao fnFunctionDao,
-      FnLuActivityDao fnLuActivityDao, FnLuAlertMethodDao fnLuAlertMethodDao,
-      FnLuMenuSetDao fnLuMenuSetDao, FnLuPriorityDao fnLuPriorityDao,
-      FnLuTimezoneDao fnLuTimezoneDao, FnMenuDao fnMenuDao,
-      FnMenuFunctionalDao fnMenuFunctionalDao,
-      FnMenuFunctionalAncestorsDao fnMenuFunctionalAncestorsDao,
-      FnMenuFunctionalRolesDao fnMenuFunctionalRolesDao, FnQzJobDetailsDao fnQzJobDetailsDao,
-      FnQzLocksDao fnQzLocksDao, FnQzSchedulerStateDao fnQzSchedulerStateDao,
-      FnQzTriggersDao fnQzTriggersDao, FnQzCronTriggersDao fnQzCronTriggersDao,
-      FnRestrictedUrlDao fnRestrictedUrlDao, FnRoleCompositeDao fnRoleCompositeDao,
-      FnRoleFunctionDao fnRoleFunctionDao, FnSharedContextDao fnSharedContextDao,
-      FnLuTabSetDao fnLuTabSetDao, FnTabDao fnTabDao, FnTabSelectedDao fnTabSelectedDao,
-      FnUserDao fnUserDao, EpPersUserAppSortDao epPersUserAppSortDao,
-      FnPersUserAppSelDao fnPersUserAppSelDao, FnAuditLogDao fnAuditLogDao,
-      FnUserRoleDao fnUserRoleDao) {
-    this.fnAppDao = fnAppDao;
-    this.epAppFunctionDao = epAppFunctionDao;
-    this.fnRoleDao = fnRoleDao;
-    this.epAppRoleFunctionDao = epAppRoleFunctionDao;
-    this.epBasicAuthAccountDao = epBasicAuthAccountDao;
-    this.epMicroserviceDao = epMicroserviceDao;
-    this.epMicroserviceParameterDao = epMicroserviceParameterDao;
-    this.epWidgetCatalogDao = epWidgetCatalogDao;
-    this.fnAppContactUsDao = fnAppContactUsDao;
-    this.fnCommonWidgetDataDao = fnCommonWidgetDataDao;
-    this.fnLanguageDao = fnLanguageDao;
-    this.fnDisplayTextDao = fnDisplayTextDao;
-    this.fnFunctionDao = fnFunctionDao;
-    this.fnLuActivityDao = fnLuActivityDao;
-    this.fnLuAlertMethodDao = fnLuAlertMethodDao;
-    this.fnLuMenuSetDao = fnLuMenuSetDao;
-    this.fnLuPriorityDao = fnLuPriorityDao;
-    this.fnLuTimezoneDao = fnLuTimezoneDao;
-    this.fnMenuDao = fnMenuDao;
-    this.fnMenuFunctionalDao = fnMenuFunctionalDao;
-    this.fnMenuFunctionalAncestorsDao = fnMenuFunctionalAncestorsDao;
-    this.fnMenuFunctionalRolesDao = fnMenuFunctionalRolesDao;
-    this.fnQzJobDetailsDao = fnQzJobDetailsDao;
-    this.fnQzLocksDao = fnQzLocksDao;
-    this.fnQzSchedulerStateDao = fnQzSchedulerStateDao;
-    this.fnQzTriggersDao = fnQzTriggersDao;
-    this.fnQzCronTriggersDao = fnQzCronTriggersDao;
-    this.fnRestrictedUrlDao = fnRestrictedUrlDao;
-    this.fnRoleCompositeDao = fnRoleCompositeDao;
-    this.fnRoleFunctionDao = fnRoleFunctionDao;
-    this.fnSharedContextDao = fnSharedContextDao;
-    this.fnLuTabSetDao = fnLuTabSetDao;
-    this.fnTabDao = fnTabDao;
-    this.fnTabSelectedDao = fnTabSelectedDao;
-    this.fnUserDao = fnUserDao;
-    this.epPersUserAppSortDao = epPersUserAppSortDao;
-    this.fnPersUserAppSelDao = fnPersUserAppSelDao;
-    this.fnAuditLogDao = fnAuditLogDao;
-    this.fnUserRoleDao = fnUserRoleDao;
+  public DBInitializingBean(FnAppService fnAppService, EpAppFunctionService epAppFunctionService, FnRoleService fnRoleService, EpAppRoleFunctionService epAppRoleFunctionService, EpBasicAuthAccountService epBasicAuthAccountService, EpMicroserviceService epMicroserviceService, EpMicroserviceParameterService epMicroserviceParameterService, EpWidgetCatalogService epWidgetCatalogService, FnAppContactUsService fnAppContactUsService, FnCommonWidgetDataService fnCommonWidgetDataService, FnLanguageService fnLanguageService, FnDisplayTextService fnDisplayTextService, FnFunctionService fnFunctionService, FnLuActivityService fnLuActivityService, FnLuAlertMethodService fnLuAlertMethodService, FnLuMenuSetService fnLuMenuSetService, FnLuPriorityService fnLuPriorityService, FnLuTimezoneService fnLuTimezoneService, FnMenuService fnMenuService, FnMenuFunctionalService fnMenuFunctionalService, FnMenuFunctionalAncestorsService fnMenuFunctionalAncestorsService, FnMenuFunctionalRolesService fnMenuFunctionalRolesService, FnQzJobDetailsService fnQzJobDetailsService, FnQzLocksService fnQzLocksService, FnQzSchedulerStateService fnQzSchedulerStateService, FnQzTriggersService fnQzTriggersService, FnQzCronTriggersService fnQzCronTriggersService, FnRestrictedUrlService fnRestrictedUrlService, FnRoleCompositeService fnRoleCompositeService, FnRoleFunctionService fnRoleFunctionService, FnSharedContextService fnSharedContextService, FnLuTabSetService fnLuTabSetService, FnTabService fnTabService, FnTabSelectedService fnTabSelectedService, FnUserService fnUserService, EpPersUserAppSortService epPersUserAppSortService, FnPersUserAppSelService fnPersUserAppSelService, FnAuditLogService fnAuditLogService, FnUserRoleService fnUserRoleService) {
+    this.fnAppService = fnAppService;
+    this.epAppFunctionService = epAppFunctionService;
+    this.fnRoleService = fnRoleService;
+    this.epAppRoleFunctionService = epAppRoleFunctionService;
+    this.epBasicAuthAccountService = epBasicAuthAccountService;
+    this.epMicroserviceService = epMicroserviceService;
+    this.epMicroserviceParameterService = epMicroserviceParameterService;
+    this.epWidgetCatalogService = epWidgetCatalogService;
+    this.fnAppContactUsService = fnAppContactUsService;
+    this.fnCommonWidgetDataService = fnCommonWidgetDataService;
+    this.fnLanguageService = fnLanguageService;
+    this.fnDisplayTextService = fnDisplayTextService;
+    this.fnFunctionService = fnFunctionService;
+    this.fnLuActivityService = fnLuActivityService;
+    this.fnLuAlertMethodService = fnLuAlertMethodService;
+    this.fnLuMenuSetService = fnLuMenuSetService;
+    this.fnLuPriorityService = fnLuPriorityService;
+    this.fnLuTimezoneService = fnLuTimezoneService;
+    this.fnMenuService = fnMenuService;
+    this.fnMenuFunctionalService = fnMenuFunctionalService;
+    this.fnMenuFunctionalAncestorsService = fnMenuFunctionalAncestorsService;
+    this.fnMenuFunctionalRolesService = fnMenuFunctionalRolesService;
+    this.fnQzJobDetailsService = fnQzJobDetailsService;
+    this.fnQzLocksService = fnQzLocksService;
+    this.fnQzSchedulerStateService = fnQzSchedulerStateService;
+    this.fnQzTriggersService = fnQzTriggersService;
+    this.fnQzCronTriggersService = fnQzCronTriggersService;
+    this.fnRestrictedUrlService = fnRestrictedUrlService;
+    this.fnRoleCompositeService = fnRoleCompositeService;
+    this.fnRoleFunctionService = fnRoleFunctionService;
+    this.fnSharedContextService = fnSharedContextService;
+    this.fnLuTabSetService = fnLuTabSetService;
+    this.fnTabService = fnTabService;
+    this.fnTabSelectedService = fnTabSelectedService;
+    this.fnUserService = fnUserService;
+    this.epPersUserAppSortService = epPersUserAppSortService;
+    this.fnPersUserAppSelService = fnPersUserAppSelService;
+    this.fnAuditLogService = fnAuditLogService;
+    this.fnUserRoleService = fnUserRoleService;
   }
 
   @Override
@@ -472,7 +418,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         .authNamespace(null)
         .build();
     List<FnApp> fnApps = new ArrayList<>(Arrays.asList(app, app2, app3, app4, app5, app6, app7, app8, app9, app10));
-    fnAppDao.saveAll(fnApps);
+    fnAppService.saveAll(fnApps);
 
     // EP_APP_FUNCTION TABLE
 
@@ -535,7 +481,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
             function10, function11, function12, function13, function14, function15, function16, function17, function18,
             function19, function20, function21, function22, function23, function24, function25, function26,
             function27));
-    epAppFunctionDao.saveAll(epAppFunctions);
+    epAppFunctionService.saveAll(epAppFunctions);
 
     // FN_ROLE TABLE
 
@@ -565,7 +511,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
     List<FnRole> fnRoles = new ArrayList<>(Arrays
         .asList(fnRole1, fnRole16, fnRole900, fnRole950, fnRole999, fnRole1000, fnRole1001, fnRole1002, fnRole1003, fnRole1004, fnRole1005,
             fnRole1006, fnRole1007, fnRole1008, fnRole1009, fnRole1010, fnRole1011, fnRole1012, fnRole2115));
-    fnRoleDao.saveAll(fnRoles);
+    fnRoleService.saveAll(fnRoles);
 
     // EP_APP_ROLE_FUNCTION TABLE
 
@@ -634,10 +580,10 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
             epAppRoleFunction21, epAppRoleFunction22, epAppRoleFunction23, epAppRoleFunction24, epAppRoleFunction25,
             epAppRoleFunction26, epAppRoleFunction27, epAppRoleFunction28));
 
-    epAppRoleFunctionDao.saveAll(epAppRoleFunctions);
+    epAppRoleFunctionService.saveAll(epAppRoleFunctions);
 
     EpBasicAuthAccount epBasicAuthAccount = EpBasicAuthAccount.builder().extAppName("JIRA").username("jira").password("6APqvG4AU2rfLgCvMdySwQ==").activeYn(true).build();
-    epBasicAuthAccountDao.save(epBasicAuthAccount);
+    epBasicAuthAccountService.save(epBasicAuthAccount);
 
     // EP_MICROSERVICE TABLE
 
@@ -648,7 +594,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<EpMicroservice> epMicroservices = new ArrayList<>(Arrays.asList(epMicroservice1, epMicroservice2, epMicroservice3, epMicroservice4));
 
-    epMicroserviceDao.saveAll(epMicroservices);
+    epMicroserviceService.saveAll(epMicroservices);
 
     // ep_microservice_parameter table
 
@@ -659,7 +605,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<EpMicroserviceParameter> epMicroserviceParameters = new ArrayList<>(Arrays.asList(parameter1, parameter2, parameter3, parameter4));
 
-    epMicroserviceParameterDao.saveAll(epMicroserviceParameters);
+    epMicroserviceParameterService.saveAll(epMicroserviceParameters);
 
     // ep_widget_catalog table
     //TODO should we connect serviceId to EpMicroservice?
@@ -671,7 +617,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<EpWidgetCatalog> epWidgetCatalogs = new ArrayList<>(Arrays.asList(epWidgetCatalog1, epWidgetCatalog2, epWidgetCatalog3, epWidgetCatalog4));
 
-    epWidgetCatalogDao.saveAll(epWidgetCatalogs);
+    epWidgetCatalogService.saveAll(epWidgetCatalogs);
 
     // ep_widget_catalog_files table
     //TODO
@@ -691,7 +637,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnAppContactUs> fnAppContactUses = new ArrayList<>(Arrays.asList(fnAppContactUs1, fnAppContactUs2, fnAppContactUs3, fnAppContactUs4, fnAppContactUs5, fnAppContactUs6, fnAppContactUs7, fnAppContactUs8));
 
-    fnAppContactUsDao.saveAll(fnAppContactUses);
+    fnAppContactUsService.saveAll(fnAppContactUses);
 
     // fn_common_widget_data table
 
@@ -708,15 +654,15 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnCommonWidgetData> fnCommonWidgetDataList = new ArrayList<>(Arrays.asList(fnCommonWidgetData1, fnCommonWidgetData2, fnCommonWidgetData3, fnCommonWidgetData4, fnCommonWidgetData5, fnCommonWidgetData6, fnCommonWidgetData7, fnCommonWidgetData8, fnCommonWidgetData9, fnCommonWidgetData10));
 
-    fnCommonWidgetDataDao.saveAll(fnCommonWidgetDataList);
+    fnCommonWidgetDataService.saveAll(fnCommonWidgetDataList);
 
     // fn_language table
     //TODO fix china text
     FnLanguage language1 = new FnLanguage("English", "EN");
     FnLanguage language2 = new FnLanguage("简体ä¸\u00ADæ–‡", "CN");
 
-    fnLanguageDao.save(language1);
-    fnLanguageDao.save(language2);
+    fnLanguageService.save(language1);
+    fnLanguageService.save(language2);
 
     // fn_display_text table
     // TODO should we change languageId from long type to FnLanguage?
@@ -754,7 +700,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         fnDisplayText18, fnDisplayText19, fnDisplayText20, fnDisplayText21, fnDisplayText22, fnDisplayText23, fnDisplayText24,
         fnDisplayText25, fnDisplayText26));
 
-    fnDisplayTextDao.saveAll(fnDisplayTexts);
+    fnDisplayTextService.saveAll(fnDisplayTexts);
 
     // fn_function table
 
@@ -792,7 +738,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         menuJobDesigner, menuLogout, menuMap, menuNotes, menuProcess, menuProfile, menuProfileCreate, menuProfileImport,
         menuReports, menuSample, menuTab, menuTask, menuTaskSearch, menuWebAnalytics, saveNotification, viewReports));
 
-    fnFunctionDao.saveAll(fnFunctions);
+    fnFunctionService.saveAll(fnFunctions);
 
     // fn_lu_activity table
 
@@ -830,7 +776,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         activity16, activity17, activity18, activity19, activity20, activity21, activity22, activity23, activity24, activity25,
         tabAccess, activity27, activity28));
 
-    fnLuActivityDao.saveAll(luActivities);
+    fnLuActivityService.saveAll(luActivities);
 
     //fn_lu_alert_method table
 
@@ -842,19 +788,19 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnLuAlertMethod> alertMethods = new ArrayList<>(Arrays.asList(alertMethod1, alertMethod2, alertMethod3, alertMethod4, alertMethod5));
 
-    fnLuAlertMethodDao.saveAll(alertMethods);
+    fnLuAlertMethodService.saveAll(alertMethods);
 
     // fn_lu_menu_set table
 
     FnLuMenuSet menuSet = FnLuMenuSet.builder().menuSetCd("APP").menuSetName("Application Menu").build();
 
-    fnLuMenuSetDao.save(menuSet);
+    fnLuMenuSetService.save(menuSet);
 
     // fn_lu_tab_set table
 
     FnLuTabSet fnLuTabSet = FnLuTabSet.builder().tabSetCd("APP").tabSetName("Application Tabs").build();
 
-    fnLuTabSetDao.save(fnLuTabSet);
+    fnLuTabSetService.save(fnLuTabSet);
 
     // fn_lu_priority table
 
@@ -866,7 +812,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnLuPriority> priorities = new ArrayList<>(Arrays.asList(low, normal, high, urgent, fatal));
 
-    fnLuPriorityDao.saveAll(priorities);
+    fnLuPriorityService.saveAll(priorities);
 
     // fn_lu_timezone table
 
@@ -880,7 +826,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnLuTimezone> timezones = new ArrayList<>(Arrays.asList(USEastern, USCentral, USMountain, USArizona, USPacific, USAlaska, USHawaii));
 
-    fnLuTimezoneDao.saveAll(timezones);
+    fnLuTimezoneService.saveAll(timezones);
 
     // fn_menu table
 
@@ -901,7 +847,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnMenu> fnMenus = new ArrayList<>(Arrays.asList(menu1, menu2, menu3, menu4, menu5, menu6, menu7, menu8, menu9, menu10, menu11, menu12, menu13, menu14));
 
-    fnMenuDao.saveAll(fnMenus);
+    fnMenuService.saveAll(fnMenus);
 
     // fn_menu_functional table
 
@@ -953,7 +899,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         menuFunctional313, menuFunctional316, menuFunctional148, menuFunctional317, menuFunctional318, menuFunctional319));
 
 
-    fnMenuFunctionalDao.saveAll(menuFunctionals);
+    fnMenuFunctionalService.saveAll(menuFunctionals);
 
     // fn_menu_functional_ancestors table
 
@@ -1086,7 +1032,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         ancestors150, ancestors151, ancestors152, ancestors158, ancestors159, ancestors160, ancestors161, ancestors162,
         ancestors163, ancestors164, ancestors165, ancestors166, ancestors167, ancestors168, ancestors169));
 
-    fnMenuFunctionalAncestorsDao.saveAll(ancestors);
+    fnMenuFunctionalAncestorsService.saveAll(ancestors);
 
     // fn_menu_functional_roles table
 
@@ -1128,7 +1074,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         functionalRoles22, functionalRoles23, functionalRoles24, functionalRoles25, functionalRoles26, functionalRoles27,
         functionalRoles39, functionalRoles40, functionalRoles42, functionalRoles43));
 
-    fnMenuFunctionalRolesDao.saveAll(functionalRoles);
+    fnMenuFunctionalRolesService.saveAll(functionalRoles);
 
     // fn_qz_job_details table
 
@@ -1142,7 +1088,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnQzJobDetails> jobDetails = new ArrayList<>(Arrays.asList(fnQzJobDetails1, fnQzJobDetails2));
 
-    fnQzJobDetailsDao.saveAll(jobDetails);
+    fnQzJobDetailsService.saveAll(jobDetails);
 
     // fn_qz_locks table
 
@@ -1151,7 +1097,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnQzLocks> locks = new ArrayList<>(Arrays.asList(fnQzLocks1, fnQzLocks2));
 
-    fnQzLocksDao.saveAll(locks);
+    fnQzLocksService.saveAll(locks);
 
     // fn_qz_scheduler_state table
 
@@ -1159,7 +1105,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         .instanceName("portal-portal-app-76c9f7bfb5-s8rhd1565254283688").lastCheckinTime(BigInteger.valueOf(1565691615399L))
         .checkinInterval(BigInteger.valueOf(20000L)).build();
 
-    fnQzSchedulerStateDao.save(schedulerState);
+    fnQzSchedulerStateService.save(schedulerState);
 
     // fn_qz_triggers table
     //TODO
@@ -1168,7 +1114,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnQzTriggers> fnQzTriggers = new ArrayList<>(Arrays.asList(trigger1, trigger2));
 
-    // fnQzTriggersDao.saveAll(fnQzTriggers);
+    // fnQzTriggersService.saveAll(fnQzTriggers);
 
     // fn_qz_cron_triggers table
     //TODO
@@ -1178,7 +1124,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnQzCronTriggers> cronTriggers = new ArrayList<>(Arrays.asList(cronTrigger1, cronTrigger2));
 
-    //fnQzCronTriggersDao.saveAll(cronTriggers);
+    //fnQzCronTriggersService.saveAll(cronTriggers);
 
     // fn_restricted_url table
     //TODO
@@ -1231,13 +1177,13 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         url26, url27, url28, url29, url30, url31, url32, url33, url34, url35, url36, url37, url38, url39, url40, url41,
         url42, url43));
 
-    //fnRestrictedUrlDao.saveAll(urls);
+    //fnRestrictedUrlService.saveAll(urls);
 
     // fn_role_composite table
     //TODO
     FnRoleComposite roleComposite = FnRoleComposite.builder().parentRoles(fnRole1).childRoles(fnRole16).build();
 
-    //fnRoleCompositeDao.save(roleComposite);
+    //fnRoleCompositeService.save(roleComposite);
 
     // fn_role_function table
 
@@ -1283,7 +1229,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         roleFunction23, roleFunction24, roleFunction25, roleFunction26, roleFunction27, roleFunction28, roleFunction29,
         roleFunction30, roleFunction31, roleFunction32, roleFunction33, roleFunction34));
 
-    fnRoleFunctionDao.saveAll(roleFunctions);
+    fnRoleFunctionService.saveAll(roleFunctions);
 
 
     // fn_shared_context table
@@ -1304,7 +1250,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
     List<FnSharedContext> sharedContexts = new ArrayList<>(Arrays.asList(sharedContext1, sharedContext2, sharedContext3,
         sharedContext4, sharedContext5, sharedContext6, sharedContext7, sharedContext8, sharedContext9, sharedContext10, sharedContext11, sharedContext12));
 
-    fnSharedContextDao.saveAll(sharedContexts);
+    fnSharedContextService.saveAll(sharedContexts);
 
     // fn_tab table
 
@@ -1319,7 +1265,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnTab> fnTabs = new ArrayList<>(Arrays.asList(TAB1, TAB2, TAB2_SUB1, TAB2_SUB1_S1, TAB2_SUB2, TAB2_SUB3, TAB3, TAB4));
 
-    fnTabDao.saveAll(fnTabs);
+    fnTabService.saveAll(fnTabs);
 
     // fn_tab_selected table
 
@@ -1337,7 +1283,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
     List<FnTabSelected> tabSelecteds = new ArrayList<>(Arrays.asList(tabSelected1, tabSelected2, tabSelected3, tabSelected4,
         tabSelected5, tabSelected6, tabSelected7, tabSelected8, tabSelected9, tabSelected10));
 
-//    fnTabSelectedDao.saveAll(tabSelecteds);
+//    fnTabSelectedService.saveAll(tabSelecteds);
 
     // fn_user table
 
@@ -1356,13 +1302,13 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnUser> fnUsers = new ArrayList<>(Arrays.asList(fnUser1, fnUser2, fnUser3, fnUser4, fnUser5, fnUser6, fnUser7, fnUser8, fnUser9, fnUser10, fnUser11, fnUser12));
 
-    fnUserDao.saveAll(fnUsers);
+    fnUserService.saveAll(fnUsers);
 
     // ep_pers_user_app_sort table
 
     EpPersUserAppSort appSort = EpPersUserAppSort.builder().userID(fnUser1).sortPref(0).build();
 
-    epPersUserAppSortDao.save(appSort);
+    epPersUserAppSortService.save(appSort);
 
     // fn_pers_user_app_sel table
 
@@ -1373,7 +1319,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnPersUserAppSel> appSels = new ArrayList<>(Arrays.asList(appSel1, appSel2, appSel3, appSel4));
 
-    fnPersUserAppSelDao.saveAll(appSels);
+    fnPersUserAppSelService.saveAll(appSels);
 
     // fn_audit_log table
 
@@ -1387,7 +1333,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
 
     List<FnAuditLog> auditLogs = new ArrayList<>(Arrays.asList(fnAuditLog1, fnAuditLog2, fnAuditLog3, fnAuditLog4, fnAuditLog5, fnAuditLog6, fnAuditLog7));
 
-    fnAuditLogDao.saveAll(auditLogs);
+    fnAuditLogService.saveAll(auditLogs);
 
     // fn_user_role table
 
@@ -1437,7 +1383,7 @@ public class DBInitializingBean implements org.springframework.beans.factory.Ini
         userRole25, userRole26, userRole27, userRole28, userRole29, userRole30, userRole31, userRole32, userRole33, userRole34,
         userRole35, userRole36, userRole37, userRole38, userRole39));
 
-    fnUserRoleDao.saveAll(userRoles);
+    fnUserRoleService.saveAll(userRoles);
 
 
   }
index a0542ec..5fd919b 100644 (file)
@@ -40,7 +40,7 @@
 
 package org.onap.portal.configuration;
 
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.user.FnUserService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.context.annotation.Configuration;
 import org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder;
index f3b3818..9360984 100644 (file)
 
 package org.onap.portal.configuration;
 
-import org.onap.portal.dao.fn.FnFunctionDao;
+import org.onap.portal.service.function.FnFunctionService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.context.annotation.ComponentScan;
+import org.springframework.context.annotation.Configuration;
 import org.springframework.core.Ordered;
 import org.springframework.web.servlet.config.annotation.EnableWebMvc;
 import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
@@ -52,11 +53,11 @@ import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
 @ComponentScan("org.springframework.security.samples.mvc")
 public class WebMvcConfiguration implements WebMvcConfigurer {
 
-       private final FnFunctionDao fnFunctionDao;
+       private final FnFunctionService fnFunctionService;
 
        @Autowired
-       public WebMvcConfiguration(FnFunctionDao fnFunctionDao) {
-              this.fnFunctionDao = fnFunctionDao;
+       public WebMvcConfiguration(FnFunctionService fnFunctionService) {
+              this.fnFunctionService = fnFunctionService;
        }
 
        @Override
index 4a25e61..28c21d3 100644 (file)
@@ -50,8 +50,8 @@ import org.onap.portal.domain.dto.PortalRestStatusEnum;
 import org.onap.portal.domain.dto.fn.FnLanguageDto;
 import org.onap.portal.domain.mapper.FnLanguageMapper;
 import org.onap.portal.domain.mapper.FnUserMapper;
-import org.onap.portal.service.fn.FnLanguageService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.language.FnLanguageService;
+import org.onap.portal.service.user.FnUserService;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
index 571ab20..3f05b0a 100644 (file)
@@ -45,7 +45,7 @@ import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.dto.PortalRestResponse;
 import org.onap.portal.domain.dto.PortalRestStatusEnum;
 import org.onap.portal.domain.dto.transport.ProfileDetail;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.user.FnUserService;
 import org.onap.portal.validation.DataValidator;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.onap.portalsdk.core.onboarding.util.CipherUtil;
index dbba777..1a2cb5d 100644 (file)
@@ -66,8 +66,8 @@ import org.onap.portal.logging.aop.EPEELFLoggerAdvice;
 import org.onap.portal.logging.logic.EPLogUtil;
 import org.onap.portal.service.AdminRolesService;
 import org.onap.portal.service.ApplicationsRestClientService;
-import org.onap.portal.service.fn.FnUserRoleService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.userRole.FnUserRoleService;
+import org.onap.portal.service.user.FnUserService;
 import org.onap.portal.utils.EPCommonSystemProperties;
 import org.onap.portal.utils.EcompPortalUtils;
 import org.onap.portal.utils.PortalConstants;
index 5977944..93d6dd5 100644 (file)
@@ -59,9 +59,9 @@ import org.onap.portal.domain.dto.ecomp.WidgetParameterResult;
 import org.onap.portal.domain.dto.ecomp.WidgetServiceHeaders;
 import org.onap.portal.logging.aop.EPAuditLog;
 import org.onap.portal.service.WidgetMService;
-import org.onap.portal.service.ep.EpMicroserviceParameterService;
-import org.onap.portal.service.ep.EpWidgetCatalogParameterService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.microserviceParameter.EpMicroserviceParameterService;
+import org.onap.portal.service.widgetCatalogParameter.EpWidgetCatalogParameterService;
+import org.onap.portal.service.user.FnUserService;
 import org.onap.portal.utils.EPCommonSystemProperties;
 import org.onap.portal.utils.EcompPortalUtils;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
index 6a92fbc..db7039f 100644 (file)
@@ -50,12 +50,10 @@ import org.onap.portal.domain.dto.transport.FieldsValidator;
 import org.onap.portal.domain.dto.transport.OnboardingWidget;
 import org.onap.portal.domain.dto.transport.WidgetCatalogPersonalization;
 import org.onap.portal.logging.aop.EPAuditLog;
-import org.onap.portal.service.AdminRolesService;
 import org.onap.portal.service.PersUserWidgetService;
-import org.onap.portal.service.WidgetService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.widget.WidgetService;
+import org.onap.portal.service.user.FnUserService;
 import org.onap.portal.utils.EcompPortalUtils;
-import org.onap.portal.validation.DataValidator;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.context.annotation.EnableAspectJAutoProxy;
index 2c7151a..9c00b7a 100644 (file)
@@ -50,7 +50,7 @@ import javax.servlet.http.HttpServletRequest;
 import org.onap.portal.domain.db.fn.FnApp;
 import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.service.AppsCacheService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.user.FnUserService;
 import org.onap.portal.utils.EPCommonSystemProperties;
 import org.onap.portal.utils.EcompPortalUtils;
 import org.onap.portalsdk.core.exception.SessionExpiredException;
index 8049cd6..187e175 100644 (file)
@@ -57,7 +57,6 @@ import java.util.Set;
 import java.util.SortedSet;
 import java.util.TreeSet;
 import java.util.stream.Collectors;
-import javax.annotation.PostConstruct;
 import javax.persistence.EntityManager;
 import javax.persistence.Query;
 import javax.persistence.Tuple;
@@ -96,15 +95,15 @@ import org.onap.portal.exception.DeleteDomainObjectFailedException;
 import org.onap.portal.exception.SyncUserRolesException;
 import org.onap.portal.logging.format.EPAppMessagesEnum;
 import org.onap.portal.logging.logic.EPLogUtil;
-import org.onap.portal.service.ep.EpAppFunctionService;
-import org.onap.portal.service.ep.EpUserRolesRequestDetService;
-import org.onap.portal.service.ep.EpUserRolesRequestService;
-import org.onap.portal.service.fn.FnAppService;
-import org.onap.portal.service.fn.FnMenuFunctionalRolesService;
-import org.onap.portal.service.fn.FnMenuFunctionalService;
-import org.onap.portal.service.fn.FnRoleService;
-import org.onap.portal.service.fn.FnUserRoleService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.appFunction.EpAppFunctionService;
+import org.onap.portal.service.userRolesRequestDet.EpUserRolesRequestDetService;
+import org.onap.portal.service.userRolesRequest.EpUserRolesRequestService;
+import org.onap.portal.service.app.FnAppService;
+import org.onap.portal.service.menuFunctionalRoles.FnMenuFunctionalRolesService;
+import org.onap.portal.service.menuFunctional.FnMenuFunctionalService;
+import org.onap.portal.service.role.FnRoleService;
+import org.onap.portal.service.userRole.FnUserRoleService;
+import org.onap.portal.service.user.FnUserService;
 import org.onap.portal.utils.EPCommonSystemProperties;
 import org.onap.portal.utils.EPUserUtils;
 import org.onap.portal.utils.EcompPortalUtils;
@@ -223,7 +222,7 @@ public class AdminRolesService {
     return false;
   }
 
-  boolean isUser(FnUser user) {
+  public boolean isUser(FnUser user) {
     try {
       FnUser currentUser = fnUserService.getUser(user.getId()).orElseThrow(Exception::new);
       if (currentUser != null && currentUser.getId() != null) {
index 83b5df9..b7dd4bf 100644 (file)
@@ -48,7 +48,7 @@ import java.util.stream.Collectors;
 import javax.annotation.PostConstruct;
 import org.onap.portal.domain.db.fn.FnApp;
 import org.onap.portal.domain.dto.transport.OnboardingApp;
-import org.onap.portal.service.fn.FnAppService;
+import org.onap.portal.service.app.FnAppService;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -35,7 +35,7 @@
  *
  * 
  */
-package org.onap.portal.service.fn.old;
+package org.onap.portal.service;
 
 import java.util.HashMap;
 import java.util.HashSet;
@@ -57,8 +57,6 @@ import org.springframework.transaction.annotation.Transactional;
 public class EPRoleFunctionService {
        @Autowired
        private DataAccessService dataAccessService;
-       
-       
 
        public DataAccessService getDataAccessService() {
                return dataAccessService;
index b673923..b9f161f 100644 (file)
@@ -59,9 +59,9 @@ import org.onap.portal.domain.dto.transport.CentralV2Role;
 import org.onap.portal.domain.dto.transport.GlobalRoleWithApplicationRoleFunction;
 import org.onap.portal.exception.RoleFunctionException;
 import org.onap.portal.logging.logic.EPLogUtil;
-import org.onap.portal.service.ep.EpAppFunctionService;
-import org.onap.portal.service.fn.FnAppService;
-import org.onap.portal.service.fn.FnRoleService;
+import org.onap.portal.service.appFunction.EpAppFunctionService;
+import org.onap.portal.service.app.FnAppService;
+import org.onap.portal.service.role.FnRoleService;
 import org.onap.portal.utils.EPCommonSystemProperties;
 import org.onap.portal.utils.EPUserUtils;
 import org.onap.portal.utils.EcompPortalUtils;
index 28d63eb..2a5d0ae 100644 (file)
@@ -43,13 +43,13 @@ package org.onap.portal.service;
 import java.util.ArrayList;
 import java.util.List;
 import java.util.stream.Collectors;
-import org.onap.portal.dao.ep.EpPersUserWidgetSelDao;
-import org.onap.portal.dao.fn.EpWidgetCatalogDao;
 import org.onap.portal.domain.db.ep.EpPersUserWidgetSel;
 import org.onap.portal.domain.db.ep.EpWidgetCatalog;
 import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.dto.ecomp.PersUserWidgetSelection;
 import org.onap.portal.domain.dto.transport.WidgetCatalogPersonalization;
+import org.onap.portal.service.persUserWidgetSel.EpPersUserWidgetSelService;
+import org.onap.portal.service.widgetCatalog.EpWidgetCatalogService;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -61,14 +61,14 @@ import org.springframework.transaction.annotation.Transactional;
 public class PersUserWidgetService {
 
        private static final Logger LOGGER = LoggerFactory.getLogger(PersUserWidgetService.class);
-       private final EpPersUserWidgetSelDao epPersUserWidgetSelDao;
-       private final EpWidgetCatalogDao epWidgetCatalogDao;
+       private final EpPersUserWidgetSelService epPersUserWidgetSelService;
+       private final EpWidgetCatalogService epWidgetCatalogService;
 
        @Autowired
-       public PersUserWidgetService(final EpPersUserWidgetSelDao epPersUserWidgetSelDao,
-               final EpWidgetCatalogDao epWidgetCatalogDao) {
-              this.epPersUserWidgetSelDao = epPersUserWidgetSelDao;
-              this.epWidgetCatalogDao = epWidgetCatalogDao;
+       public PersUserWidgetService(final EpPersUserWidgetSelService epPersUserWidgetSelService,
+               final EpWidgetCatalogService epWidgetCatalogService) {
+              this.epPersUserWidgetSelService = epPersUserWidgetSelService;
+              this.epWidgetCatalogService = epWidgetCatalogService;
        }
 
        public void setPersUserAppValue(FnUser user, WidgetCatalogPersonalization personalization) {
@@ -83,19 +83,19 @@ public class PersUserWidgetService {
               }
 
               if (persRow.getId() != null) {
-                     epPersUserWidgetSelDao.deleteById(persRow.getId());
+                     epPersUserWidgetSelService.deleteById(persRow.getId());
               }
 
               persRow.setStatusCode(personalization.getSelect() ? "S" : "H"); // Show / Hide
               EpPersUserWidgetSel epPersUserWidgetSel = new EpPersUserWidgetSel();
               epPersUserWidgetSel.setUserId(user);
               epPersUserWidgetSel.setWidgetId(
-                      epWidgetCatalogDao.findById(personalization.getWidgetId()).orElse(new EpWidgetCatalog()));
-              epPersUserWidgetSelDao.saveAndFlush(epPersUserWidgetSel);
+                      epWidgetCatalogService.findById(personalization.getWidgetId()).orElse(new EpWidgetCatalog()));
+              epPersUserWidgetSelService.saveAndFlush(epPersUserWidgetSel);
        }
 
        private List<PersUserWidgetSelection> getUserWidgetSelction(FnUser user, Long widgetId) {
-              return epPersUserWidgetSelDao
+              return epPersUserWidgetSelService
                       .getEpPersUserWidgetSelForUserIdAndWidgetId(user.getId(), widgetId)
                       .orElse(new ArrayList<>())
                       .stream()
@@ -1,4 +1,4 @@
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.app;
 
 import java.util.List;
 import org.onap.portal.domain.db.fn.FnApp;
@@ -10,7 +10,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnAppDao extends JpaRepository<FnApp, Long> {
+interface FnAppDao extends JpaRepository<FnApp, Long> {
 
   @Query
   List<FnApp> getByUebKey(final @Param("uebKey") String uebKey);
  *
  */
 
-package org.onap.portal.service.fn;
+package org.onap.portal.service.app;
 
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Optional;
 import javax.persistence.EntityExistsException;
 import javax.persistence.EntityManager;
-import org.onap.portal.dao.fn.FnAppDao;
+
 import org.onap.portal.domain.db.fn.FnApp;
 import org.onap.portal.domain.dto.transport.OnboardingApp;
 import org.onap.portal.utils.EPCommonSystemProperties;
@@ -66,7 +66,7 @@ public class FnAppService {
   private final EntityManager entityManager;
 
   @Autowired
-  public FnAppService(final FnAppDao fnAppDao, EntityManager entityManager) {
+  public FnAppService(FnAppDao fnAppDao, EntityManager entityManager) {
     this.fnAppDao = fnAppDao;
     this.entityManager = entityManager;
   }
@@ -123,7 +123,7 @@ public class FnAppService {
     return result;
   }
 
-  List<FnApp> getUserRemoteApps(String id) {
+  public List<FnApp> getUserRemoteApps(String id) {
 /*    StringBuilder sb = new StringBuilder();
     sb.append("SELECT * FROM FnApp join FN_USER_ROLE ON FN_USER_ROLE.APP_ID = FN_APP.APP_ID where ");
     sb.append("FN_USER_ROLE.USER_ID = ").append(id).append(" AND FN_USER_ROLE.ROLE_ID != ")
@@ -134,4 +134,8 @@ public class FnAppService {
     List<FnApp> adminApps = query.getResultList();*/
     return new ArrayList<>();
   }
+
+  public List<FnApp> saveAll(List<FnApp> fnApps) {
+    return fnAppDao.saveAll(fnApps);
+  }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.appContactUs;
 
 import org.onap.portal.domain.db.fn.FnAppContactUs;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnAppContactUsDao extends JpaRepository<FnAppContactUs, Long> {
+interface FnAppContactUsDao extends JpaRepository<FnAppContactUs, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/appContactUs/FnAppContactUsService.java b/portal-BE/src/main/java/org/onap/portal/service/appContactUs/FnAppContactUsService.java
new file mode 100644 (file)
index 0000000..600d832
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.appContactUs;
+
+import org.onap.portal.domain.db.fn.FnAppContactUs;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnAppContactUsService {
+
+    private final FnAppContactUsDao fnAppContactUsDao;
+
+    @Autowired
+    public FnAppContactUsService(FnAppContactUsDao fnAppContactUsDao) {
+        this.fnAppContactUsDao = fnAppContactUsDao;
+    }
+
+    public List<FnAppContactUs> saveAll(List<FnAppContactUs> fnAppContactUses) {
+        return fnAppContactUsDao.saveAll(fnAppContactUses);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.appFunction;
 
 import java.util.List;
 import org.onap.portal.domain.db.ep.EpAppFunction;
@@ -50,7 +50,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface EpAppFunctionDao extends JpaRepository<EpAppFunction, Long> {
+interface EpAppFunctionDao extends JpaRepository<EpAppFunction, Long> {
 
   @Query
   List<EpAppFunction> getAppRoleFunctionList(final @Param("roleId") Long roleId, final @Param("appId") Long appId);
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.service.ep;
+package org.onap.portal.service.appFunction;
 
 import java.util.ArrayList;
 import java.util.List;
@@ -46,7 +46,7 @@ import java.util.Optional;
 import java.util.function.Function;
 import java.util.function.Predicate;
 import java.util.stream.Collectors;
-import org.onap.portal.dao.ep.EpAppFunctionDao;
+
 import org.onap.portal.domain.db.ep.EpAppFunction;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -76,4 +76,8 @@ public class EpAppFunctionService {
     List<Object> seen = new ArrayList<>();
     return t -> seen.add(keyExtractor.apply(t));
   }
+
+  public List<EpAppFunction> saveAll(List<EpAppFunction> epAppFunctions) {
+    return epAppFunctionDao.saveAll(epAppFunctions);
+  }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.appRoleFunction;
 
 import org.onap.portal.domain.db.ep.EpAppRoleFunction;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface EpAppRoleFunctionDao extends JpaRepository<EpAppRoleFunction, Integer> {
+interface EpAppRoleFunctionDao extends JpaRepository<EpAppRoleFunction, Integer> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/appRoleFunction/EpAppRoleFunctionService.java b/portal-BE/src/main/java/org/onap/portal/service/appRoleFunction/EpAppRoleFunctionService.java
new file mode 100644 (file)
index 0000000..cb5383b
--- /dev/null
@@ -0,0 +1,62 @@
+/*
+ * ============LICENSE_START==========================================
+ * ONAP Portal
+ * ===================================================================
+ * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * ===================================================================
+ * Modifications Copyright (c) 2019 Samsung
+ * ===================================================================
+ *
+ * Unless otherwise specified, all software contained herein is licensed
+ * under the Apache License, Version 2.0 (the "License");
+ * you may not use this software except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *             http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * Unless otherwise specified, all documentation contained herein is licensed
+ * under the Creative Commons License, Attribution 4.0 Intl. (the "License");
+ * you may not use this documentation except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *             https://creativecommons.org/licenses/by/4.0/
+ *
+ * Unless required by applicable law or agreed to in writing, documentation
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * ============LICENSE_END============================================
+ *
+ *
+ */
+
+package org.onap.portal.service.appRoleFunction;
+
+import org.onap.portal.domain.db.ep.EpAppRoleFunction;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class EpAppRoleFunctionService {
+
+    private final EpAppRoleFunctionDao epAppRoleFunctionDao;
+
+    @Autowired
+    public EpAppRoleFunctionService(EpAppRoleFunctionDao epAppRoleFunctionDao) {
+        this.epAppRoleFunctionDao = epAppRoleFunctionDao;
+    }
+
+    public List<EpAppRoleFunction> saveAll(List<EpAppRoleFunction> epAppRoleFunctions) {
+        return epAppRoleFunctionDao.saveAll(epAppRoleFunctions);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.auditLog;
 
 import org.onap.portal.domain.db.fn.FnAuditLog;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnAuditLogDao extends JpaRepository<FnAuditLog, Integer> {
+interface FnAuditLogDao extends JpaRepository<FnAuditLog, Integer> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/auditLog/FnAuditLogService.java b/portal-BE/src/main/java/org/onap/portal/service/auditLog/FnAuditLogService.java
new file mode 100644 (file)
index 0000000..ef51aab
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.auditLog;
+
+import org.onap.portal.domain.db.fn.FnAuditLog;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnAuditLogService {
+
+    private final FnAuditLogDao fnAuditLogDao;
+
+    @Autowired
+    public FnAuditLogService(FnAuditLogDao fnAuditLogDao) {
+        this.fnAuditLogDao = fnAuditLogDao;
+    }
+
+    public List<FnAuditLog> saveAll(List<FnAuditLog> auditLogs) {
+        return fnAuditLogDao.saveAll(auditLogs);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.basicAuthAccount;
 
 import org.onap.portal.domain.db.ep.EpBasicAuthAccount;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface EpBasicAuthAccountDao extends JpaRepository<EpBasicAuthAccount, Long> {
+interface EpBasicAuthAccountDao extends JpaRepository<EpBasicAuthAccount, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/basicAuthAccount/EpBasicAuthAccountService.java b/portal-BE/src/main/java/org/onap/portal/service/basicAuthAccount/EpBasicAuthAccountService.java
new file mode 100644 (file)
index 0000000..3b23e91
--- /dev/null
@@ -0,0 +1,20 @@
+package org.onap.portal.service.basicAuthAccount;
+
+import org.onap.portal.domain.db.ep.EpBasicAuthAccount;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class EpBasicAuthAccountService {
+
+    private final EpBasicAuthAccountDao epBasicAuthAccountDao;
+
+    @Autowired
+    public EpBasicAuthAccountService(EpBasicAuthAccountDao epBasicAuthAccountDao) {
+        this.epBasicAuthAccountDao = epBasicAuthAccountDao;
+    }
+
+    public EpBasicAuthAccount save(EpBasicAuthAccount epBasicAuthAccount) {
+        return epBasicAuthAccountDao.save(epBasicAuthAccount);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.commonWidgetData;
 
 import org.onap.portal.domain.db.fn.FnCommonWidgetData;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnCommonWidgetDataDao extends JpaRepository<FnCommonWidgetData, Long> {
+interface FnCommonWidgetDataDao extends JpaRepository<FnCommonWidgetData, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/commonWidgetData/FnCommonWidgetDataService.java b/portal-BE/src/main/java/org/onap/portal/service/commonWidgetData/FnCommonWidgetDataService.java
new file mode 100644 (file)
index 0000000..940d3ad
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.commonWidgetData;
+
+import org.onap.portal.domain.db.fn.FnCommonWidgetData;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnCommonWidgetDataService {
+
+    private final FnCommonWidgetDataDao fnCommonWidgetDataDao;
+
+    @Autowired
+    public FnCommonWidgetDataService(FnCommonWidgetDataDao fnCommonWidgetDataDao) {
+        this.fnCommonWidgetDataDao = fnCommonWidgetDataDao;
+    }
+
+    public List<FnCommonWidgetData> saveAll(List<FnCommonWidgetData> fnCommonWidgetDataList) {
+        return fnCommonWidgetDataDao.saveAll(fnCommonWidgetDataList);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.displayText;
 
 import org.onap.portal.domain.db.fn.FnDisplayText;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnDisplayTextDao extends JpaRepository<FnDisplayText, Long> {
+interface FnDisplayTextDao extends JpaRepository<FnDisplayText, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/displayText/FnDisplayTextService.java b/portal-BE/src/main/java/org/onap/portal/service/displayText/FnDisplayTextService.java
new file mode 100644 (file)
index 0000000..45870ca
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.displayText;
+
+import org.onap.portal.domain.db.fn.FnDisplayText;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnDisplayTextService {
+
+    private final FnDisplayTextDao fnDisplayTextDao;
+
+    @Autowired
+    public FnDisplayTextService(FnDisplayTextDao fnDisplayTextDao) {
+        this.fnDisplayTextDao = fnDisplayTextDao;
+    }
+
+    public List<FnDisplayText> saveAll(List<FnDisplayText> fnDisplayTexts) {
+        return fnDisplayTextDao.saveAll(fnDisplayTexts);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.function;
 
 import org.onap.portal.domain.db.fn.FnFunction;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnFunctionDao extends JpaRepository<FnFunction, String> {
+interface FnFunctionDao extends JpaRepository<FnFunction, String> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/function/FnFunctionService.java b/portal-BE/src/main/java/org/onap/portal/service/function/FnFunctionService.java
new file mode 100644 (file)
index 0000000..d2361be
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.function;
+
+import org.onap.portal.domain.db.fn.FnFunction;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnFunctionService {
+
+    private final FnFunctionDao fnFunctionDao;
+
+    @Autowired
+    public FnFunctionService(FnFunctionDao fnFunctionDao) {
+        this.fnFunctionDao = fnFunctionDao;
+    }
+
+    public List<FnFunction> saveAll(List<FnFunction> fnFunctions) {
+        return fnFunctionDao.saveAll(fnFunctions);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.language;
 
 import org.onap.portal.domain.db.fn.FnLanguage;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -49,7 +49,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnLanguageDao extends JpaRepository<FnLanguage, Long> {
+interface FnLanguageDao extends JpaRepository<FnLanguage, Long> {
   @Query
   FnLanguage getByLanguageAlias(final @Param("alias") String alias);
 
  *
  */
 
-package org.onap.portal.service.fn;
+package org.onap.portal.service.language;
 
 import java.security.Principal;
 import java.util.List;
 import java.util.Optional;
-import org.onap.portal.dao.fn.FnLanguageDao;
+
 import org.onap.portal.domain.db.fn.FnLanguage;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.context.annotation.EnableAspectJAutoProxy;
@@ -70,4 +70,12 @@ public class FnLanguageService {
        public FnLanguage save(final FnLanguage fnLanguage){
               return fnLanguageDao.saveAndFlush(fnLanguage);
        }
+
+       public FnLanguage getByLanguageAlias(String language) {
+              return fnLanguageDao.getByLanguageAlias(language);
+       }
+
+       public void delete(FnLanguage fnLanguage) {
+              fnLanguageDao.delete(fnLanguage);
+       }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.luActivity;
 
 import org.onap.portal.domain.db.fn.FnLuActivity;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnLuActivityDao extends JpaRepository<FnLuActivity, String> {
+interface FnLuActivityDao extends JpaRepository<FnLuActivity, String> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/luActivity/FnLuActivityService.java b/portal-BE/src/main/java/org/onap/portal/service/luActivity/FnLuActivityService.java
new file mode 100644 (file)
index 0000000..0ce6800
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.luActivity;
+
+import org.onap.portal.domain.db.fn.FnLuActivity;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnLuActivityService {
+
+    private final FnLuActivityDao fnLuActivityDao;
+
+    @Autowired
+    public FnLuActivityService(FnLuActivityDao fnLuActivityDao) {
+        this.fnLuActivityDao = fnLuActivityDao;
+    }
+
+    public List<FnLuActivity> saveAll(List<FnLuActivity> luActivities) {
+        return fnLuActivityDao.saveAll(luActivities);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.luAlertMethod;
 
 import org.onap.portal.domain.db.fn.FnLuAlertMethod;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnLuAlertMethodDao extends JpaRepository<FnLuAlertMethod, String> {
+interface FnLuAlertMethodDao extends JpaRepository<FnLuAlertMethod, String> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/luAlertMethod/FnLuAlertMethodService.java b/portal-BE/src/main/java/org/onap/portal/service/luAlertMethod/FnLuAlertMethodService.java
new file mode 100644 (file)
index 0000000..649ea98
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.luAlertMethod;
+
+import org.onap.portal.domain.db.fn.FnLuAlertMethod;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnLuAlertMethodService {
+
+    private final FnLuAlertMethodDao fnLuAlertMethodDao;
+
+    @Autowired
+    public FnLuAlertMethodService(FnLuAlertMethodDao fnLuAlertMethodDao) {
+        this.fnLuAlertMethodDao = fnLuAlertMethodDao;
+    }
+
+    public List<FnLuAlertMethod> saveAll(List<FnLuAlertMethod> alertMethods) {
+        return fnLuAlertMethodDao.saveAll(alertMethods);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.luMenuSet;
 
 import org.onap.portal.domain.db.fn.FnLuMenuSet;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnLuMenuSetDao extends JpaRepository<FnLuMenuSet, String> {
+interface FnLuMenuSetDao extends JpaRepository<FnLuMenuSet, String> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/luMenuSet/FnLuMenuSetService.java b/portal-BE/src/main/java/org/onap/portal/service/luMenuSet/FnLuMenuSetService.java
new file mode 100644 (file)
index 0000000..3433cde
--- /dev/null
@@ -0,0 +1,20 @@
+package org.onap.portal.service.luMenuSet;
+
+import org.onap.portal.domain.db.fn.FnLuMenuSet;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class FnLuMenuSetService {
+
+    private final FnLuMenuSetDao fnLuMenuSetDao;
+
+    @Autowired
+    public FnLuMenuSetService(FnLuMenuSetDao fnLuMenuSetDao) {
+        this.fnLuMenuSetDao = fnLuMenuSetDao;
+    }
+
+    public FnLuMenuSet save(FnLuMenuSet menuSet) {
+        return fnLuMenuSetDao.save(menuSet);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.luPriority;
 
 import org.onap.portal.domain.db.fn.FnLuPriority;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnLuPriorityDao extends JpaRepository<FnLuPriority, Long> {
+interface FnLuPriorityDao extends JpaRepository<FnLuPriority, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/luPriority/FnLuPriorityService.java b/portal-BE/src/main/java/org/onap/portal/service/luPriority/FnLuPriorityService.java
new file mode 100644 (file)
index 0000000..998589c
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.luPriority;
+
+import org.onap.portal.domain.db.fn.FnLuPriority;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnLuPriorityService {
+
+    private final FnLuPriorityDao fnLuPriorityDao;
+
+    @Autowired
+    public FnLuPriorityService(FnLuPriorityDao fnLuPriorityDao) {
+        this.fnLuPriorityDao = fnLuPriorityDao;
+    }
+
+    public List<FnLuPriority> saveAll(List<FnLuPriority> priorities) {
+        return fnLuPriorityDao.saveAll(priorities);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.luTabSet;
 
 import org.onap.portal.domain.db.fn.FnLuTabSet;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnLuTabSetDao extends JpaRepository<FnLuTabSet, String> {
+interface FnLuTabSetDao extends JpaRepository<FnLuTabSet, String> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/luTabSet/FnLuTabSetService.java b/portal-BE/src/main/java/org/onap/portal/service/luTabSet/FnLuTabSetService.java
new file mode 100644 (file)
index 0000000..b9c131a
--- /dev/null
@@ -0,0 +1,20 @@
+package org.onap.portal.service.luTabSet;
+
+import org.onap.portal.domain.db.fn.FnLuTabSet;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class FnLuTabSetService {
+
+    private final FnLuTabSetDao fnLuTabSetDao;
+
+    @Autowired
+    public FnLuTabSetService(FnLuTabSetDao fnLuTabSetDao) {
+        this.fnLuTabSetDao = fnLuTabSetDao;
+    }
+
+    public FnLuTabSet save(FnLuTabSet fnLuTabSet) {
+        return fnLuTabSetDao.save(fnLuTabSet);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.luTimezone;
 
 import org.onap.portal.domain.db.fn.FnLuTimezone;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnLuTimezoneDao extends JpaRepository<FnLuTimezone, Long> {
+interface FnLuTimezoneDao extends JpaRepository<FnLuTimezone, Long> {
 
 }
  *
  */
 
-package org.onap.portal.service.fn;
+package org.onap.portal.service.luTimezone;
 
+import java.util.List;
 import java.util.Optional;
-import org.onap.portal.dao.fn.FnLuTimezoneDao;
+
 import org.onap.portal.domain.db.fn.FnLuTimezone;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -60,4 +61,8 @@ public class FnLuTimezoneService {
        public Optional<FnLuTimezone> getById(Long id){
               return fnLuTimezoneDao.findById(id);
        }
+
+       public List<FnLuTimezone> saveAll(List<FnLuTimezone> timezones) {
+              return fnLuTimezoneDao.saveAll(timezones);
+       }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.menu;
 
 import org.onap.portal.domain.db.fn.FnMenu;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnMenuDao extends JpaRepository<FnMenu, Integer> {
+interface FnMenuDao extends JpaRepository<FnMenu, Integer> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/menu/FnMenuService.java b/portal-BE/src/main/java/org/onap/portal/service/menu/FnMenuService.java
new file mode 100644 (file)
index 0000000..ad7a34b
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.menu;
+
+import org.onap.portal.domain.db.fn.FnMenu;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnMenuService {
+
+    private final FnMenuDao fnMenuDao;
+
+    @Autowired
+    public FnMenuService(FnMenuDao fnMenuDao) {
+        this.fnMenuDao = fnMenuDao;
+    }
+
+    public List<FnMenu> saveAll(List<FnMenu> fnMenus) {
+        return fnMenuDao.saveAll(fnMenus);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.menuFunctional;
 
 import java.util.List;
 import org.onap.portal.domain.db.fn.FnMenuFunctional;
@@ -50,7 +50,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnMenuFunctionalDao extends JpaRepository<FnMenuFunctional, Long> {
+interface FnMenuFunctionalDao extends JpaRepository<FnMenuFunctional, Long> {
   @Query
   List<FnMenuFunctional> retrieveByMenuId(final @Param("menuId") Long menuId);
 }
  *
  */
 
-package org.onap.portal.service.fn;
+package org.onap.portal.service.menuFunctional;
 
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Optional;
-import org.onap.portal.dao.fn.FnMenuFunctionalDao;
+
 import org.onap.portal.domain.db.fn.FnMenuFunctional;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -62,4 +62,7 @@ public class FnMenuFunctionalService {
     return Optional.of(fnMenuFunctionalDao.retrieveByMenuId(menuId)).orElse(new ArrayList<>());
   }
 
+  public List<FnMenuFunctional> saveAll(List<FnMenuFunctional> menuFunctionals) {
+    return fnMenuFunctionalDao.saveAll(menuFunctionals);
+  }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.menuFunctionalAncestors;
 
 import org.onap.portal.domain.db.fn.FnMenuFunctionalAncestors;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnMenuFunctionalAncestorsDao extends JpaRepository<FnMenuFunctionalAncestors, Integer> {
+interface FnMenuFunctionalAncestorsDao extends JpaRepository<FnMenuFunctionalAncestors, Integer> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/menuFunctionalAncestors/FnMenuFunctionalAncestorsService.java b/portal-BE/src/main/java/org/onap/portal/service/menuFunctionalAncestors/FnMenuFunctionalAncestorsService.java
new file mode 100644 (file)
index 0000000..070169f
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.menuFunctionalAncestors;
+
+import org.onap.portal.domain.db.fn.FnMenuFunctionalAncestors;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnMenuFunctionalAncestorsService {
+
+    private final FnMenuFunctionalAncestorsDao fnMenuFunctionalAncestorsDao;
+
+    @Autowired
+    public FnMenuFunctionalAncestorsService(FnMenuFunctionalAncestorsDao fnMenuFunctionalAncestorsDao) {
+        this.fnMenuFunctionalAncestorsDao = fnMenuFunctionalAncestorsDao;
+    }
+
+    public List<FnMenuFunctionalAncestors> saveAll(List<FnMenuFunctionalAncestors> ancestors) {
+        return fnMenuFunctionalAncestorsDao.saveAll(ancestors);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.menuFunctionalRoles;
 
 import java.util.List;
 import org.onap.portal.domain.db.fn.FnMenuFunctionalRoles;
@@ -50,7 +50,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnMenuFunctionalRolesDao extends JpaRepository<FnMenuFunctionalRoles, Long> {
+interface FnMenuFunctionalRolesDao extends JpaRepository<FnMenuFunctionalRoles, Long> {
 
   @Query
   List<FnMenuFunctionalRoles> retrieveByRoleId(final @Param("roleId") Long roleId);
  *
  */
 
-package org.onap.portal.service.fn;
+package org.onap.portal.service.menuFunctionalRoles;
 
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Optional;
-import org.onap.portal.dao.fn.FnMenuFunctionalRolesDao;
+
 import org.onap.portal.domain.db.fn.FnMenuFunctionalRoles;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -73,4 +73,7 @@ public class FnMenuFunctionalRolesService {
     return Optional.of(fnMenuFunctionalRolesDao.retrieveByMenuId(menuId)).orElse(new ArrayList<>());
   }
 
+  public List<FnMenuFunctionalRoles> saveAll(List<FnMenuFunctionalRoles> functionalRoles) {
+    return fnMenuFunctionalRolesDao.saveAll(functionalRoles);
+  }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.microservice;
 
 import org.onap.portal.domain.db.ep.EpMicroservice;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface EpMicroserviceDao extends JpaRepository<EpMicroservice, Long> {
+interface EpMicroserviceDao extends JpaRepository<EpMicroservice, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/microservice/EpMicroserviceService.java b/portal-BE/src/main/java/org/onap/portal/service/microservice/EpMicroserviceService.java
new file mode 100644 (file)
index 0000000..1b999f8
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.microservice;
+
+import org.onap.portal.domain.db.ep.EpMicroservice;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class EpMicroserviceService {
+
+    private final EpMicroserviceDao epMicroserviceDao;
+
+    @Autowired
+    public EpMicroserviceService(EpMicroserviceDao epMicroserviceDao) {
+        this.epMicroserviceDao = epMicroserviceDao;
+    }
+
+    public List<EpMicroservice> saveAll(List<EpMicroservice> epMicroservices) {
+        return epMicroserviceDao.saveAll(epMicroservices);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.microserviceParameter;
 
 import java.util.List;
 import org.onap.portal.domain.db.ep.EpMicroserviceParameter;
@@ -50,7 +50,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface EpMicroserviceParameterDao extends JpaRepository<EpMicroserviceParameter, Long> {
+interface EpMicroserviceParameterDao extends JpaRepository<EpMicroserviceParameter, Long> {
 
        @Query
        void deleteByServiceId(@Param("SERVICEID") Long userId);
  *
  */
 
-package org.onap.portal.service.ep;
+package org.onap.portal.service.microserviceParameter;
 
 import java.util.ArrayList;
 import java.util.List;
 import java.util.stream.Collectors;
 import org.hibernate.criterion.Criterion;
 import org.hibernate.criterion.Restrictions;
-import org.onap.portal.dao.ep.EpMicroserviceParameterDao;
 import org.onap.portal.domain.db.ep.EpMicroserviceParameter;
 import org.onap.portal.domain.dto.ecomp.MicroserviceParameter;
+import org.onap.portal.service.widgetCatalogParameter.EpWidgetCatalogParameterService;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -101,4 +101,8 @@ public class EpMicroserviceParameterService {
                      return false;
               }
        }
+
+       public List<EpMicroserviceParameter> saveAll(List<EpMicroserviceParameter> epMicroserviceParameters) {
+              return epMicroserviceParameterDao.saveAll(epMicroserviceParameters);
+       }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.persUserAppSel;
 
 import org.onap.portal.domain.db.fn.FnPersUserAppSel;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnPersUserAppSelDao extends JpaRepository<FnPersUserAppSel, Long> {
+interface FnPersUserAppSelDao extends JpaRepository<FnPersUserAppSel, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/persUserAppSel/FnPersUserAppSelService.java b/portal-BE/src/main/java/org/onap/portal/service/persUserAppSel/FnPersUserAppSelService.java
new file mode 100644 (file)
index 0000000..41c281d
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.persUserAppSel;
+
+import org.onap.portal.domain.db.fn.FnPersUserAppSel;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnPersUserAppSelService {
+
+    private final FnPersUserAppSelDao fnPersUserAppSelDao;
+
+    @Autowired
+    public FnPersUserAppSelService(FnPersUserAppSelDao fnPersUserAppSelDao) {
+        this.fnPersUserAppSelDao = fnPersUserAppSelDao;
+    }
+
+    public List<FnPersUserAppSel> saveAll(List<FnPersUserAppSel> appSels) {
+        return fnPersUserAppSelDao.saveAll(appSels);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.persUserAppSort;
 
 import org.onap.portal.domain.db.ep.EpPersUserAppSort;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface EpPersUserAppSortDao extends JpaRepository<EpPersUserAppSort, Long> {
+interface EpPersUserAppSortDao extends JpaRepository<EpPersUserAppSort, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/persUserAppSort/EpPersUserAppSortService.java b/portal-BE/src/main/java/org/onap/portal/service/persUserAppSort/EpPersUserAppSortService.java
new file mode 100644 (file)
index 0000000..05d32e6
--- /dev/null
@@ -0,0 +1,20 @@
+package org.onap.portal.service.persUserAppSort;
+
+import org.onap.portal.domain.db.ep.EpPersUserAppSort;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class EpPersUserAppSortService {
+
+    private final EpPersUserAppSortDao epPersUserAppSortDao;
+
+    @Autowired
+    public EpPersUserAppSortService(EpPersUserAppSortDao epPersUserAppSortDao) {
+        this.epPersUserAppSortDao = epPersUserAppSortDao;
+    }
+
+    public EpPersUserAppSort save(EpPersUserAppSort appSort) {
+        return epPersUserAppSortDao.save(appSort);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.persUserWidgetSel;
 
 import java.util.List;
 import java.util.Optional;
@@ -51,7 +51,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface EpPersUserWidgetSelDao extends JpaRepository<EpPersUserWidgetSel, Long> {
+interface EpPersUserWidgetSelDao extends JpaRepository<EpPersUserWidgetSel, Long> {
 
        @Query
        Optional<List<EpPersUserWidgetSel>> getEpPersUserWidgetSelForUserIdAndWidgetId(@Param("USERID") Long userId, @Param("WIDGETID") Long widgetId);
diff --git a/portal-BE/src/main/java/org/onap/portal/service/persUserWidgetSel/EpPersUserWidgetSelService.java b/portal-BE/src/main/java/org/onap/portal/service/persUserWidgetSel/EpPersUserWidgetSelService.java
new file mode 100644 (file)
index 0000000..cd940d1
--- /dev/null
@@ -0,0 +1,32 @@
+package org.onap.portal.service.persUserWidgetSel;
+
+import org.onap.portal.domain.db.ep.EpPersUserWidgetSel;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Optional;
+
+@Service
+public class EpPersUserWidgetSelService {
+
+    private final EpPersUserWidgetSelDao epPersUserWidgetSelDao;
+
+    @Autowired
+    public EpPersUserWidgetSelService(EpPersUserWidgetSelDao epPersUserWidgetSelDao) {
+        this.epPersUserWidgetSelDao = epPersUserWidgetSelDao;
+    }
+
+    public void deleteById(Long id) {
+        epPersUserWidgetSelDao.deleteById(id);
+    }
+
+    public EpPersUserWidgetSel saveAndFlush(EpPersUserWidgetSel epPersUserWidgetSel) {
+        return epPersUserWidgetSelDao.saveAndFlush(epPersUserWidgetSel);
+    }
+
+    public Optional<List<EpPersUserWidgetSel>> getEpPersUserWidgetSelForUserIdAndWidgetId(Long id, Long widgetId) {
+        return epPersUserWidgetSelDao.getEpPersUserWidgetSelForUserIdAndWidgetId(id, widgetId);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.qzCronTriggers;
 
 import org.onap.portal.domain.db.fn.FnQzCronTriggers;
 import org.onap.portal.domain.db.fn.compositePK.FnQzTriggersId;
@@ -48,6 +48,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnQzCronTriggersDao extends JpaRepository<FnQzCronTriggers, FnQzTriggersId> {
+interface FnQzCronTriggersDao extends JpaRepository<FnQzCronTriggers, FnQzTriggersId> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/qzCronTriggers/FnQzCronTriggersService.java b/portal-BE/src/main/java/org/onap/portal/service/qzCronTriggers/FnQzCronTriggersService.java
new file mode 100644 (file)
index 0000000..8cfdef2
--- /dev/null
@@ -0,0 +1,15 @@
+package org.onap.portal.service.qzCronTriggers;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class FnQzCronTriggersService {
+
+    private final FnQzCronTriggersDao fnQzCronTriggersDao;
+
+    @Autowired
+    public FnQzCronTriggersService(FnQzCronTriggersDao fnQzCronTriggersDao) {
+        this.fnQzCronTriggersDao = fnQzCronTriggersDao;
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.qzJobDetails;
 
 import org.onap.portal.domain.db.fn.FnQzJobDetails;
 import org.onap.portal.domain.db.fn.FnQzJobDetails.FnQzJobDetailsID;
@@ -48,6 +48,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnQzJobDetailsDao extends JpaRepository<FnQzJobDetails, FnQzJobDetailsID> {
+interface FnQzJobDetailsDao extends JpaRepository<FnQzJobDetails, FnQzJobDetailsID> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/qzJobDetails/FnQzJobDetailsService.java b/portal-BE/src/main/java/org/onap/portal/service/qzJobDetails/FnQzJobDetailsService.java
new file mode 100644 (file)
index 0000000..f83f8e7
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.qzJobDetails;
+
+import org.onap.portal.domain.db.fn.FnQzJobDetails;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnQzJobDetailsService {
+
+    private final FnQzJobDetailsDao fnQzJobDetailsDao;
+
+    @Autowired
+    public FnQzJobDetailsService(FnQzJobDetailsDao fnQzJobDetailsDao) {
+        this.fnQzJobDetailsDao = fnQzJobDetailsDao;
+    }
+
+    public List<FnQzJobDetails> saveAll(List<FnQzJobDetails> jobDetails) {
+        return fnQzJobDetailsDao.saveAll(jobDetails);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.qzLocks;
 
 import org.onap.portal.domain.db.fn.FnQzLocks;
 import org.onap.portal.domain.db.fn.FnQzLocks.FnQzLocksID;
@@ -48,6 +48,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnQzLocksDao extends JpaRepository<FnQzLocks, FnQzLocksID> {
+interface FnQzLocksDao extends JpaRepository<FnQzLocks, FnQzLocksID> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/qzLocks/FnQzLocksService.java b/portal-BE/src/main/java/org/onap/portal/service/qzLocks/FnQzLocksService.java
new file mode 100644 (file)
index 0000000..a582f6d
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.qzLocks;
+
+import org.onap.portal.domain.db.fn.FnQzLocks;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnQzLocksService {
+
+    private final FnQzLocksDao fnQzLocksDao;
+
+    @Autowired
+    public FnQzLocksService(FnQzLocksDao fnQzLocksDao) {
+        this.fnQzLocksDao = fnQzLocksDao;
+    }
+
+    public List<FnQzLocks> saveAll(List<FnQzLocks> locks) {
+        return fnQzLocksDao.saveAll(locks);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.qzSchedulerState;
 
 import org.onap.portal.domain.db.fn.FnQzSchedulerState;
 import org.onap.portal.domain.db.fn.FnQzSchedulerState.FnQzSchedulerStateID;
@@ -48,6 +48,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnQzSchedulerStateDao extends JpaRepository<FnQzSchedulerState, FnQzSchedulerStateID> {
+interface FnQzSchedulerStateDao extends JpaRepository<FnQzSchedulerState, FnQzSchedulerStateID> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/qzSchedulerState/FnQzSchedulerStateService.java b/portal-BE/src/main/java/org/onap/portal/service/qzSchedulerState/FnQzSchedulerStateService.java
new file mode 100644 (file)
index 0000000..5451979
--- /dev/null
@@ -0,0 +1,20 @@
+package org.onap.portal.service.qzSchedulerState;
+
+import org.onap.portal.domain.db.fn.FnQzSchedulerState;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class FnQzSchedulerStateService {
+
+    private final FnQzSchedulerStateDao fnQzSchedulerStateDao;
+
+    @Autowired
+    public FnQzSchedulerStateService(FnQzSchedulerStateDao fnQzSchedulerStateDao) {
+        this.fnQzSchedulerStateDao = fnQzSchedulerStateDao;
+    }
+
+    public FnQzSchedulerState save(FnQzSchedulerState schedulerState) {
+        return fnQzSchedulerStateDao.save(schedulerState);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.qzTriggers;
 
 import org.onap.portal.domain.db.fn.FnQzTriggers;
 import org.onap.portal.domain.db.fn.compositePK.FnQzTriggersId;
@@ -48,6 +48,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnQzTriggersDao extends JpaRepository<FnQzTriggers, FnQzTriggersId> {
+interface FnQzTriggersDao extends JpaRepository<FnQzTriggers, FnQzTriggersId> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/qzTriggers/FnQzTriggersService.java b/portal-BE/src/main/java/org/onap/portal/service/qzTriggers/FnQzTriggersService.java
new file mode 100644 (file)
index 0000000..4f175af
--- /dev/null
@@ -0,0 +1,15 @@
+package org.onap.portal.service.qzTriggers;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class FnQzTriggersService {
+
+    private final FnQzTriggersDao fnQzTriggersDao;
+
+    @Autowired
+    public FnQzTriggersService(FnQzTriggersDao fnQzTriggersDao) {
+        this.fnQzTriggersDao = fnQzTriggersDao;
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.restrictedUrl;
 
 import org.onap.portal.domain.db.fn.FnRestrictedUrl;
 import org.onap.portal.domain.db.fn.FnRestrictedUrl.FnRestrictedUrlId;
@@ -48,6 +48,5 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnRestrictedUrlDao extends JpaRepository<FnRestrictedUrl, FnRestrictedUrlId> {
-
+interface FnRestrictedUrlDao extends JpaRepository<FnRestrictedUrl, FnRestrictedUrlId> {
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/restrictedUrl/FnRestrictedUrlService.java b/portal-BE/src/main/java/org/onap/portal/service/restrictedUrl/FnRestrictedUrlService.java
new file mode 100644 (file)
index 0000000..8f04dbf
--- /dev/null
@@ -0,0 +1,15 @@
+package org.onap.portal.service.restrictedUrl;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class FnRestrictedUrlService {
+
+    private final FnRestrictedUrlDao fnRestrictedUrlDao;
+
+    @Autowired
+    public FnRestrictedUrlService(FnRestrictedUrlDao fnRestrictedUrlDao) {
+        this.fnRestrictedUrlDao = fnRestrictedUrlDao;
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.role;
 
 import java.util.List;
 import org.onap.portal.domain.db.fn.FnRole;
@@ -50,7 +50,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnRoleDao extends JpaRepository<FnRole, Long> {
+interface FnRoleDao extends JpaRepository<FnRole, Long> {
 
   @Query
   List<FnRole> retrieveAppRoleByAppRoleIdAndByAppId(final @Param("appId") Long appId,
  *
  */
 
-package org.onap.portal.service.fn;
+package org.onap.portal.service.role;
 
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Optional;
 import javax.persistence.EntityExistsException;
-import org.onap.portal.dao.fn.FnRoleDao;
+
 import org.onap.portal.domain.db.fn.FnRole;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -57,7 +57,6 @@ public class FnRoleService {
 
   private final EELFLoggerDelegate logger = EELFLoggerDelegate.getLogger(FnRoleService.class);
 
-
   private final FnRoleDao fnRoleDao;
 
   @Autowired
@@ -149,4 +148,8 @@ public class FnRoleService {
   public FnRole saveOne(final FnRole role){
     return fnRoleDao.save(role);
   }
+
+  public List<FnRole> saveAll(List<FnRole> fnRoles) {
+    return fnRoleDao.saveAll(fnRoles);
+  }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.roleComposite;
 
 import org.onap.portal.domain.db.fn.FnRoleComposite;
 import org.onap.portal.domain.db.fn.compositePK.FnRoleCompositeId;
@@ -48,6 +48,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnRoleCompositeDao extends JpaRepository<FnRoleComposite, FnRoleCompositeId> {
+interface FnRoleCompositeDao extends JpaRepository<FnRoleComposite, FnRoleCompositeId> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/roleComposite/FnRoleCompositeService.java b/portal-BE/src/main/java/org/onap/portal/service/roleComposite/FnRoleCompositeService.java
new file mode 100644 (file)
index 0000000..ed15259
--- /dev/null
@@ -0,0 +1,15 @@
+package org.onap.portal.service.roleComposite;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class FnRoleCompositeService {
+
+    private final FnRoleCompositeDao fnRoleCompositeDao;
+
+    @Autowired
+    public FnRoleCompositeService(FnRoleCompositeDao fnRoleCompositeDao) {
+        this.fnRoleCompositeDao = fnRoleCompositeDao;
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.roleFunction;
 
 import org.onap.portal.domain.db.fn.FnRoleFunction;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Transactional
 @Repository
-public interface FnRoleFunctionDao extends JpaRepository<FnRoleFunction, Long> {
+interface FnRoleFunctionDao extends JpaRepository<FnRoleFunction, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/roleFunction/FnRoleFunctionService.java b/portal-BE/src/main/java/org/onap/portal/service/roleFunction/FnRoleFunctionService.java
new file mode 100644 (file)
index 0000000..a91dee8
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.roleFunction;
+
+import org.onap.portal.domain.db.fn.FnRoleFunction;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnRoleFunctionService {
+
+    private final FnRoleFunctionDao fnRoleFunctionDao;
+
+    @Autowired
+    public FnRoleFunctionService(FnRoleFunctionDao fnRoleFunctionDao) {
+        this.fnRoleFunctionDao = fnRoleFunctionDao;
+    }
+
+    public List<FnRoleFunction> saveAll(List<FnRoleFunction> roleFunctions) {
+        return fnRoleFunctionDao.saveAll(roleFunctions);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.sharedContext;
 
 import org.onap.portal.domain.db.fn.FnSharedContext;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnSharedContextDao extends JpaRepository<FnSharedContext, Long> {
+interface FnSharedContextDao extends JpaRepository<FnSharedContext, Long> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/sharedContext/FnSharedContextService.java b/portal-BE/src/main/java/org/onap/portal/service/sharedContext/FnSharedContextService.java
new file mode 100644 (file)
index 0000000..7a427ae
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.sharedContext;
+
+import org.onap.portal.domain.db.fn.FnSharedContext;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnSharedContextService {
+
+    private final FnSharedContextDao fnSharedContextDao;
+
+    @Autowired
+    public FnSharedContextService(FnSharedContextDao fnSharedContextDao) {
+        this.fnSharedContextDao = fnSharedContextDao;
+    }
+
+    public List<FnSharedContext> saveAll(List<FnSharedContext> sharedContexts) {
+        return fnSharedContextDao.saveAll(sharedContexts);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.tab;
 
 import org.onap.portal.domain.db.fn.FnTab;
 import org.springframework.data.jpa.repository.JpaRepository;
@@ -47,6 +47,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnTabDao extends JpaRepository<FnTab, String> {
+interface FnTabDao extends JpaRepository<FnTab, String> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/tab/FnTabService.java b/portal-BE/src/main/java/org/onap/portal/service/tab/FnTabService.java
new file mode 100644 (file)
index 0000000..ed90831
--- /dev/null
@@ -0,0 +1,22 @@
+package org.onap.portal.service.tab;
+
+import org.onap.portal.domain.db.fn.FnTab;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service
+public class FnTabService {
+
+    private final FnTabDao fnTabDao;
+
+    @Autowired
+    public FnTabService(FnTabDao fnTabDao) {
+        this.fnTabDao = fnTabDao;
+    }
+
+    public List<FnTab> saveAll(List<FnTab> fnTabs) {
+        return fnTabDao.saveAll(fnTabs);
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.tabSelected;
 
 import org.onap.portal.domain.db.fn.FnTabSelected;
 import org.onap.portal.domain.db.fn.FnTabSelected.FnTabSelectedId;
@@ -48,6 +48,6 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnTabSelectedDao extends JpaRepository<FnTabSelected, FnTabSelectedId> {
+interface FnTabSelectedDao extends JpaRepository<FnTabSelected, FnTabSelectedId> {
 
 }
diff --git a/portal-BE/src/main/java/org/onap/portal/service/tabSelected/FnTabSelectedService.java b/portal-BE/src/main/java/org/onap/portal/service/tabSelected/FnTabSelectedService.java
new file mode 100644 (file)
index 0000000..92c6f56
--- /dev/null
@@ -0,0 +1,15 @@
+package org.onap.portal.service.tabSelected;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class FnTabSelectedService {
+
+    private final FnTabSelectedDao fnTabSelectedDao;
+
+    @Autowired
+    public FnTabSelectedService(FnTabSelectedDao fnTabSelectedDao) {
+        this.fnTabSelectedDao = fnTabSelectedDao;
+    }
+}
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.user;
 
 import java.util.List;
 import java.util.Optional;
@@ -51,7 +51,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnUserDao extends JpaRepository<FnUser, Long> {
+interface FnUserDao extends JpaRepository<FnUser, Long> {
 
        @Query
        Optional<FnUser> findByLoginId(final @Param("loginId") String username);
  *
  */
 
-package org.onap.portal.service.fn;
+package org.onap.portal.service.user;
 
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Optional;
-import org.onap.portal.dao.fn.FnUserDao;
+
 import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -89,12 +89,12 @@ public class FnUserService implements UserDetailsService {
               return fnUserDao.getUserWithOrgUserId(orgUserIdValue).orElse(new ArrayList<>());
        }
 
-       List<FnUser> getUsersByOrgIds(final List<String> orgIds) {
+       public List<FnUser> getUsersByOrgIds(final List<String> orgIds) {
               return fnUserDao.getUsersByOrgIds(orgIds).orElse(new ArrayList<>());
        }
 
 
-       List<FnUser> getActiveUsers() {
+       public List<FnUser> getActiveUsers() {
               return fnUserDao.getActiveUsers().orElse(new ArrayList<>());
        }
 
@@ -109,4 +109,16 @@ public class FnUserService implements UserDetailsService {
        public List<FnUser> findAll() {
               return fnUserDao.findAll();
        }
-       }
\ No newline at end of file
+
+       public List<FnUser> saveAll(List<FnUser> fnUsers) {
+              return fnUserDao.saveAll(fnUsers);
+       }
+
+       public FnUser save(FnUser user) {
+              return fnUserDao.save(user);
+       }
+
+       public void delete(FnUser user) {
+              fnUserDao.delete(user);
+       }
+}
\ No newline at end of file
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.userRole;
 
 import java.util.List;
 import java.util.Optional;
@@ -52,7 +52,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnUserRoleDao extends JpaRepository<FnUserRole, Long> {
+interface FnUserRoleDao extends JpaRepository<FnUserRole, Long> {
 
        @Query
        Optional<List<FnUserRole>> getAdminUserRoles(final @Param("userId") Long userId, final @Param("roleId") Long roleId, final @Param("appId") Long appId);
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.service.fn;
+package org.onap.portal.service.userRole;
 
 import com.fasterxml.jackson.core.JsonProcessingException;
 import com.fasterxml.jackson.databind.DeserializationFeature;
@@ -58,7 +58,6 @@ import javax.persistence.EntityManager;
 import javax.persistence.Tuple;
 import javax.servlet.http.HttpServletResponse;
 import org.apache.cxf.transport.http.HTTPException;
-import org.onap.portal.dao.fn.FnUserRoleDao;
 import org.onap.portal.domain.db.ep.EpUserRolesRequest;
 import org.onap.portal.domain.db.ep.EpUserRolesRequestDet;
 import org.onap.portal.domain.db.fn.FnApp;
@@ -75,9 +74,11 @@ import org.onap.portal.domain.dto.transport.Role;
 import org.onap.portal.domain.dto.transport.RoleInAppForUser;
 import org.onap.portal.domain.dto.transport.UserApplicationRoles;
 import org.onap.portal.service.ApplicationsRestClientService;
-import org.onap.portal.service.ep.EpAppFunctionService;
-import org.onap.portal.service.ep.EpUserRolesRequestDetService;
-import org.onap.portal.service.ep.EpUserRolesRequestService;
+import org.onap.portal.service.userRolesRequestDet.EpUserRolesRequestDetService;
+import org.onap.portal.service.userRolesRequest.EpUserRolesRequestService;
+import org.onap.portal.service.app.FnAppService;
+import org.onap.portal.service.role.FnRoleService;
+import org.onap.portal.service.user.FnUserService;
 import org.onap.portal.utils.EPCommonSystemProperties;
 import org.onap.portal.utils.PortalConstants;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
@@ -536,4 +537,8 @@ public class FnUserRoleService {
     }
     return rolesInAppForUser;
   }
+
+  public List<FnUserRole> saveAll(List<FnUserRole> userRoles) {
+    return fnUserRoleDao.saveAll(userRoles);
+  }
 }
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.userRolesRequest;
 
 import java.util.List;
 import org.onap.portal.domain.db.ep.EpUserRolesRequest;
@@ -50,7 +50,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface EpUserRolesRequestDao extends JpaRepository<EpUserRolesRequest, Long> {
+interface EpUserRolesRequestDao extends JpaRepository<EpUserRolesRequest, Long> {
   @Query
   List<EpUserRolesRequest> userAppRolesRequestList(final @Param("userId") Long userId, final @Param("appId") Long appId);
 }
  *
  */
 
-package org.onap.portal.service.ep;
+package org.onap.portal.service.userRolesRequest;
 
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Optional;
-import org.onap.portal.dao.ep.EpUserRolesRequestDao;
+
 import org.onap.portal.domain.db.ep.EpUserRolesRequest;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.userRolesRequestDet;
 
 import java.util.List;
 import org.onap.portal.domain.db.ep.EpUserRolesRequestDet;
@@ -50,7 +50,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface EpUserRolesRequestDetDao extends JpaRepository<EpUserRolesRequestDet, Long> {
+interface EpUserRolesRequestDetDao extends JpaRepository<EpUserRolesRequestDet, Long> {
 
   @Query
   List<EpUserRolesRequestDet> appRolesRequestDetailList(final @Param("reqId") Long reqId);
  *
  */
 
-package org.onap.portal.service.ep;
+package org.onap.portal.service.userRolesRequestDet;
 
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Optional;
-import org.onap.portal.dao.ep.EpUserRolesRequestDetDao;
 import org.onap.portal.domain.db.ep.EpUserRolesRequestDet;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -38,7 +38,7 @@
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.widget;
 
 import java.util.List;
 import java.util.Optional;
@@ -51,7 +51,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface FnWidgetDao extends JpaRepository<FnWidget, Long> {
+interface FnWidgetDao extends JpaRepository<FnWidget, Long> {
 
        @Query
        Optional<List<FnWidget>> getForUrlNameAndAppId(final @Param("URL") String url, final @Param("NAME") String name, final @Param("APPID") Long appId);
  *
  */
 
-package org.onap.portal.service;
+package org.onap.portal.service.widget;
 
 import java.util.ArrayList;
 import java.util.List;
 import javax.persistence.EntityManager;
 import javax.servlet.http.HttpServletResponse;
-import org.onap.portal.dao.fn.FnWidgetDao;
+
 import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.db.fn.FnUserRole;
 import org.onap.portal.domain.db.fn.FnWidget;
 import org.onap.portal.domain.dto.transport.FieldsValidator;
 import org.onap.portal.domain.dto.transport.OnboardingWidget;
-import org.onap.portal.service.fn.FnUserRoleService;
+import org.onap.portal.service.AdminRolesService;
+import org.onap.portal.service.userRole.FnUserRoleService;
 import org.onap.portal.utils.EPCommonSystemProperties;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.springframework.beans.factory.annotation.Autowired;
  *
  */
 
-package org.onap.portal.dao.fn;
+package org.onap.portal.service.widgetCatalog;
 
 import org.onap.portal.domain.db.ep.EpWidgetCatalog;
 import org.springframework.data.jpa.repository.JpaRepository;
 
-public interface EpWidgetCatalogDao extends JpaRepository<EpWidgetCatalog, Long> {
+interface EpWidgetCatalogDao extends JpaRepository<EpWidgetCatalog, Long> {
 
 }
@@ -1,10 +1,12 @@
-package org.onap.portal.service.ep;
+package org.onap.portal.service.widgetCatalog;
 
-import org.onap.portal.dao.fn.EpWidgetCatalogDao;
 import org.onap.portal.domain.db.ep.EpWidgetCatalog;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
+import java.util.List;
+import java.util.Optional;
+
 @Service
 public class EpWidgetCatalogService {
 
@@ -18,4 +20,12 @@ public class EpWidgetCatalogService {
        public EpWidgetCatalog save(final EpWidgetCatalog epWidgetCatalog){
               return epWidgetCatalogDao.save(epWidgetCatalog);
        }
+
+       public Optional<EpWidgetCatalog> findById(Long widgetId) {
+              return epWidgetCatalogDao.findById(widgetId);
+       }
+
+       public List<EpWidgetCatalog> saveAll(List<EpWidgetCatalog> epWidgetCatalogs) {
+              return epWidgetCatalogDao.saveAll(epWidgetCatalogs);
+       }
 }
@@ -1,4 +1,4 @@
-package org.onap.portal.dao.ep;
+package org.onap.portal.service.widgetCatalogParameter;
 
 import java.util.List;
 import java.util.Optional;
@@ -12,7 +12,7 @@ import org.springframework.transaction.annotation.Transactional;
 
 @Repository
 @Transactional
-public interface EpWidgetCatalogParameterDao extends JpaRepository<EpWidgetCatalogParameter, Long> {
+interface EpWidgetCatalogParameterDao extends JpaRepository<EpWidgetCatalogParameter, Long> {
 
        @Query
        Optional<List<EpWidgetCatalogParameter>> retrieveByParamId(@Param("PARAMID") Long paramId);
  *
  */
 
-package org.onap.portal.service.ep;
+package org.onap.portal.service.widgetCatalogParameter;
 
 import java.util.ArrayList;
 import java.util.List;
-import org.onap.portal.dao.ep.EpWidgetCatalogParameterDao;
 import org.onap.portal.domain.db.ep.EpWidgetCatalogParameter;
+import org.onap.portal.service.microserviceParameter.EpMicroserviceParameterService;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
index fea7133..027cebe 100644 (file)
@@ -63,7 +63,7 @@ import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.db.fn.FnUserRole;
 import org.onap.portal.domain.dto.transport.Role;
 import org.onap.portal.exception.RoleFunctionException;
-import org.onap.portal.service.fn.old.EPRoleFunctionService;
+import org.onap.portal.service.EPRoleFunctionService;
 import org.onap.portalsdk.core.domain.RoleFunction;
 import org.onap.portalsdk.core.exception.SessionExpiredException;
 import org.onap.portalsdk.core.logging.logic.EELFLoggerDelegate;
index e00dc5c..ca0cf92 100644 (file)
@@ -45,13 +45,13 @@ import static org.junit.jupiter.api.Assertions.assertNull;
 
 import org.junit.jupiter.api.Test;
 import org.junit.runner.RunWith;
-import org.onap.portal.dao.fn.FnLanguageDao;
 import org.onap.portal.domain.db.fn.FnLanguage;
 import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.dto.PortalRestResponse;
 import org.onap.portal.domain.dto.PortalRestStatusEnum;
 import org.onap.portal.domain.dto.fn.FnLanguageDto;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.language.FnLanguageService;
+import org.onap.portal.service.user.FnUserService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
@@ -69,7 +69,7 @@ class LanguageControllerTest {
        @Autowired
        private LanguageController languageController;
        @Autowired
-       private FnLanguageDao fnLanguageDao;
+       private FnLanguageService fnLanguageService;
        @Autowired
        private FnUserService fnUserService;
 
@@ -89,7 +89,7 @@ class LanguageControllerTest {
               assertEquals(expected.getMessage(), actual.getMessage());
               assertEquals(expected.getStatus(), actual.getStatus());
               //Clean up
-              fnLanguageDao.delete(fnLanguage);
+              fnLanguageService.delete(fnLanguage);
        }
 
        @Test
@@ -109,7 +109,7 @@ class LanguageControllerTest {
               assertEquals(expected.getMessage(), actual.getMessage());
               assertEquals(expected.getStatus(), actual.getStatus());
               //Clean up
-              fnLanguageDao.delete(fnLanguage);
+              fnLanguageService.delete(fnLanguage);
        }
 
        @Test
@@ -138,7 +138,7 @@ class LanguageControllerTest {
 
 
               //Clean up
-              fnLanguageDao.delete(fnLanguage);
+              fnLanguageService.delete(fnLanguage);
        }
 
        @Test
@@ -162,7 +162,7 @@ class LanguageControllerTest {
 
 
               //Clean up
-              fnLanguageDao.delete(fnLanguage);
+              fnLanguageService.delete(fnLanguage);
        }
 
 
index 0316683..7c654ad 100644 (file)
@@ -47,7 +47,7 @@ import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.dto.PortalRestResponse;
 import org.onap.portal.domain.dto.PortalRestStatusEnum;
 import org.onap.portal.domain.dto.transport.ProfileDetail;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.user.FnUserService;
 import org.onap.portalsdk.core.onboarding.exception.CipherUtilException;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
index e83c247..e9f9627 100644 (file)
@@ -45,11 +45,11 @@ import static org.junit.jupiter.api.Assertions.*;
 import org.junit.jupiter.api.Test;
 import org.junit.runner.RunWith;
 import org.onap.portal.domain.dto.ecomp.ExternalSystemAccess;
-import org.onap.portal.service.fn.FnAppService;
-import org.onap.portal.service.fn.FnLanguageService;
-import org.onap.portal.service.fn.FnRoleService;
-import org.onap.portal.service.fn.FnUserRoleService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.app.FnAppService;
+import org.onap.portal.service.language.FnLanguageService;
+import org.onap.portal.service.role.FnRoleService;
+import org.onap.portal.service.userRole.FnUserRoleService;
+import org.onap.portal.service.user.FnUserService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
index 27ce348..65525db 100644 (file)
@@ -51,18 +51,17 @@ import java.util.List;
 import javax.transaction.Transactional;
 import org.junit.Test;
 import org.junit.runner.RunWith;
-import org.onap.portal.dao.fn.FnLanguageDao;
 import org.onap.portal.domain.db.ep.EpMicroserviceParameter;
 import org.onap.portal.domain.db.ep.EpWidgetCatalog;
 import org.onap.portal.domain.db.ep.EpWidgetCatalogParameter;
 import org.onap.portal.domain.db.fn.FnLanguage;
 import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.dto.ecomp.WidgetCatalog;
-import org.onap.portal.service.ep.EpMicroserviceParameterService;
-import org.onap.portal.service.ep.EpWidgetCatalogParameterService;
-import org.onap.portal.service.ep.EpWidgetCatalogService;
-import org.onap.portal.service.fn.FnLanguageService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.microserviceParameter.EpMicroserviceParameterService;
+import org.onap.portal.service.widgetCatalogParameter.EpWidgetCatalogParameterService;
+import org.onap.portal.service.widgetCatalog.EpWidgetCatalogService;
+import org.onap.portal.service.language.FnLanguageService;
+import org.onap.portal.service.user.FnUserService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
@@ -88,8 +87,6 @@ public class WidgetsCatalogControllerTest {
        private EpMicroserviceParameterService epMicroserviceParameterService;
        @Autowired
        private EpWidgetCatalogService epWidgetCatalogService;
-       @Autowired
-       private FnLanguageDao fnLanguageDao;
 
        @Test
        public void getUserWidgetCatalog() {
@@ -172,7 +169,7 @@ public class WidgetsCatalogControllerTest {
               EpMicroserviceParameter parameter = new EpMicroserviceParameter();
               epMicroserviceParameterService.save(parameter);
               FnUser user = buildFnUser();
-              FnLanguage language = fnLanguageDao.getByLanguageAlias("EN");
+              FnLanguage language = fnLanguageService.getByLanguageAlias("EN");
               user.setLanguageId(language);
               fnUserService.saveFnUser(user);
               EpWidgetCatalogParameter data =  EpWidgetCatalogParameter.builder()
index 168fcc7..9da6e73 100644 (file)
@@ -53,8 +53,6 @@ import javax.servlet.http.HttpServletResponse;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
-import org.onap.portal.dao.fn.FnLanguageDao;
-import org.onap.portal.dao.fn.FnUserDao;
 import org.onap.portal.domain.db.fn.FnLanguage;
 import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.db.fn.FnWidget;
@@ -62,8 +60,9 @@ import org.onap.portal.domain.dto.transport.FieldsValidator;
 import org.onap.portal.domain.dto.transport.OnboardingWidget;
 import org.onap.portal.domain.dto.transport.WidgetCatalogPersonalization;
 import org.onap.portal.framework.MockitoTestSuite;
-import org.onap.portal.service.WidgetService;
-import org.onap.portal.service.fn.FnLanguageService;
+import org.onap.portal.service.user.FnUserService;
+import org.onap.portal.service.widget.WidgetService;
+import org.onap.portal.service.language.FnLanguageService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
@@ -89,14 +88,11 @@ public class WidgetsControllerTest {
        @Autowired
        private WidgetsController widgetsController;
        @Autowired
-       private FnUserDao fnUserDao;
-       @Autowired
-       private FnLanguageDao fnLanguageDao;
-       @Autowired
        private WidgetService widgetService;
        @Autowired
        private  FnLanguageService fnLanguageService;
-
+       @Autowired
+       FnUserService fnUserService;
        private FnLanguage language;
        private FnUser questUser;
        private FnUser notQuestUser;
@@ -120,14 +116,14 @@ public class WidgetsControllerTest {
        public void getOnboardingWidgetsQuestUserTest() {
               UsernamePasswordAuthenticationToken questPrincipal = new UsernamePasswordAuthenticationToken("questUser",
                       "demo123");
-              fnUserDao.save(questUser);
+              fnUserService.save(questUser);
               List<OnboardingWidget> onboardingWidgets = widgetsController
                       .getOnboardingWidgets(questPrincipal, request, response);
               assertNull(onboardingWidgets);
 
               //Clean up
-              fnUserDao.delete(questUser);
-              fnLanguageDao.delete(language);
+              fnUserService.delete(questUser);
+              fnLanguageService.delete(language);
        }
 
        @Test
@@ -135,7 +131,7 @@ public class WidgetsControllerTest {
               UsernamePasswordAuthenticationToken notQuestprincipal = new UsernamePasswordAuthenticationToken(
                       "notQuestUser",
                       "demo123");
-              fnUserDao.save(notQuestUser);
+              fnUserService.save(notQuestUser);
               List<OnboardingWidget> expected = new ArrayList<>();
               when(request.getHeader("X-Widgets-Type")).thenReturn("managed");
 
@@ -143,7 +139,7 @@ public class WidgetsControllerTest {
                       .getOnboardingWidgets(notQuestprincipal, request, response);
 
               assertEquals(expected, actual);
-              fnUserDao.delete(notQuestUser);
+              fnUserService.delete(notQuestUser);
        }
 
        @Test
@@ -151,19 +147,19 @@ public class WidgetsControllerTest {
               UsernamePasswordAuthenticationToken notQuestprincipal = new UsernamePasswordAuthenticationToken(
                       "notQuestUser",
                       "demo123");
-              fnUserDao.save(notQuestUser);
+              fnUserService.save(notQuestUser);
               when(request.getHeader("X-Widgets-Type")).thenReturn("test");
               List<OnboardingWidget> actual = widgetsController
                       .getOnboardingWidgets(notQuestprincipal, request, response);
 
               assertNull(actual);
-              fnUserDao.delete(notQuestUser);
+              fnUserService.delete(notQuestUser);
        }
 
        @Test
        public void putOnboardingWidgetSameWidget() {
               //Given
-              fnUserDao.save(notQuestUser);
+              fnUserService.save(notQuestUser);
               when(request.getHeader("X-Widgets-Type")).thenReturn("managed");
 
               OnboardingWidget onboardingWidget = OnboardingWidget.builder()
@@ -199,7 +195,7 @@ public class WidgetsControllerTest {
        @Test
        public void putOnboardingWidgetAOP() {
               //Given
-              fnUserDao.save(notQuestUser);
+              fnUserService.save(notQuestUser);
               when(request.getHeader("X-Widgets-Type")).thenReturn("managed");
 
               OnboardingWidget onboardingWidget = OnboardingWidget.builder()
@@ -236,7 +232,7 @@ public class WidgetsControllerTest {
        @Test
        public void putOnboardingWidgetAOPXSSTest() {
               //Given
-              fnUserDao.save(notQuestUser);
+              fnUserService.save(notQuestUser);
               when(request.getHeader("X-Widgets-Type")).thenReturn("managed");
 
               OnboardingWidget onboardingWidget = OnboardingWidget.builder()
@@ -264,7 +260,7 @@ public class WidgetsControllerTest {
        @Test
        public void postOnboardingWidgetXSS() {
               //Given
-              fnUserDao.save(notQuestUser);
+              fnUserService.save(notQuestUser);
               when(request.getHeader("X-Widgets-Type")).thenReturn("managed");
 
               OnboardingWidget onboardingWidget = OnboardingWidget.builder()
@@ -290,7 +286,7 @@ public class WidgetsControllerTest {
        @Test
        public void postOnboardingWidget() {
               //Given
-              fnUserDao.save(notQuestUser);
+              fnUserService.save(notQuestUser);
               when(request.getHeader("X-Widgets-Type")).thenReturn("managed");
 
               OnboardingWidget onboardingWidget = OnboardingWidget.builder()
@@ -315,7 +311,7 @@ public class WidgetsControllerTest {
        @Test
        public void deleteOnboardingWidgetSCFORBIDDEN() {
               //Given
-              fnUserDao.save(notQuestUser);
+              fnUserService.save(notQuestUser);
               when(request.getHeader("X-Widgets-Type")).thenReturn("managed");
 
               OnboardingWidget onboardingWidget = OnboardingWidget.builder()
index b4427ef..e11a696 100644 (file)
@@ -45,6 +45,7 @@ import static org.junit.jupiter.api.Assertions.*;
 import org.junit.jupiter.api.Test;
 import org.junit.runner.RunWith;
 import org.onap.portal.domain.db.ep.EpMicroserviceParameter;
+import org.onap.portal.service.microserviceParameter.EpMicroserviceParameterService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.test.context.TestPropertySource;
index ad1ee60..7c7b0b7 100644 (file)
@@ -43,19 +43,20 @@ package org.onap.portal.service.ep;
 import static org.junit.jupiter.api.Assertions.assertEquals;
 
 import java.time.LocalDateTime;
-import java.util.Collections;
-import java.util.HashSet;
+
 import org.junit.jupiter.api.Test;
 import org.junit.runner.RunWith;
 import org.onap.portal.controller.WidgetsCatalogController;
-import org.onap.portal.dao.fn.FnLanguageDao;
 import org.onap.portal.domain.db.ep.EpMicroserviceParameter;
 import org.onap.portal.domain.db.ep.EpWidgetCatalog;
 import org.onap.portal.domain.db.ep.EpWidgetCatalogParameter;
 import org.onap.portal.domain.db.fn.FnLanguage;
 import org.onap.portal.domain.db.fn.FnUser;
-import org.onap.portal.service.fn.FnLanguageService;
-import org.onap.portal.service.fn.FnUserService;
+import org.onap.portal.service.language.FnLanguageService;
+import org.onap.portal.service.microserviceParameter.EpMicroserviceParameterService;
+import org.onap.portal.service.user.FnUserService;
+import org.onap.portal.service.widgetCatalog.EpWidgetCatalogService;
+import org.onap.portal.service.widgetCatalogParameter.EpWidgetCatalogParameterService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
@@ -77,7 +78,7 @@ class EpWidgetCatalogParameterServiceTest {
        private final FnUserService fnUserService;
        private final EpMicroserviceParameterService epMicroserviceParameterService;
        private final EpWidgetCatalogService epWidgetCatalogService;
-       private final FnLanguageDao fnLanguageDao;
+       private final FnLanguageService fnLanguageService;
 
        @Autowired
        public EpWidgetCatalogParameterServiceTest(
@@ -85,13 +86,13 @@ class EpWidgetCatalogParameterServiceTest {
            WidgetsCatalogController widgetsCatalogController,
            FnUserService fnUserService,
            EpMicroserviceParameterService epMicroserviceParameterService,
-           EpWidgetCatalogService epWidgetCatalogService, FnLanguageDao fnLanguageDao) {
+           EpWidgetCatalogService epWidgetCatalogService, FnLanguageService fnLanguageService) {
               this.epWidgetCatalogParameterService = epWidgetCatalogParameterService;
               this.widgetsCatalogController = widgetsCatalogController;
               this.fnUserService = fnUserService;
               this.epMicroserviceParameterService = epMicroserviceParameterService;
               this.epWidgetCatalogService = epWidgetCatalogService;
-              this.fnLanguageDao = fnLanguageDao;
+              this.fnLanguageService = fnLanguageService;
        }
 
        @Test
@@ -154,7 +155,7 @@ class EpWidgetCatalogParameterServiceTest {
        }
 
        private FnUser buildFnUser() {
-              FnLanguage language = fnLanguageDao.getByLanguageAlias("EN");
+              FnLanguage language = fnLanguageService.getByLanguageAlias("EN");
               return FnUser.builder()
                       .lastLoginDate(LocalDateTime.now())
                       .activeYn(true)
index fbb09e1..68b1a80 100644 (file)
@@ -49,6 +49,8 @@ import org.junit.jupiter.api.Test;
 import org.junit.runner.RunWith;
 import org.onap.portal.domain.db.fn.FnUser;
 import org.onap.portal.domain.dto.ecomp.EPUserAppCatalogRoles;
+import org.onap.portal.service.user.FnUserService;
+import org.onap.portal.service.userRole.FnUserRoleService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.test.context.TestPropertySource;
index 56cbe81..49c018e 100644 (file)
@@ -48,10 +48,12 @@ import java.util.Arrays;
 import java.util.List;
 import org.junit.jupiter.api.Test;
 import org.junit.runner.RunWith;
-import org.onap.portal.dao.fn.FnLanguageDao;
+import org.onap.portal.service.language.FnLanguageService;
 import org.onap.portal.domain.db.fn.FnLanguage;
 import org.onap.portal.domain.db.fn.FnLuTimezone;
 import org.onap.portal.domain.db.fn.FnUser;
+import org.onap.portal.service.luTimezone.FnLuTimezoneService;
+import org.onap.portal.service.user.FnUserService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.test.context.SpringBootTest;
 import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
@@ -71,8 +73,6 @@ class FnUserServiceTest {
        private FnLuTimezoneService fnLuTimezoneService;
        @Autowired
        private FnLanguageService fnLanguageService;
-       @Autowired
-       private FnLanguageDao fnLanguageDao;
 
        @Test
        void saveUser(){
@@ -96,7 +96,7 @@ class FnUserServiceTest {
               expected.setCountryCd("US");
               expected.setLanguageId(fnLanguageService.findById(1L).orElse(new FnLanguage()));
               expected.setGuest(false);
-              FnLanguage language = fnLanguageDao.getByLanguageAlias("EN");
+              FnLanguage language = fnLanguageService.getByLanguageAlias("EN");
               expected.setLanguageId(language);
 
               //When