From 59148be1a5a9beea5a157ace746eea3c969f5ed4 Mon Sep 17 00:00:00 2001 From: KrupaNagabhushan Date: Tue, 7 Feb 2023 10:03:36 +0000 Subject: Service Import - general page validation Issue-ID: SDC-4371 Signed-off-by: KrupaNagabhushan Change-Id: Ie7340a012feee413a622a8f6ed131f10be5e15e4 --- .../app/view-models/workspace/tabs/general/general-view-model.ts | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'catalog-ui/src/app') diff --git a/catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts b/catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts index 8023ceecec..f550ccf355 100644 --- a/catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts +++ b/catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts @@ -760,6 +760,12 @@ export class GeneralViewModel { }); this.$scope.onCategoryChange = (): void => { + if (!this.$scope.component.selectedCategory) { + this.$scope.editForm['category'].$setDirty(); + } + if (!this.$scope.component.description) { + this.$scope.editForm['description'].$setDirty(); + } this.$scope.component.selectedCategory = this.$scope.componentCategories.selectedCategory; if (this.$scope.component.selectedCategory) { this.$scope.component.categories = this.convertCategoryStringToOneArray(); -- cgit 1.2.3-korg