Fix deployment artifact not shown 80/114880/2
authorsebdet <sebastien.determe@intl.att.com>
Fri, 13 Nov 2020 15:18:15 +0000 (16:18 +0100)
committerChristophe Closset <christophe.closset@intl.att.com>
Mon, 16 Nov 2020 08:09:46 +0000 (08:09 +0000)
Fix deployment artifact not shown when clicking on the composed resource defined in a service.

Issue-ID: SDC-3301
Signed-off-by: sebdet <sebastien.determe@intl.att.com>
Change-Id: I65c5a61d27fad6126a933bf735abb0c99b1896a9

catalog-be/src/main/java/org/openecomp/sdc/be/components/impl/ArtifactsBusinessLogic.java

index c9e0a44..b6efd3e 100644 (file)
@@ -796,7 +796,7 @@ public class ArtifactsBusinessLogic extends BaseBusinessLogic {
                 log.debug("handleGetArtifactsByType - not failed groupType {} , component id {}", artifactGroupType, componentId);
                 throw new ByActionStatusComponentException(ActionStatus.MISSING_INFORMATION);
             }
-            if (groupType == ArtifactGroupTypeEnum.DEPLOYMENT) {
+            if (parentId == null && groupType == ArtifactGroupTypeEnum.DEPLOYMENT) {
                 List<ArtifactDefinition> list = getDeploymentArtifacts(component, componentId);
                 if (list != null && !list.isEmpty()) {
                     resMap = list.stream().collect(Collectors.toMap(ArtifactDataDefinition::getArtifactLabel, Function.identity()));