From 6787d78d2678772551b5e6c902b1e3fb5b5cb17d Mon Sep 17 00:00:00 2001 From: swapnalipode Date: Thu, 9 Jan 2020 17:19:45 +0530 Subject: Adding changes to Controller catalog Adding new changes for integration in controller catalog Change-Id: I5a014ff35d01213545d09db79886c6c4fd9f827d Issue-ID: CCSDK-810 Signed-off-by: swapnalipode --- .../create-catalog/create-catalog.component.ts | 29 ++++++++++++---------- 1 file changed, 16 insertions(+), 13 deletions(-) (limited to 'cds-ui/client/src/app/feature-modules/controller-catalog/create-catalog/create-catalog.component.ts') diff --git a/cds-ui/client/src/app/feature-modules/controller-catalog/create-catalog/create-catalog.component.ts b/cds-ui/client/src/app/feature-modules/controller-catalog/create-catalog/create-catalog.component.ts index 3b8294db9..ad74a9fc3 100644 --- a/cds-ui/client/src/app/feature-modules/controller-catalog/create-catalog/create-catalog.component.ts +++ b/cds-ui/client/src/app/feature-modules/controller-catalog/create-catalog/create-catalog.component.ts @@ -97,20 +97,23 @@ export class CreateCatalogComponent implements OnInit { this.catalog.derivedFrom=this.CatalogFormData.controls['derivedFrom'].value this.catalog.description=this.CatalogFormData.controls['description'].value this.catalog.definition=this.data; + this.catalog.version=""; + this.catalog.creationDate=""; console.log(this.catalog); - let catalogState = { - catalog: this.catalog - } - this.store.dispatch(new SetCatalogState(catalogState)); - - this.catalogCreateService.saveCatalog(this.catalog) - .subscribe(response=>{ - this.alertService.success("save success") - }, - error=>{ - this.alertService.error('Error saving resources'); - }) - + let catalogState = { + catalog: this.catalog + } + this.store.dispatch(new SetCatalogState(catalogState)); + + this.catalogCreateService.saveCatalog(this.catalog) + .subscribe(response=>{ + this.alertService.success("save success") + }, + error=>{ + console.log(error); + this.alertService.error('Error saving resources'); + }) + } onChange($event) { -- cgit 1.2.3-korg