Fix 'Adding property to VF/Service throws js-exception'-bug 78/132778/1
authorvasraz <vasyl.razinkov@est.tech>
Thu, 15 Dec 2022 18:40:59 +0000 (18:40 +0000)
committerVasyl Razinkov <vasyl.razinkov@est.tech>
Thu, 15 Dec 2022 18:43:39 +0000 (18:43 +0000)
Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech>
Change-Id: I81009a79715f1719862e406e88be008294f94e37
Issue-ID: SDC-4310

catalog-ui/src/app/ng2/components/logic/properties-table/dynamic-property/dynamic-property.component.ts

index 360cfac..57b991b 100644 (file)
@@ -113,17 +113,16 @@ export class DynamicPropertyComponent {
     ngOnChanges() {
         this.propType = this.property.derivedDataType;
         this.propPath = (this.property instanceof PropertyFEModel) ? this.property.name : this.property.propertiesName;
-        this.propertyTestsId = this.getPropertyTestsId(); 
+        this.rootProperty = (this.rootProperty) ? this.rootProperty : <PropertyFEModel>this.property;
+        this.propertyTestsId = this.getPropertyTestsId();
     }
 
-
     onClickPropertyRow = (property, event) => {
         // Because DynamicPropertyComponent is recrusive second time the event is fire event.stopPropagation = undefined
         event && event.stopPropagation && event.stopPropagation();
         this.clickOnPropertyRow.emit(property);
     }
 
-
     expandChildById = (id: string) => {
         this.expandedChildId = id;
         this.expandChild.emit(id);