aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--catalog-model/src/main/java/org/openecomp/sdc/be/model/operations/impl/PropertyOperation.java14
1 files changed, 7 insertions, 7 deletions
diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/operations/impl/PropertyOperation.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/operations/impl/PropertyOperation.java
index f6bcf1bc8e..d5f7ccbcbb 100644
--- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/operations/impl/PropertyOperation.java
+++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/operations/impl/PropertyOperation.java
@@ -2197,8 +2197,8 @@ public class PropertyOperation extends AbstractOperation implements IPropertyOpe
Object minValue = rangeArray.get(0);
Object maxValue = rangeArray.get(1);
InRangeConstraint rangeConstraint = new InRangeConstraint(Lists.newArrayList(minValue, maxValue));
- rangeConstraint.setMin(convertToComparable(ToscaType.RANGE, String.valueOf(minValue)));
- rangeConstraint.setMax(convertToComparable(ToscaType.RANGE, String.valueOf(maxValue)));
+ rangeConstraint.setMin(String.valueOf(minValue));
+ rangeConstraint.setMax(String.valueOf(maxValue));
propertyConstraint = rangeConstraint;
}
} else {
@@ -2318,9 +2318,6 @@ public class PropertyOperation extends AbstractOperation implements IPropertyOpe
if (je.isBoolean()) {
return je.getAsBoolean();
}
- if (je.isString()) {
- return je.getAsString();
- }
if (je.isNumber()) {
double number = je.getAsNumber().floatValue();
if ((number % 1) == 0) {
@@ -2328,6 +2325,9 @@ public class PropertyOperation extends AbstractOperation implements IPropertyOpe
}
return number;
}
+ if (je.isString()) {
+ return je.getAsString();
+ }
return null;
}
}
@@ -2442,8 +2442,8 @@ public class PropertyOperation extends AbstractOperation implements IPropertyOpe
String minValue = rangeArray.get(0).asText();
String maxValue = rangeArray.get(1).asText();
InRangeConstraint rangeConstraint = new InRangeConstraint(Lists.newArrayList(minValue, maxValue));
- rangeConstraint.setMin(convertToComparable(ToscaType.RANGE, minValue));
- rangeConstraint.setMax(convertToComparable(ToscaType.RANGE, maxValue));
+ rangeConstraint.setMin(minValue);
+ rangeConstraint.setMax(maxValue);
return rangeConstraint;
}
}