From a4900b643dbccdeaa499d3b0ceace5524b12a67a Mon Sep 17 00:00:00 2001 From: Swapnali Shadanan Pode Date: Fri, 29 Mar 2019 16:36:41 +0530 Subject: Existing model changes Change-Id: I41ddfbe6780f96b0f6ce6955322fa835162db320 Issue-ID: CCSDK-804 Signed-off-by: sp00501638 --- .../existing-model/existing-model.component.html | 2 +- .../existing-model/existing-model.component.ts | 26 ++++++++++++++++++++-- 2 files changed, 25 insertions(+), 3 deletions(-) (limited to 'cds-ui/client/src') diff --git a/cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.html b/cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.html index 491066310..4a738b79c 100644 --- a/cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.html +++ b/cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.html @@ -19,4 +19,4 @@ */--> - \ No newline at end of file + \ No newline at end of file diff --git a/cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.ts b/cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.ts index f780ef851..9fdc38886 100644 --- a/cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.ts +++ b/cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.ts @@ -19,6 +19,10 @@ */ import { Component, OnInit } from '@angular/core'; +import { Store } from '@ngrx/store'; +import { IResources } from 'src/app/common/core/store/models/resources.model'; +import { IAppState } from 'src/app/common/core/store/state/app.state'; +import { LoadResourcesSuccess } from 'src/app/common/core/store/actions/resources.action'; @Component({ selector: 'app-existing-model', @@ -27,9 +31,27 @@ import { Component, OnInit } from '@angular/core'; }) export class ExistingModelComponent implements OnInit { - constructor() { } + resourceName:string; + + constructor(private store: Store) { } ngOnInit() { - } + } + + selectedResource(value){ + console.log(value); + this.resourceName=value; + } + + getDataUsingResouceName(){ + + } + + updateResourcesState() { + var me = this; + var data:IResources; + me.store.dispatch(new LoadResourcesSuccess(data)); + } + } -- cgit 1.2.3-korg