summaryrefslogtreecommitdiffstats
path: root/cds-ui/client/src
diff options
context:
space:
mode:
authorDan Timoney <dtimoney@att.com>2019-03-31 12:45:03 +0000
committerGerrit Code Review <gerrit@onap.org>2019-03-31 12:45:03 +0000
commit4e5c0925e95c57f698b2da65d3f2e58ad8fc5d92 (patch)
tree9afded503493edbc4acbba9c5e0274dda53628fe /cds-ui/client/src
parent43ce732ffb11a11a8c683d6ac85fd8cd3e8e00ca (diff)
parenta4900b643dbccdeaa499d3b0ceace5524b12a67a (diff)
Merge "Existing model changes"
Diffstat (limited to 'cds-ui/client/src')
-rw-r--r--cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.html2
-rw-r--r--cds-ui/client/src/app/feature-modules/resource-definition/resource-creation/existing-model/existing-model.component.ts26
2 files changed, 25 insertions, 3 deletions
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 @@
*/-->
-<app-search-resource></app-search-resource> \ No newline at end of file
+<app-search-resource (resourcesData)="selectedResource($event)"></app-search-resource> \ 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<IAppState>) { }
ngOnInit() {
- }
+ }
+
+ selectedResource(value){
+ console.log(value);
+ this.resourceName=value;
+ }
+
+ getDataUsingResouceName(){
+
+ }
+
+ updateResourcesState() {
+ var me = this;
+ var data:IResources;
+ me.store.dispatch(new LoadResourcesSuccess(data));
+ }
+
}