From 75aacbbe1acf78fa53378f07f0a8c7769449a17e Mon Sep 17 00:00:00 2001 From: Michael Lando Date: Mon, 17 Jul 2017 21:12:03 +0300 Subject: [SDC] rebase 1710 code Change-Id: I532ed68979fee7840ea8a5395e7e965b155fb9f9 Signed-off-by: Michael Lando --- catalog-ui/src/app/utils/component-factory.ts | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) (limited to 'catalog-ui/src/app/utils/component-factory.ts') diff --git a/catalog-ui/src/app/utils/component-factory.ts b/catalog-ui/src/app/utils/component-factory.ts index c202a1c8f5..b35918c0f6 100644 --- a/catalog-ui/src/app/utils/component-factory.ts +++ b/catalog-ui/src/app/utils/component-factory.ts @@ -20,8 +20,8 @@ 'use strict'; import {DEFAULT_ICON, ResourceType, ComponentType} from "./constants"; -import {ServiceService, CacheService, ResourceService, ProductService} from "app/services"; -import {IMainCategory, ISubCategory, ICsarComponent, Component, Resource, Service, Product} from "app/models"; +import {ServiceService, CacheService, ResourceService} from "app/services"; +import {IMainCategory, ISubCategory, ICsarComponent, Component, Resource, Service} from "app/models"; import {ComponentMetadata} from "../models/component-metadata"; import {ComponentServiceNg2} from "../ng2/services/component-services/component.service"; import {ComponentGenericResponse} from "../ng2/services/responses/component-generic-response"; @@ -32,7 +32,6 @@ export class ComponentFactory { static '$inject' = [ 'Sdc.Services.Components.ResourceService', 'Sdc.Services.Components.ServiceService', - 'Sdc.Services.Components.ProductService', 'Sdc.Services.CacheService', '$q', 'ComponentServiceNg2' @@ -40,7 +39,6 @@ export class ComponentFactory { constructor(private ResourceService:ResourceService, private ServiceService:ServiceService, - private ProductService:ProductService, private cacheService:CacheService, private $q:ng.IQService, private ComponentServiceNg2: ComponentServiceNg2) { @@ -58,18 +56,10 @@ export class ComponentFactory { newComponent = new Resource(this.ResourceService, this.$q, component); break; - case 'PRODUCT': - newComponent = new Product(this.ProductService, this.$q, component); - break; } return newComponent; }; - public createProduct = (product:Product):Product => { - let newProduct:Product = new Product(this.ProductService, this.$q, product); - return newProduct; - }; - public createService = (service:Service):Service => { let newService:Service = new Service(this.ServiceService, this.$q, service); return newService; @@ -144,12 +134,10 @@ export class ComponentFactory { case ResourceType.VL: case ResourceType.VFC: case ResourceType.CP: + case ResourceType.PNF: + case ResourceType.CVFC: newComponent = new Resource(this.ResourceService, this.$q); break; - - case ComponentType.PRODUCT: - newComponent = new Product(this.ProductService, this.$q); - break; } newComponent.componentType = componentType; newComponent.tags = []; -- cgit 1.2.3-korg