From 590f2ae1738322c5b4c5bd18d969a848497c16fc Mon Sep 17 00:00:00 2001 From: ds-ext-sceronik Date: Mon, 6 Nov 2023 09:00:04 +0100 Subject: [PATCH 1/6] feature: TRACEFOSS-2796 deep link --- .../asbuilt/mapper/AssetAsBuiltResponseMapper.java | 4 ++-- .../asplanned/mapper/AssetAsPlannedResponseMapper.java | 4 ++-- .../application/base/mapper/AssetBaseResponseMapper.java | 7 +++++-- .../integration/assets/AssetAsPlannedControllerByIdIT.java | 3 ++- .../main/java/assets/response/base/AssetBaseResponse.java | 4 ++-- 5 files changed, 13 insertions(+), 9 deletions(-) diff --git a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asbuilt/mapper/AssetAsBuiltResponseMapper.java b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asbuilt/mapper/AssetAsBuiltResponseMapper.java index c33491cc0b..73f4eed627 100644 --- a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asbuilt/mapper/AssetAsBuiltResponseMapper.java +++ b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asbuilt/mapper/AssetAsBuiltResponseMapper.java @@ -54,8 +54,8 @@ public static AssetAsBuiltResponse from(final AssetBase asset) { .van(asset.getVan()) .semanticDataModel(from(asset.getSemanticDataModel())) .detailAspectModels(fromList(asset.getDetailAspectModels())) - .qualityAlertsInStatusActive(countNotificationsInActiveState(asset.getQualityAlerts())) - .qualityInvestigationsInStatusActive(countNotificationsInActiveState(asset.getQualityInvestigations())) + .qualityAlertsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityAlerts())) + .qualityInvestigationsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityInvestigations())) .build(); } diff --git a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asplanned/mapper/AssetAsPlannedResponseMapper.java b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asplanned/mapper/AssetAsPlannedResponseMapper.java index abb265f8a1..7e342474d3 100644 --- a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asplanned/mapper/AssetAsPlannedResponseMapper.java +++ b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asplanned/mapper/AssetAsPlannedResponseMapper.java @@ -54,8 +54,8 @@ public static AssetAsPlannedResponse from(final AssetBase asset) { .van(asset.getVan()) .semanticDataModel(from(asset.getSemanticDataModel())) .detailAspectModels(fromList(asset.getDetailAspectModels())) - .qualityAlertsInStatusActive(countNotificationsInActiveState(asset.getQualityAlerts())) - .qualityInvestigationsInStatusActive(countNotificationsInActiveState(asset.getQualityInvestigations())) + .qualityAlertsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityAlerts())) + .qualityInvestigationsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityInvestigations())) .build(); } diff --git a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/base/mapper/AssetBaseResponseMapper.java b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/base/mapper/AssetBaseResponseMapper.java index 8d47a8aedf..dcf9449805 100644 --- a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/base/mapper/AssetBaseResponseMapper.java +++ b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/base/mapper/AssetBaseResponseMapper.java @@ -46,6 +46,7 @@ import org.eclipse.tractusx.traceability.assets.domain.base.model.aspect.DetailAspectModel; import org.eclipse.tractusx.traceability.assets.domain.base.model.aspect.DetailAspectType; import org.eclipse.tractusx.traceability.qualitynotification.domain.base.model.QualityNotification; +import org.eclipse.tractusx.traceability.qualitynotification.domain.base.model.QualityNotificationId; import java.util.List; @@ -134,10 +135,12 @@ public static SemanticDataModelResponse from(final SemanticDataModel semanticDat return SemanticDataModelResponse.valueOf(semanticDataModel.name()); } - protected static Integer countNotificationsInActiveState(List notifications) { + protected static List gettNotificationIdsInActiveState(List notifications) { return emptyIfNull(notifications).stream() .filter(QualityNotification::isActiveState) - .toList().size(); + .map(QualityNotification::getNotificationId) + .map(QualityNotificationId::value) + .toList(); } private static List from(List subcomponents) { diff --git a/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsPlannedControllerByIdIT.java b/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsPlannedControllerByIdIT.java index 498afe1ff6..a667233dcd 100644 --- a/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsPlannedControllerByIdIT.java +++ b/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsPlannedControllerByIdIT.java @@ -48,6 +48,7 @@ import static org.eclipse.tractusx.traceability.qualitynotification.infrastructure.model.NotificationStatusBaseEntity.RECEIVED; import static org.eclipse.tractusx.traceability.qualitynotification.infrastructure.model.NotificationStatusBaseEntity.SENT; import static org.hamcrest.Matchers.equalTo; +import static org.hamcrest.Matchers.hasSize; import static org.hamcrest.Matchers.is; import static org.junit.jupiter.params.provider.Arguments.arguments; @@ -98,7 +99,7 @@ void givenAlertsForAsset_whenCallAssetById_thenReturnProperCount() throws JoseEx .log().all() .statusCode(200) .assertThat() - .body("qualityAlertsInStatusActive", is(6)); + .body("qualityAlertsInStatusActive", hasSize(6)); } @Test diff --git a/tx-models/src/main/java/assets/response/base/AssetBaseResponse.java b/tx-models/src/main/java/assets/response/base/AssetBaseResponse.java index f46b33aab8..da80ba5a09 100644 --- a/tx-models/src/main/java/assets/response/base/AssetBaseResponse.java +++ b/tx-models/src/main/java/assets/response/base/AssetBaseResponse.java @@ -76,7 +76,7 @@ public class AssetBaseResponse { private String classification; private List detailAspectModels; @ApiModelProperty(example = "1") - private Integer qualityAlertsInStatusActive; + private List qualityAlertsInStatusActive; @ApiModelProperty(example = "2") - private Integer qualityInvestigationsInStatusActive; + private List qualityInvestigationsInStatusActive; } From 32809f31fa469326f0cc43050b943aea2de44303 Mon Sep 17 00:00:00 2001 From: ds-ext-sceronik Date: Tue, 7 Nov 2023 08:55:37 +0100 Subject: [PATCH 2/6] feature: TRACEFOSS-2796 deep link --- .../openapi/traceability-foss-backend.json | 1678 +++++++++-------- .../mapper/AssetAsBuiltResponseMapper.java | 4 +- .../mapper/AssetAsPlannedResponseMapper.java | 4 +- .../assets/AssetAsBuiltControllerByIdIT.java | 6 +- .../AssetAsPlannedControllerByIdIT.java | 4 +- .../response/base/AssetBaseResponse.java | 8 +- 6 files changed, 876 insertions(+), 828 deletions(-) diff --git a/tx-backend/openapi/traceability-foss-backend.json b/tx-backend/openapi/traceability-foss-backend.json index 397e173b65..c6bed5927a 100644 --- a/tx-backend/openapi/traceability-foss-backend.json +++ b/tx-backend/openapi/traceability-foss-backend.json @@ -41,8 +41,8 @@ "description" : "The endpoint returns a result of BPN EDC URL mappings.", "operationId" : "getBpnEdcs", "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -51,18 +51,20 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "200" : { + "description" : "Returns the paged result found", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "maxItems" : 2147483647, + "minItems" : 0, + "type" : "array" } } } }, - "403" : { - "description" : "Forbidden.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -71,8 +73,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -81,8 +83,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -91,20 +93,18 @@ } } }, - "200" : { - "description" : "Returns the paged result found", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { - "maxItems" : 2147483647, - "minItems" : 0, - "type" : "array" + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -155,18 +155,20 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "200" : { + "description" : "Returns the paged result found for BpnEdcMapping", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "maxItems" : 2147483647, + "minItems" : 0, + "type" : "array" } } } }, - "415" : { - "description" : "Unsupported media type", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -175,8 +177,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -185,20 +187,18 @@ } } }, - "200" : { - "description" : "Returns the paged result found for BpnEdcMapping", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { - "maxItems" : 2147483647, - "minItems" : 0, - "type" : "array" + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -207,8 +207,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -217,8 +217,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -269,18 +269,20 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "200" : { + "description" : "Returns the paged result found for BpnEdcMapping", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "maxItems" : 2147483647, + "minItems" : 0, + "type" : "array" } } } }, - "415" : { - "description" : "Unsupported media type", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -289,8 +291,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -299,20 +301,18 @@ } } }, - "200" : { - "description" : "Returns the paged result found for BpnEdcMapping", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { - "maxItems" : 2147483647, - "minItems" : 0, - "type" : "array" + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -321,8 +321,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -331,8 +331,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -380,8 +380,14 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "200" : { + "description" : "Returns the paged result found", + "content" : { + "application/json" : {} + } + }, + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -390,8 +396,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -400,14 +406,8 @@ } } }, - "200" : { - "description" : "Returns the paged result found", - "content" : { - "application/json" : {} - } - }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -416,8 +416,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -426,8 +426,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -436,8 +436,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -493,8 +493,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -503,8 +503,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -513,8 +513,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -523,8 +523,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No Content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -533,8 +536,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -543,8 +546,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -553,9 +556,6 @@ } } }, - "204" : { - "description" : "No Content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -603,8 +603,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -613,8 +613,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -623,18 +623,20 @@ } } }, - "403" : { - "description" : "Forbidden.", + "200" : { + "description" : "Returns the paged result found for Asset", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "maxItems" : 2147483647, + "minItems" : 0, + "type" : "array" } } } }, - "429" : { - "description" : "Too many requests.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -643,8 +645,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -653,20 +655,18 @@ } } }, - "200" : { - "description" : "Returns the paged result found for Asset", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { - "maxItems" : 2147483647, - "minItems" : 0, - "type" : "array" + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -712,8 +712,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -722,8 +722,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -732,8 +732,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -742,8 +742,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -752,8 +752,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -762,8 +762,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -832,8 +832,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -842,8 +842,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -852,8 +852,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -862,8 +862,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -872,9 +875,9 @@ } } }, - "500" : { - "description" : "Internal server error.", - "content" : { + "403" : { + "description" : "Forbidden.", + "content" : { "application/json" : { "schema" : { "$ref" : "#/components/schemas/ErrorResponse" @@ -882,8 +885,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -892,9 +895,6 @@ } } }, - "204" : { - "description" : "No content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -945,8 +945,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -955,8 +955,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -965,8 +965,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -975,8 +975,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -985,8 +988,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -995,8 +998,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -1005,9 +1008,6 @@ } } }, - "204" : { - "description" : "No content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -1048,8 +1048,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1058,8 +1058,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -1068,8 +1068,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1078,8 +1078,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1088,8 +1091,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1098,8 +1101,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -1108,9 +1111,6 @@ } } }, - "204" : { - "description" : "No content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -1151,8 +1151,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1161,8 +1161,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -1171,8 +1171,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1181,8 +1181,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1191,8 +1194,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1201,8 +1204,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -1211,9 +1214,6 @@ } } }, - "204" : { - "description" : "No content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -1253,8 +1253,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1263,8 +1263,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -1273,8 +1273,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1283,8 +1283,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1293,8 +1293,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1303,8 +1303,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -1362,8 +1362,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1372,8 +1372,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -1382,8 +1382,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1392,8 +1392,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1402,8 +1402,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1412,8 +1412,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -1476,8 +1476,8 @@ } } }, - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1486,8 +1486,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -1496,8 +1496,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1506,8 +1506,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1516,8 +1516,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1526,8 +1526,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -1575,8 +1575,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1585,8 +1585,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -1595,8 +1595,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1605,8 +1605,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1615,8 +1615,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1625,8 +1625,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -1677,8 +1677,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1687,30 +1687,30 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "200" : { + "description" : "Returns the paged result found for Asset", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "maxItems" : 2147483647, + "minItems" : 0, + "type" : "array" } } } }, - "200" : { - "description" : "Returns the paged result found for Asset", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { - "maxItems" : 2147483647, - "minItems" : 0, - "type" : "array" + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1719,8 +1719,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1729,8 +1729,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1739,8 +1739,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -1796,8 +1796,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1806,8 +1806,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -1816,18 +1816,19 @@ } } }, - "403" : { - "description" : "Forbidden.", + "200" : { + "description" : "Returns the paged result found for Asset", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "maxItems" : 2147483647, + "type" : "array" } } } }, - "429" : { - "description" : "Too many requests.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1836,8 +1837,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1846,8 +1847,8 @@ } } }, - "404" : { - "description" : "Not found.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1856,13 +1857,12 @@ } } }, - "200" : { - "description" : "Returns the paged result found for Asset", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { - "maxItems" : 2147483647, - "type" : "array" + "$ref" : "#/components/schemas/ErrorResponse" } } } @@ -1904,8 +1904,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -1914,8 +1914,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -1924,8 +1924,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -1934,8 +1934,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -1944,8 +1944,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -1954,8 +1954,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -2024,8 +2024,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -2034,8 +2034,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -2044,8 +2044,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -2054,8 +2054,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -2064,8 +2067,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -2074,8 +2077,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -2084,9 +2087,6 @@ } } }, - "204" : { - "description" : "No content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -2137,8 +2137,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -2147,8 +2147,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -2157,8 +2157,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -2167,8 +2167,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -2177,8 +2180,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -2187,8 +2190,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -2197,9 +2200,6 @@ } } }, - "204" : { - "description" : "No content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -2240,8 +2240,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -2250,8 +2250,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -2260,8 +2260,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -2270,8 +2270,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -2280,8 +2283,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -2290,8 +2293,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -2300,9 +2303,6 @@ } } }, - "204" : { - "description" : "No content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -2343,8 +2343,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -2353,8 +2353,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -2363,8 +2363,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -2373,8 +2373,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -2383,8 +2386,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -2393,8 +2396,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -2403,9 +2406,6 @@ } } }, - "204" : { - "description" : "No content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -2445,8 +2445,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -2455,8 +2455,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -2465,8 +2465,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -2475,8 +2475,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -2485,8 +2485,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -2495,8 +2495,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -2618,13 +2618,19 @@ "$ref" : "#/components/schemas/DetailAspectModelResponse" } }, - "qualityAlertsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityAlertIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } }, - "qualityInvestigationsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityInvestigationIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } } } } @@ -2679,8 +2685,8 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -2689,8 +2695,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -2699,8 +2705,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -2709,8 +2715,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -2719,8 +2725,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -2729,8 +2735,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -2852,13 +2858,19 @@ "$ref" : "#/components/schemas/DetailAspectModelResponse" } }, - "qualityAlertsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityAlertIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } }, - "qualityInvestigationsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityInvestigationIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } } } } @@ -2905,68 +2917,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "415" : { - "description" : "Unsupported media type", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "403" : { - "description" : "Forbidden.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "429" : { - "description" : "Too many requests.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "500" : { - "description" : "Internal server error.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "404" : { - "description" : "Not found.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "200" : { - "description" : "Returns the assets found", + "200" : { + "description" : "Returns the assets found", "content" : { "application/json" : { "schema" : { @@ -3078,13 +3030,19 @@ "$ref" : "#/components/schemas/DetailAspectModelResponse" } }, - "qualityAlertsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityAlertIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } }, - "qualityInvestigationsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityInvestigationIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } } } } @@ -3092,6 +3050,66 @@ } } }, + "429" : { + "description" : "Too many requests.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "500" : { + "description" : "Internal server error.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "404" : { + "description" : "Not found.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "401" : { + "description" : "Authorization failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "403" : { + "description" : "Forbidden.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "415" : { + "description" : "Unsupported media type", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, "400" : { "description" : "Bad request.", "content" : { @@ -3139,36 +3157,6 @@ "required" : true }, "responses" : { - "401" : { - "description" : "Authorization failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "415" : { - "description" : "Unsupported media type", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "403" : { - "description" : "Forbidden.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, "429" : { "description" : "Too many requests.", "content" : { @@ -3312,13 +3300,19 @@ "$ref" : "#/components/schemas/DetailAspectModelResponse" } }, - "qualityAlertsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityAlertIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } }, - "qualityInvestigationsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityInvestigationIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } } } } @@ -3326,6 +3320,36 @@ } } }, + "401" : { + "description" : "Authorization failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "403" : { + "description" : "Forbidden.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "415" : { + "description" : "Unsupported media type", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, "400" : { "description" : "Bad request.", "content" : { @@ -3355,8 +3379,8 @@ "description" : "The endpoint returns all shell descriptors.", "operationId" : "findAll", "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -3365,8 +3389,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -3375,8 +3399,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -3385,18 +3409,21 @@ } } }, - "429" : { - "description" : "Too many requests.", + "200" : { + "description" : "ShellDescriptors found.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/ShellDescriptorResponse" + } } } } }, - "500" : { - "description" : "Internal server error.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -3405,21 +3432,18 @@ } } }, - "200" : { - "description" : "ShellDescriptors found.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { - "type" : "array", - "items" : { - "$ref" : "#/components/schemas/ShellDescriptorResponse" - } + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -3456,8 +3480,8 @@ "description" : "The endpoint deletes all shell descriptors.", "operationId" : "deleteAll", "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -3466,8 +3490,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -3476,8 +3500,11 @@ } } }, - "403" : { - "description" : "Forbidden.", + "204" : { + "description" : "Deleted." + }, + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -3486,11 +3513,8 @@ } } }, - "204" : { - "description" : "Deleted." - }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -3499,8 +3523,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -3509,8 +3533,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -3548,8 +3572,8 @@ "description" : "The endpoint Triggers reload of shell descriptors.", "operationId" : "reload", "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -3558,8 +3582,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -3568,8 +3592,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -3578,8 +3602,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "202" : { + "description" : "Created registry reload job." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -3588,8 +3615,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -3598,11 +3625,8 @@ } } }, - "202" : { - "description" : "Created registry reload job." - }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -3651,18 +3675,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "415" : { - "description" : "Unsupported media type", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -3671,8 +3685,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -3697,8 +3711,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -3707,8 +3721,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -3717,8 +3731,18 @@ } } }, - "404" : { - "description" : "Not found.", + "403" : { + "description" : "Forbidden.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -3756,18 +3780,18 @@ "description" : "The endpoint can return limited data based on the user role", "operationId" : "dashboard", "responses" : { - "200" : { - "description" : "Returns dashboard data", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/DashboardResponse" + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "401" : { - "description" : "Authorization failed.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -3776,8 +3800,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -3786,18 +3810,18 @@ } } }, - "403" : { - "description" : "Forbidden.", + "200" : { + "description" : "Returns dashboard data", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "$ref" : "#/components/schemas/DashboardResponse" } } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -3806,8 +3830,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -3816,8 +3840,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -3873,8 +3897,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -3883,8 +3907,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -3893,8 +3917,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -4020,13 +4044,19 @@ "$ref" : "#/components/schemas/DetailAspectModelResponse" } }, - "qualityAlertsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityAlertIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } }, - "qualityInvestigationsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityInvestigationIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } } } } @@ -4035,8 +4065,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -4045,8 +4075,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -4055,8 +4085,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -4112,36 +4142,6 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "415" : { - "description" : "Unsupported media type", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "403" : { - "description" : "Forbidden.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, "200" : { "description" : "Returns the asset by childId", "content" : { @@ -4255,13 +4255,19 @@ "$ref" : "#/components/schemas/DetailAspectModelResponse" } }, - "qualityAlertsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityAlertIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } }, - "qualityInvestigationsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityInvestigationIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } } } } @@ -4299,6 +4305,36 @@ } } }, + "401" : { + "description" : "Authorization failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "403" : { + "description" : "Forbidden.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "415" : { + "description" : "Unsupported media type", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, "400" : { "description" : "Bad request.", "content" : { @@ -4356,20 +4392,18 @@ } ], "responses" : { - "200" : { - "description" : "Returns a distinct filter values for given fieldName.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { - "maxItems" : 2147483647, - "minItems" : 0, - "type" : "array" + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "401" : { - "description" : "Authorization failed.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -4378,8 +4412,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -4388,8 +4422,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -4398,8 +4432,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -4408,8 +4442,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -4418,12 +4452,14 @@ } } }, - "404" : { - "description" : "Not found.", + "200" : { + "description" : "Returns a distinct filter values for given fieldName.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "maxItems" : 2147483647, + "minItems" : 0, + "type" : "array" } } } @@ -4475,18 +4511,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "415" : { - "description" : "Unsupported media type", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -4495,8 +4521,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -4505,8 +4531,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -4515,8 +4541,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -4525,8 +4551,8 @@ } } }, - "404" : { - "description" : "Not found.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -4535,8 +4561,8 @@ } } }, - "400" : { - "description" : "Bad request.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -4662,13 +4688,19 @@ "$ref" : "#/components/schemas/DetailAspectModelResponse" } }, - "qualityAlertsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityAlertIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } }, - "qualityInvestigationsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityInvestigationIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } } } } @@ -4676,6 +4708,16 @@ } } } + }, + "400" : { + "description" : "Bad request.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } } }, "security" : [ @@ -4698,72 +4740,22 @@ "parameters" : [ { "name" : "assetId", - "in" : "path", - "required" : true, - "schema" : { - "type" : "string" - } - }, - { - "name" : "childId", - "in" : "path", - "required" : true, - "schema" : { - "type" : "string" - } - } - ], - "responses" : { - "401" : { - "description" : "Authorization failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "415" : { - "description" : "Unsupported media type", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "403" : { - "description" : "Forbidden.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "429" : { - "description" : "Too many requests.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } + "in" : "path", + "required" : true, + "schema" : { + "type" : "string" } }, - "500" : { - "description" : "Internal server error.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } + { + "name" : "childId", + "in" : "path", + "required" : true, + "schema" : { + "type" : "string" } - }, + } + ], + "responses" : { "200" : { "description" : "Returns the asset by childId", "content" : { @@ -4877,13 +4869,19 @@ "$ref" : "#/components/schemas/DetailAspectModelResponse" } }, - "qualityAlertsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityAlertIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } }, - "qualityInvestigationsInStatusActive" : { - "type" : "integer", - "format" : "int32" + "qualityInvestigationIdsInStatusActive" : { + "type" : "array", + "items" : { + "type" : "integer", + "format" : "int64" + } } } } @@ -4891,6 +4889,26 @@ } } }, + "429" : { + "description" : "Too many requests.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "500" : { + "description" : "Internal server error.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, "404" : { "description" : "Not found.", "content" : { @@ -4901,6 +4919,36 @@ } } }, + "401" : { + "description" : "Authorization failed.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "403" : { + "description" : "Forbidden.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "415" : { + "description" : "Unsupported media type", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, "400" : { "description" : "Bad request.", "content" : { @@ -4958,20 +5006,18 @@ } ], "responses" : { - "200" : { - "description" : "Returns a distinct filter values for given fieldName.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { - "maxItems" : 2147483647, - "minItems" : 0, - "type" : "array" + "$ref" : "#/components/schemas/ErrorResponse" } } } }, - "401" : { - "description" : "Authorization failed.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -4980,8 +5026,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -4990,8 +5036,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -5000,8 +5046,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -5010,8 +5056,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -5020,12 +5066,14 @@ } } }, - "404" : { - "description" : "Not found.", + "200" : { + "description" : "Returns a distinct filter values for given fieldName.", "content" : { "application/json" : { "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" + "maxItems" : 2147483647, + "minItems" : 0, + "type" : "array" } } } @@ -5059,18 +5107,8 @@ "description" : "The endpoint returns a map for assets consumed by the map.", "operationId" : "assetsCountryMap", "responses" : { - "401" : { - "description" : "Authorization failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "415" : { - "description" : "Unsupported media type", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -5079,8 +5117,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -5103,8 +5141,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -5113,8 +5151,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -5123,8 +5161,18 @@ } } }, - "404" : { - "description" : "Not found.", + "403" : { + "description" : "Forbidden.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -5173,18 +5221,8 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", - "content" : { - "application/json" : { - "schema" : { - "$ref" : "#/components/schemas/ErrorResponse" - } - } - } - }, - "415" : { - "description" : "Unsupported media type", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -5193,8 +5231,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -5218,8 +5256,8 @@ } } }, - "429" : { - "description" : "Too many requests.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -5228,8 +5266,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -5238,8 +5276,18 @@ } } }, - "404" : { - "description" : "Not found.", + "403" : { + "description" : "Forbidden.", + "content" : { + "application/json" : { + "schema" : { + "$ref" : "#/components/schemas/ErrorResponse" + } + } + } + }, + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -5277,8 +5325,8 @@ "description" : "Deletes all submodels from the system.", "operationId" : "deleteSubmodels", "responses" : { - "401" : { - "description" : "Authorization failed.", + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -5287,8 +5335,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -5297,8 +5345,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -5307,8 +5355,11 @@ } } }, - "429" : { - "description" : "Too many requests.", + "204" : { + "description" : "No Content." + }, + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -5317,8 +5368,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -5327,8 +5378,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { @@ -5337,9 +5388,6 @@ } } }, - "204" : { - "description" : "No Content." - }, "400" : { "description" : "Bad request.", "content" : { @@ -5379,8 +5427,11 @@ } ], "responses" : { - "401" : { - "description" : "Authorization failed.", + "204" : { + "description" : "Deleted." + }, + "429" : { + "description" : "Too many requests.", "content" : { "application/json" : { "schema" : { @@ -5389,8 +5440,8 @@ } } }, - "415" : { - "description" : "Unsupported media type", + "500" : { + "description" : "Internal server error.", "content" : { "application/json" : { "schema" : { @@ -5399,8 +5450,8 @@ } } }, - "403" : { - "description" : "Forbidden.", + "404" : { + "description" : "Not found.", "content" : { "application/json" : { "schema" : { @@ -5409,11 +5460,8 @@ } } }, - "204" : { - "description" : "Deleted." - }, - "429" : { - "description" : "Too many requests.", + "401" : { + "description" : "Authorization failed.", "content" : { "application/json" : { "schema" : { @@ -5422,8 +5470,8 @@ } } }, - "500" : { - "description" : "Internal server error.", + "403" : { + "description" : "Forbidden.", "content" : { "application/json" : { "schema" : { @@ -5432,8 +5480,8 @@ } } }, - "404" : { - "description" : "Not found.", + "415" : { + "description" : "Unsupported media type", "content" : { "application/json" : { "schema" : { diff --git a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asbuilt/mapper/AssetAsBuiltResponseMapper.java b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asbuilt/mapper/AssetAsBuiltResponseMapper.java index 73f4eed627..10cfb0c4b8 100644 --- a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asbuilt/mapper/AssetAsBuiltResponseMapper.java +++ b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asbuilt/mapper/AssetAsBuiltResponseMapper.java @@ -54,8 +54,8 @@ public static AssetAsBuiltResponse from(final AssetBase asset) { .van(asset.getVan()) .semanticDataModel(from(asset.getSemanticDataModel())) .detailAspectModels(fromList(asset.getDetailAspectModels())) - .qualityAlertsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityAlerts())) - .qualityInvestigationsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityInvestigations())) + .qualityAlertIdsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityAlerts())) + .qualityInvestigationIdsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityInvestigations())) .build(); } diff --git a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asplanned/mapper/AssetAsPlannedResponseMapper.java b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asplanned/mapper/AssetAsPlannedResponseMapper.java index 7e342474d3..4c6f391b4e 100644 --- a/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asplanned/mapper/AssetAsPlannedResponseMapper.java +++ b/tx-backend/src/main/java/org/eclipse/tractusx/traceability/assets/application/asplanned/mapper/AssetAsPlannedResponseMapper.java @@ -54,8 +54,8 @@ public static AssetAsPlannedResponse from(final AssetBase asset) { .van(asset.getVan()) .semanticDataModel(from(asset.getSemanticDataModel())) .detailAspectModels(fromList(asset.getDetailAspectModels())) - .qualityAlertsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityAlerts())) - .qualityInvestigationsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityInvestigations())) + .qualityAlertIdsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityAlerts())) + .qualityInvestigationIdsInStatusActive(gettNotificationIdsInActiveState(asset.getQualityInvestigations())) .build(); } diff --git a/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsBuiltControllerByIdIT.java b/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsBuiltControllerByIdIT.java index 3393e765a8..d2788093ab 100644 --- a/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsBuiltControllerByIdIT.java +++ b/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsBuiltControllerByIdIT.java @@ -49,7 +49,7 @@ import static org.eclipse.tractusx.traceability.qualitynotification.infrastructure.model.NotificationStatusBaseEntity.RECEIVED; import static org.eclipse.tractusx.traceability.qualitynotification.infrastructure.model.NotificationStatusBaseEntity.SENT; import static org.hamcrest.Matchers.equalTo; -import static org.hamcrest.Matchers.is; +import static org.hamcrest.Matchers.hasSize; import static org.junit.jupiter.params.provider.Arguments.arguments; class AssetAsBuiltControllerByIdIT extends IntegrationTestSpecification { @@ -101,7 +101,7 @@ void givenAlertsForAsset_whenCallAssetById_thenReturnProperCount() throws JoseEx .log().all() .statusCode(200) .assertThat() - .body("qualityAlertsInStatusActive", is(6)); + .body("qualityAlertIdsInStatusActive", hasSize(6)); } @Test @@ -127,7 +127,7 @@ void givenInvestigationsForAsset_whenCallAssetById_thenReturnProperCount() throw .then() .statusCode(200) .assertThat() - .body("qualityInvestigationsInStatusActive", is(6)); + .body("qualityInvestigationIdsInStatusActive", hasSize(6)); } @Test diff --git a/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsPlannedControllerByIdIT.java b/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsPlannedControllerByIdIT.java index a667233dcd..9fb9bc8e15 100644 --- a/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsPlannedControllerByIdIT.java +++ b/tx-backend/src/test/java/org/eclipse/tractusx/traceability/integration/assets/AssetAsPlannedControllerByIdIT.java @@ -99,7 +99,7 @@ void givenAlertsForAsset_whenCallAssetById_thenReturnProperCount() throws JoseEx .log().all() .statusCode(200) .assertThat() - .body("qualityAlertsInStatusActive", hasSize(6)); + .body("qualityAlertIdsInStatusActive", hasSize(6)); } @Test @@ -125,7 +125,7 @@ void givenInvestigationsForAsset_whenCallAssetById_thenReturnProperCount() throw .then() .statusCode(200) .assertThat() - .body("qualityInvestigationsInStatusActive", is(6)); + .body("qualityInvestigationIdsInStatusActive", hasSize(6)); } @Test diff --git a/tx-models/src/main/java/assets/response/base/AssetBaseResponse.java b/tx-models/src/main/java/assets/response/base/AssetBaseResponse.java index da80ba5a09..7e6b1d5dc4 100644 --- a/tx-models/src/main/java/assets/response/base/AssetBaseResponse.java +++ b/tx-models/src/main/java/assets/response/base/AssetBaseResponse.java @@ -75,8 +75,8 @@ public class AssetBaseResponse { @Size(max = 255) private String classification; private List detailAspectModels; - @ApiModelProperty(example = "1") - private List qualityAlertsInStatusActive; - @ApiModelProperty(example = "2") - private List qualityInvestigationsInStatusActive; + @ApiModelProperty(dataType = "List", example = "1") + private List qualityAlertIdsInStatusActive; + @ApiModelProperty(dataType = "List", example = "2") + private List qualityInvestigationIdsInStatusActive; } From 6375582c20c765bd98fd1714a3821ee85470fa11 Mon Sep 17 00:00:00 2001 From: ds-ext-sceronik Date: Tue, 7 Nov 2023 08:59:29 +0100 Subject: [PATCH 3/6] feature: TRACEFOSS-2796 deep link --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ad0b073063..3f25f498c3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -36,6 +36,7 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - changed assetAsBuilt filtering manufacturerId to businessPartner - IRS-Client-Lib from 1.2.1-SNAPSHOT to 1.4.0 - Decoupled dependency check in a separate GitHub action +- Assets response have now list of notification ids rather than count of existing notifications ### Removed - Removed &filterOperator=AND from filtering requests From bf61294c3b8cc88a590f67eebc2ae709eb384c8c Mon Sep 17 00:00:00 2001 From: Maximilian Wesener Date: Tue, 7 Nov 2023 10:58:24 +0100 Subject: [PATCH 4/6] chore: TRACEFOSS-2796 deeplink functionality frontend. --- CHANGELOG.md | 1 + .../partsAsBuilt/partsAsBuilt.model.ts | 60 ++--- .../modules/page/parts/model/parts.model.ts | 226 +++++++++--------- .../shared/assembler/parts.assembler.ts | 8 +- .../parts-table/parts-table.component.html | 3 + 5 files changed, 151 insertions(+), 147 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6f3c53931b..9009907c8a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,7 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - Fixed name of veracode backend job - Bump jetty-http from 11.0.15 to 11.0.17 - Assets response have now list of notification ids rather than count of existing notifications +- Frontend adapt to backend api changes for activeAlerts and activeInvestigations ### Removed diff --git a/frontend/src/app/mocks/services/parts-mock/partsAsBuilt/partsAsBuilt.model.ts b/frontend/src/app/mocks/services/parts-mock/partsAsBuilt/partsAsBuilt.model.ts index bdf17103bc..7c7a7af6a5 100644 --- a/frontend/src/app/mocks/services/parts-mock/partsAsBuilt/partsAsBuilt.model.ts +++ b/frontend/src/app/mocks/services/parts-mock/partsAsBuilt/partsAsBuilt.model.ts @@ -64,8 +64,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:0733946c-59c6-41ae-9570-cb43a6e43842", @@ -96,8 +96,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive:[], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:4a5e9ff6-2d5c-4510-a90e-d55af3ba502f", @@ -136,8 +136,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive:[], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:1be6ec59-40fb-4993-9836-acb0e284fa03", @@ -173,8 +173,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:1be6ec59-40fb-4993-9836-acb0e284fa01", @@ -205,8 +205,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:d8030bbf-a874-49fb-b2e1-7610f0ccad12", @@ -242,8 +242,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:5205f736-8fc2-4585-b869-6bf36842369a", @@ -274,8 +274,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:1be6ec59-40fb-4993-9836-acb0e284fa02", @@ -311,8 +311,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive:[], }, { "id": "urn:uuid:1be6ec59-40fb-4993-9836-acb0e284fb01", @@ -343,8 +343,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:6b2296cc-26c0-4f38-8a22-092338c36e22", @@ -380,8 +380,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:c47b9f8b-48d0-4ef4-8f0b-e965a225cb8d", @@ -412,8 +412,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:f11ddc62-3bd5-468f-b7b0-110fe13ed0cd", @@ -444,8 +444,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }, { "id": "urn:uuid:1be6ec59-40fb-4993-9836-acb0e284fb02", @@ -476,8 +476,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive:[], }, { "id": "urn:uuid:7eeeac86-7b69-444d-81e6-655d0f1513bd", @@ -508,8 +508,8 @@ export const mockBmwAssets = [ } } ], - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive:[], + qualityInvestigationIdsInStatusActive: [], }, ] as PartResponse[]; @@ -541,8 +541,8 @@ const MockEmptyPart: PartResponse = { qualityType: QualityType.Ok, van: null, semanticDataModel: SemanticDataModel.SERIALPART, - qualityAlertsInStatusActive: 0, - qualityInvestigationsInStatusActive: 0, + qualityAlertIdsInStatusActive: [], + qualityInvestigationIdsInStatusActive: [], }; diff --git a/frontend/src/app/modules/page/parts/model/parts.model.ts b/frontend/src/app/modules/page/parts/model/parts.model.ts index 9b2234a088..cd32d4ca27 100644 --- a/frontend/src/app/modules/page/parts/model/parts.model.ts +++ b/frontend/src/app/modules/page/parts/model/parts.model.ts @@ -26,75 +26,75 @@ import { MainAspectType } from '@page/parts/model/mainAspectType.enum'; import { Owner } from '@page/parts/model/owner.enum'; export interface Part { - id: string; - idShort: string; - name: string; - manufacturer: string; - manufacturerPartId: string; - nameAtManufacturer: string; - businessPartner: string - semanticModel?: SemanticModel; - semanticModelId: string; - qualityType: QualityType; - children: string[]; - parents?: string[]; - error?: boolean; - activeInvestigation?: boolean; - activeAlert: boolean; - van: string; - semanticDataModel: SemanticDataModel; - classification: string; - - mainAspectType: MainAspectType; - - // aspectmodel props are temporarely hardcoded here because Tables and Views only accept root level prop array - // as built - partId?: string; - customerPartId?: string; - nameAtCustomer?: string; - manufacturingDate?: string; - manufacturingCountry?: string; - - productType?: string; - tractionBatteryCode?: string; - subcomponents: TractionBatteryCode[]; - - // as planned - validityPeriodFrom?: string; - validityPeriodTo?: string; - //partSiteInformationAsPlanned - catenaXSiteId: string; - psFunction: string; - functionValidFrom?: string; - functionValidUntil?: string; + id: string; + idShort: string; + name: string; + manufacturer: string; + manufacturerPartId: string; + nameAtManufacturer: string; + businessPartner: string; + semanticModel?: SemanticModel; + semanticModelId: string; + qualityType: QualityType; + children: string[]; + parents?: string[]; + error?: boolean; + activeInvestigation?: boolean; + activeAlert: boolean; + van: string; + semanticDataModel: SemanticDataModel; + classification: string; + + mainAspectType: MainAspectType; + + // aspectmodel props are temporarely hardcoded here because Tables and Views only accept root level prop array + // as built + partId?: string; + customerPartId?: string; + nameAtCustomer?: string; + manufacturingDate?: string; + manufacturingCountry?: string; + + productType?: string; + tractionBatteryCode?: string; + subcomponents: TractionBatteryCode[]; + + // as planned + validityPeriodFrom?: string; + validityPeriodTo?: string; + //partSiteInformationAsPlanned + catenaXSiteId: string; + psFunction: string; + functionValidFrom?: string; + functionValidUntil?: string; // count of notifications - activeAlerts: number; - activeInvestigations: number; + activeAlerts: string []; + activeInvestigations: string []; } export interface PartResponse { - id: string; - idShort: string; - semanticModelId: string; - manufacturerPartId: string; - businessPartner: string; - manufacturerName: string; - nameAtManufacturer: string; - owner: Owner; - childRelations: Relation[]; - parentRelations: Relation[]; - activeAlert: boolean; - underInvestigation: boolean; - qualityType: QualityType; - van: string; - semanticDataModel: SemanticDataModel; - classification: string; + id: string; + idShort: string; + semanticModelId: string; + manufacturerPartId: string; + businessPartner: string; + manufacturerName: string; + nameAtManufacturer: string; + owner: Owner; + childRelations: Relation[]; + parentRelations: Relation[]; + activeAlert: boolean; + underInvestigation: boolean; + qualityType: QualityType; + van: string; + semanticDataModel: SemanticDataModel; + classification: string; detailAspectModels: DetailAspectModel[]; // TODO: Delete ? flag when AsPlanned Parts do not return the props anymore - qualityAlertsInStatusActive?: number; - qualityInvestigationsInStatusActive?: number; + qualityAlertIdsInStatusActive?: string[]; + qualityInvestigationIdsInStatusActive?: string[]; } @@ -102,77 +102,77 @@ export type PartsResponse = PaginationResponse; // TODO: needs to be aligned with Severity in the future in terms of coding standards and use export enum QualityType { - Ok = 'Ok', - Minor = 'Minor', - Major = 'Major', - Critical = 'Critical', - LifeThreatening = 'LifeThreatening', + Ok = 'Ok', + Minor = 'Minor', + Major = 'Major', + Critical = 'Critical', + LifeThreatening = 'LifeThreatening', } export enum SemanticDataModel { - BATCH = 'BATCH', - SERIALPART = 'SERIALPART', - PARTASPLANNED = 'PARTASPLANNED', - JUSTINSEQUENCE = 'JUSTINSEQUENCE', - TRACTIONBATTERYCODE = 'TRACTIONBATTERYCODE', - UNKNOWN = 'UNKNOWN' + BATCH = 'BATCH', + SERIALPART = 'SERIALPART', + PARTASPLANNED = 'PARTASPLANNED', + JUSTINSEQUENCE = 'JUSTINSEQUENCE', + TRACTIONBATTERYCODE = 'TRACTIONBATTERYCODE', + UNKNOWN = 'UNKNOWN' } export enum SemanticDataModelInCamelCase { - BATCH = "Batch", - SERIALPART = 'SerialPart', - PARTASPLANNED = 'PartAsPlanned', - JUSTINSEQUENCE = 'JustInSequence', - TRACTIONBATTERYCODE = 'TractionBatteryCode', - UNKNOWN = 'Unknown' + BATCH = 'Batch', + SERIALPART = 'SerialPart', + PARTASPLANNED = 'PartAsPlanned', + JUSTINSEQUENCE = 'JustInSequence', + TRACTIONBATTERYCODE = 'TractionBatteryCode', + UNKNOWN = 'Unknown' } export interface Relation { - id: string; - idShort: string; + id: string; + idShort: string; } export interface AssetAsBuiltFilter { - id?: string, - idShort?: string, - name?: string, - manufacturer?: string, - partId?: string, - manufacturerPartId?: string, - customerPartId?: string, - classification?: string, - nameAtCustomer?: string, - semanticModelId?: string, - semanticDataModel?: string[], - manufacturingDate?: string, - manufacturingCountry?: string + id?: string, + idShort?: string, + name?: string, + manufacturer?: string, + partId?: string, + manufacturerPartId?: string, + customerPartId?: string, + classification?: string, + nameAtCustomer?: string, + semanticModelId?: string, + semanticDataModel?: string[], + manufacturingDate?: string, + manufacturingCountry?: string } export interface AssetAsPlannedFilter { - id?: string, - idShort?: string, - name?: string, - manufacturer?: string, - manufacturerPartId?: string, - classification?: string, - semanticDataModel?: string[], - semanticModelId?: string, - validityPeriodFrom?: string, - validityPeriodTo?: string, - psFunction?: string, - catenaXSiteId?: string, - functionValidFrom?: string, - functionValidUntil?: string, + id?: string, + idShort?: string, + name?: string, + manufacturer?: string, + manufacturerPartId?: string, + classification?: string, + semanticDataModel?: string[], + semanticModelId?: string, + validityPeriodFrom?: string, + validityPeriodTo?: string, + psFunction?: string, + catenaXSiteId?: string, + functionValidFrom?: string, + functionValidUntil?: string, } export enum FilterOperator { - EQUAL = 'EQUAL', - AT_LOCAL_DATE = 'AT_LOCAL_DATE', - STARTS_WITH = 'STARTS_WITH', - BEFORE_LOCAL_DATE = "BEFORE_LOCAL_DATE", - AFTER_LOCAL_DATE = "AFTER_LOCAL_DATE" + EQUAL = 'EQUAL', + AT_LOCAL_DATE = 'AT_LOCAL_DATE', + STARTS_WITH = 'STARTS_WITH', + BEFORE_LOCAL_DATE = 'BEFORE_LOCAL_DATE', + AFTER_LOCAL_DATE = 'AFTER_LOCAL_DATE' } export function getFilterOperatorValue(operator: FilterOperator) { - return operator as string; + return operator as string; } diff --git a/frontend/src/app/modules/shared/assembler/parts.assembler.ts b/frontend/src/app/modules/shared/assembler/parts.assembler.ts index 3f81fdce98..93c1a01281 100644 --- a/frontend/src/app/modules/shared/assembler/parts.assembler.ts +++ b/frontend/src/app/modules/shared/assembler/parts.assembler.ts @@ -117,8 +117,8 @@ export class PartsAssembler { functionValidUntil: functionValidUntil, // count of notifications - activeAlerts: partResponse.qualityAlertsInStatusActive, - activeInvestigations: partResponse.qualityInvestigationsInStatusActive, + activeAlerts: partResponse.qualityAlertIdsInStatusActive, + activeInvestigations: partResponse.qualityInvestigationIdsInStatusActive, } return mappedPart; @@ -269,8 +269,8 @@ export class PartsAssembler { ['psFunction', 'function'], ['functionValidFrom', 'functionValidFrom'], ['functionValidUntil', 'functionValidUntil'], - [ 'activeAlerts', 'qualityAlertsInStatusActive' ], - [ 'activeInvestigations', 'qualityInvestigationsInStatusActive' ], + [ 'activeAlerts', 'qualityAlertIdsInStatusActive' ], + [ 'activeInvestigations', 'qualityInvestigationIdsInStatusActive' ], ]); diff --git a/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html b/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html index fe5b7f90ca..20c8f2aad1 100644 --- a/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html +++ b/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html @@ -198,6 +198,9 @@

{{ 'table.noResultFound' | i18n }}

{{ element[column] | date:'yyyy-MM-dd' }} + + {{ element[column].length }} + Date: Tue, 7 Nov 2023 11:09:06 +0100 Subject: [PATCH 5/6] chore: TRACEFOSS-2796 deeplink functionality frontend. --- .../shared/components/parts-table/parts-table.component.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html b/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html index 20c8f2aad1..1c6cfc3ec9 100644 --- a/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html +++ b/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html @@ -199,7 +199,7 @@

{{ 'table.noResultFound' | i18n }}

- {{ element[column].length }} + {{ element[column]?.length }} From c6db53b3ba2f0d68e29c7c838441db1e9055c7f4 Mon Sep 17 00:00:00 2001 From: Maximilian Wesener Date: Tue, 7 Nov 2023 11:14:02 +0100 Subject: [PATCH 6/6] chore: TRACEFOSS-2796 deeplink functionality frontend. --- .../components/parts-table/parts-table.component.html | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html b/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html index 1c6cfc3ec9..45732e5b55 100644 --- a/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html +++ b/frontend/src/app/modules/shared/components/parts-table/parts-table.component.html @@ -194,13 +194,10 @@

{{ 'table.noResultFound' | i18n }}

- - {{ element[column] | date:'yyyy-MM-dd' }} - - - - {{ element[column]?.length }} - + + + {{isDateElement(column) ? (element[column] | date:'yyyy-MM-dd') : element[column]?.length }} +