summaryrefslogtreecommitdiffstats
path: root/catalog-model
diff options
context:
space:
mode:
authorandre.schmid <andre.schmid@est.tech>2022-03-23 15:39:45 +0000
committerMichael Morris <michael.morris@est.tech>2022-03-28 15:28:02 +0000
commit88fdc6dd75f1119ffa8e54dbfd721b6ed722b779 (patch)
tree2dd23aa9e31bc833ea2d3351b676963072f43d7d /catalog-model
parentb34392d78130702e86e36b89f848118ac08e7e44 (diff)
Fix Service/VF set value to list/map properties
In the Service Property Assignment page, setting a value to a property of type list<complex> or map<complex> was having the type replaced by the schema type and the value incorrectly set. Add test cases to cover the problem. Include small refactors. Issue-ID: SDC-3926 Change-Id: I1257dbb02e18b103118672ec52d663707d53229c Signed-off-by: andre.schmid <andre.schmid@est.tech>
Diffstat (limited to 'catalog-model')
-rw-r--r--catalog-model/src/main/java/org/openecomp/sdc/be/model/PropertyDefinition.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/PropertyDefinition.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/PropertyDefinition.java
index c06df6541f..6e313eda6c 100644
--- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/PropertyDefinition.java
+++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/PropertyDefinition.java
@@ -46,6 +46,9 @@ public class PropertyDefinition extends PropertyDataDefinition implements IOpera
public PropertyDefinition(PropertyDefinition pd) {
super(pd);
+ if (pd.getSchema() != null && pd.getSchema().getProperty() instanceof PropertyDefinition) {
+ this.getSchema().setProperty(new PropertyDefinition(pd.getSchema().getProperty()));
+ }
setConstraints(pd.getConstraints());
}