aboutsummaryrefslogtreecommitdiffstats
path: root/catalog-ui/src/app/modules
diff options
context:
space:
mode:
authorTal Gitelman <tg851x@intl.att.com>2017-12-10 18:55:03 +0200
committerTal Gitelman <tg851x@intl.att.com>2017-12-10 19:33:38 +0200
commit51d50f0ef642e0f996a1c8b8d2ef4838bdfec892 (patch)
tree3ac236a864d74d19b0f5c9020891a7a7e5c31b44 /catalog-ui/src/app/modules
parentb5cc2e0695f195716d6ccdc65e73807a6632ec70 (diff)
Final commit to master merge from
Change-Id: Ib464f9a8828437c86fe6def8af238aaf83473507 Issue-ID: SDC-714 Signed-off-by: Tal Gitelman <tg851x@intl.att.com>
Diffstat (limited to 'catalog-ui/src/app/modules')
-rw-r--r--catalog-ui/src/app/modules/directive-module.ts19
-rw-r--r--catalog-ui/src/app/modules/service-module.ts17
2 files changed, 30 insertions, 6 deletions
diff --git a/catalog-ui/src/app/modules/directive-module.ts b/catalog-ui/src/app/modules/directive-module.ts
index 8142cc49bd..4039a7683a 100644
--- a/catalog-ui/src/app/modules/directive-module.ts
+++ b/catalog-ui/src/app/modules/directive-module.ts
@@ -40,7 +40,6 @@ import {ExpandCollapseMenuBoxDirective} from "../directives/utils/expand-collaps
import {PunchOutDirective} from "../directives/punch-out/punch-out";
import {CustomValidationDirective} from "../directives/custom-validation/custom-validation";
import {EcompHeaderDirective} from "../directives/ecomp-header/ecomp-header";
-import {EcompFooterDirective} from "../directives/ecomp-footer/ecomp-footer";
import {EditNamePopoverDirective} from "../directives/edit-name-popover/edit-name-popover-directive";
import {DataTypeFieldsStructureDirective} from "../directives/property-types/data-type-fields-structure/data-type-fields-structure";
import {TypeMapDirective} from "../directives/property-types/type-map/type-map-directive";
@@ -54,7 +53,6 @@ import {SdcTabsDirective} from "../directives/sdc-tabs/sdc-tabs-directive";
import {SdcSingleTabDirective, InnerSdcSingleTabDirective} from "../directives/sdc-tabs/sdc-single-tab/sdc-single-tab-directive";
import {ExpandCollapseListHeaderDirective} from "../directives/utils/expand-collapse-list-header/expand-collapse-list-header";
import {JsonExportExcelDirective} from "../directives/export-json-to-excel/export-json-to-excel";
-import {TopNavDirective} from "../directives/layout/top-nav/top-nav";
import {TopProgressDirective} from "../directives/layout/top-progress/top-progress";
import {CheckboxElementDirective} from "../directives/elements/checkbox/checkbox";
import {RadiobuttonElementDirective} from "../directives/elements/radiobutton/radiobutton";
@@ -105,7 +103,6 @@ directiveModule.directive('expandCollapseMenuBox', ExpandCollapseMenuBoxDirectiv
directiveModule.directive('punchOut', PunchOutDirective.factory);
directiveModule.directive('customValidation', CustomValidationDirective.factory);
directiveModule.directive('ecompHeader', EcompHeaderDirective.factory);
-directiveModule.directive('ecompFooter', EcompFooterDirective.factory);
directiveModule.directive('editNamePopover', EditNamePopoverDirective.factory);
directiveModule.directive('fieldsStructure', DataTypeFieldsStructureDirective.factory);
directiveModule.directive('typeMap', TypeMapDirective.factory);
@@ -122,7 +119,6 @@ directiveModule.directive('jsonExportExcel', JsonExportExcelDirective.factory);
directiveModule.directive('expandCollapseListHeader', ExpandCollapseListHeaderDirective.factory);
//
// // Layouts
-directiveModule.directive('topNav', TopNavDirective.factory);
directiveModule.directive('topProgress', TopProgressDirective.factory);
//
// // Elements
@@ -170,3 +166,18 @@ directiveModule.service('DeploymentGraphGeneralUtils', DeploymentGraphGeneralUti
//Compoisiton right tab directives
directiveModule.directive('capabilitiesList', CapabilitiesListDirective.factory);
directiveModule.directive('requirementsList', RequirementsListDirective.factory);
+
+
+// *** NG2 Components (downgraded) *** //
+import {MenuListNg2Component} from "../ng2/components/downgrade-wrappers/menu-list-ng2/menu-list-ng2.component";
+import {TopNavComponent} from "../ng2/components/layout/top-nav/top-nav.component";
+
+directiveModule.directive('menuListNg2', downgradeComponent({
+ component: MenuListNg2Component,
+ inputs: ['props']
+}) as angular.IDirectiveFactory);
+directiveModule.directive('topNav', downgradeComponent({
+ component: TopNavComponent,
+ inputs: ['version', 'menuModel', 'topLvlSelectedIndex', 'hideSearch', 'searchTerm', 'notificationIconCallback'],
+ outputs: ['searchTermChange']
+}) as ng.IDirectiveFactory);
diff --git a/catalog-ui/src/app/modules/service-module.ts b/catalog-ui/src/app/modules/service-module.ts
index 99624ada45..b677a6d842 100644
--- a/catalog-ui/src/app/modules/service-module.ts
+++ b/catalog-ui/src/app/modules/service-module.ts
@@ -43,8 +43,14 @@ import {FileUtils} from "../utils/file-utils";
import {ValidationUtils} from "../utils/validation-utils";
import {AngularJSBridge} from "../services/angular-js-bridge-service";
import {LoaderService} from "../services/loader-service";
-import {UserResourceService} from "../services/user-resource-service";
import {CategoryResourceService} from "../services/category-resource-service";
+import {downgradeInjectable} from "@angular/upgrade/static";
+import {ModalService} from "../ng2/services/modal.service";
+import {ComponentServiceNg2} from "../ng2/services/component-services/component.service";
+import {ServiceServiceNg2} from "../ng2/services/component-services/service.service";
+import {ConnectionWizardService} from "../ng2/pages/connection-wizard/connection-wizard.service";
+import {ComponentInstanceServiceNg2} from "../ng2/services/component-instance-services/component-instance.service";
+import {UserService as UserServiceNg2} from "../ng2/services/user.service";
let moduleName:string = 'Sdc.Services';
let serviceModule:ng.IModule = angular.module(moduleName, []);
@@ -80,5 +86,12 @@ serviceModule.service('ValidationUtils', ValidationUtils);
serviceModule.service('AngularJSBridge',AngularJSBridge);
serviceModule.service('LoaderService', LoaderService);
-serviceModule.factory('Sdc.Services.UserResourceService', UserResourceService.getResource);
serviceModule.factory('Sdc.Services.CategoryResourceService', CategoryResourceService.getResource);
+
+// Angular2 upgraded services - This is in order to use the service in angular1 till we finish remove all angular1 code
+serviceModule.factory('ComponentServiceNg2', downgradeInjectable(ComponentServiceNg2));
+serviceModule.factory('ServiceServiceNg2', downgradeInjectable(ServiceServiceNg2));
+serviceModule.factory('ModalServiceNg2', downgradeInjectable(ModalService));
+serviceModule.factory('ConnectionWizardServiceNg2', downgradeInjectable(ConnectionWizardService));
+serviceModule.factory('ComponentInstanceServiceNg2', downgradeInjectable(ComponentInstanceServiceNg2));
+serviceModule.factory('UserServiceNg2', downgradeInjectable(UserServiceNg2)); \ No newline at end of file