aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKrupaNagabhushan <krupa.nagabhushan@est.tech>2023-02-07 10:03:36 +0000
committerMichael Morris <michael.morris@est.tech>2023-02-15 09:53:18 +0000
commit59148be1a5a9beea5a157ace746eea3c969f5ed4 (patch)
tree4bb03934ddf6feea6a7d5c4b47165c01b0dcd495
parentbe4abb0399b23f503123f39c44da8e2d867615b1 (diff)
Service Import - general page validation
Issue-ID: SDC-4371 Signed-off-by: KrupaNagabhushan <krupa.nagabhushan@est.tech> Change-Id: Ie7340a012feee413a622a8f6ed131f10be5e15e4
-rw-r--r--catalog-ui/src/app/view-models/workspace/tabs/general/general-view-model.ts6
1 files changed, 6 insertions, 0 deletions
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();