From 6e12c8ad59f11426e49f81c4a7032480b126bfbc Mon Sep 17 00:00:00 2001 From: vasraz Date: Mon, 23 Jan 2023 20:10:43 +0000 Subject: Implement hiding mechanism Signed-off-by: Vasyl Razinkov Change-Id: I799af15e31b724ca394eebe435223c03186fb6d3 Issue-ID: SDC-4344 --- .../org/openecomp/sdc/be/dao/neo4j/GraphPropertiesDictionary.java | 1 + .../org/openecomp/sdc/be/resources/data/category/CategoryData.java | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'catalog-dao') diff --git a/catalog-dao/src/main/java/org/openecomp/sdc/be/dao/neo4j/GraphPropertiesDictionary.java b/catalog-dao/src/main/java/org/openecomp/sdc/be/dao/neo4j/GraphPropertiesDictionary.java index 5a287c9261..2f82cb51c6 100644 --- a/catalog-dao/src/main/java/org/openecomp/sdc/be/dao/neo4j/GraphPropertiesDictionary.java +++ b/catalog-dao/src/main/java/org/openecomp/sdc/be/dao/neo4j/GraphPropertiesDictionary.java @@ -134,6 +134,7 @@ public enum GraphPropertiesDictionary { ICONS ("icons", String.class, false, false), METADATA_KEYS ("metadataKeys", String.class, false, false), USE_SERVICE_SUBSTITUTION_FOR_NESTED_SERVICES ("useServiceSubstitutionForNestedServices", Boolean.class, false, false), + NOT_APPLICABLE_METADATA_KEYS("notApplicableMetadataKeys", String.class, false, false), //relation CAPABILITY_OWNER_ID ("capOwnerId", String.class, false, false), REQUIREMENT_OWNER_ID ("reqOwnerId", String.class, false, false), diff --git a/catalog-dao/src/main/java/org/openecomp/sdc/be/resources/data/category/CategoryData.java b/catalog-dao/src/main/java/org/openecomp/sdc/be/resources/data/category/CategoryData.java index cd585ab4c4..c1c6b2a562 100644 --- a/catalog-dao/src/main/java/org/openecomp/sdc/be/resources/data/category/CategoryData.java +++ b/catalog-dao/src/main/java/org/openecomp/sdc/be/resources/data/category/CategoryData.java @@ -57,8 +57,10 @@ public class CategoryData extends GraphNode { categoryDataDefinition.setUseServiceSubstitutionForNestedServices(useServiceSubstitutionForNestedServices); Type listType = new TypeToken>() { }.getType(); - List iconsfromJson = getGson().fromJson((String) properties.get(GraphPropertiesDictionary.ICONS.getProperty()), listType); - categoryDataDefinition.setIcons(iconsfromJson); + categoryDataDefinition.setNotApplicableMetadataKeys( + getGson().fromJson((String) properties.get(GraphPropertiesDictionary.NOT_APPLICABLE_METADATA_KEYS.getProperty()), listType)); + List iconsFromJson = getGson().fromJson((String) properties.get(GraphPropertiesDictionary.ICONS.getProperty()), listType); + categoryDataDefinition.setIcons(iconsFromJson); categoryDataDefinition.setModels(getGson().fromJson((String) properties.get(GraphPropertiesDictionary.MODEL.getProperty()), listType)); final Type metadataKeylistType = new TypeToken>() { }.getType(); @@ -87,6 +89,7 @@ public class CategoryData extends GraphNode { addIfExists(map, GraphPropertiesDictionary.ICONS, categoryDataDefinition.getIcons()); addIfExists(map, GraphPropertiesDictionary.USE_SERVICE_SUBSTITUTION_FOR_NESTED_SERVICES, categoryDataDefinition.isUseServiceSubstitutionForNestedServices()); + addIfExists(map, GraphPropertiesDictionary.NOT_APPLICABLE_METADATA_KEYS, categoryDataDefinition.getNotApplicableMetadataKeys()); addIfExists(map, GraphPropertiesDictionary.METADATA_KEYS, categoryDataDefinition.getMetadataKeys()); return map; } -- cgit 1.2.3-korg