From b529a03688d6ab29853bea857178453ce3b57fd5 Mon Sep 17 00:00:00 2001 From: Rick de Rooij <rick.de.rooij@contezza.nl> Date: Wed, 12 Feb 2025 13:09:24 +0100 Subject: [PATCH 01/22] :page_facing_up: update license --- platform/LICENSE_HEADER.txt | 2 +- .../contezza/drc/audit/extractor/AuditMessageDataExtractor.java | 2 +- .../nl/contezza/drc/audit/extractor/ClientIdDataExtractor.java | 2 +- .../contezza/drc/audit/extractor/ResourceUrlDataExtractor.java | 2 +- .../contezza/drc/audit/extractor/ResourceViewDataExtractor.java | 2 +- .../contezza/drc/audit/extractor/StatusCodeDataExtractor.java | 2 +- .../nl/contezza/drc/audit/extractor/UserIdDataExtractor.java | 2 +- .../drc/audit/extractor/UserRepresentationDataExtractor.java | 2 +- .../java/nl/contezza/drc/audit/extractor/UuidDataExtractor.java | 2 +- .../drc/authentication/DRCRemoteUserAuthenticatorFactory.java | 2 +- .../drc/behaviour/IdentifierAndVersioningBehaviour.java | 2 +- .../java/nl/contezza/drc/behaviour/NotificatiesBehaviour.java | 2 +- .../src/main/java/nl/contezza/drc/helper/Bestandsdelen.java | 2 +- .../java/nl/contezza/drc/helper/DRCBestandsdelenHelper.java | 2 +- .../java/nl/contezza/drc/helper/DRCFieldValidationError.java | 2 +- .../main/java/nl/contezza/drc/helper/DRCStatusException.java | 2 +- .../main/java/nl/contezza/drc/helper/DRCValidationHelper.java | 2 +- .../src/main/java/nl/contezza/drc/messaging/BaseMessage.java | 2 +- .../java/nl/contezza/drc/messaging/DRCMessageGenerator.java | 2 +- .../java/nl/contezza/drc/messaging/DRCMessageGeneratorImpl.java | 2 +- .../main/java/nl/contezza/drc/messaging/DRCMessageListener.java | 2 +- .../src/main/java/nl/contezza/drc/messaging/NodeMessage.java | 2 +- platform/src/main/java/nl/contezza/drc/model/RGBZModel.java | 2 +- .../main/java/nl/contezza/drc/script/DRCAuditServiceScript.java | 2 +- .../src/main/java/nl/contezza/drc/script/DRCServiceScript.java | 2 +- platform/src/main/java/nl/contezza/drc/service/AuthLevel.java | 2 +- .../src/main/java/nl/contezza/drc/service/DRCAuditService.java | 2 +- .../java/nl/contezza/drc/service/DRCAutorisatiesService.java | 2 +- .../main/java/nl/contezza/drc/service/DRCBesluitenService.java | 2 +- .../main/java/nl/contezza/drc/service/DRCCatalogiService.java | 2 +- .../java/nl/contezza/drc/service/DRCNotificatiesService.java | 2 +- platform/src/main/java/nl/contezza/drc/service/DRCService.java | 2 +- .../src/main/java/nl/contezza/drc/service/DRCZakenService.java | 2 +- .../java/nl/contezza/drc/util/CustomAuditQueryParameters.java | 2 +- platform/src/main/java/nl/contezza/drc/util/DateUtil.java | 2 +- platform/src/main/java/nl/contezza/drc/util/ETag.java | 2 +- platform/src/main/java/nl/contezza/drc/util/ElfProef.java | 2 +- .../contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java | 2 +- platform/src/main/java/nl/contezza/drc/webscript/V1Get.java | 2 +- .../src/main/java/nl/contezza/drc/webscript/V1SchemaGet.java | 2 +- .../contezza/drc/webscript/bestandsdelen/BestandsdelenPut.java | 2 +- .../EnkelvoudiginformatieobjectTemplateNode.java | 2 +- .../EnkelvoudiginformatieobjectVersionHistoryNode.java | 2 +- .../EnkelvoudiginformatieobjectenDelete.java | 2 +- .../EnkelvoudiginformatieobjectenDownloadGet.java | 2 +- .../EnkelvoudiginformatieobjectenGet.java | 2 +- .../EnkelvoudiginformatieobjectenHead.java | 2 +- .../EnkelvoudiginformatieobjectenPatch.java | 2 +- .../EnkelvoudiginformatieobjectenPost.java | 2 +- .../EnkelvoudiginformatieobjectenPut.java | 2 +- .../drc/webscript/gebruiksrechten/GebruiksrechtenDelete.java | 2 +- .../drc/webscript/gebruiksrechten/GebruiksrechtenGet.java | 2 +- .../drc/webscript/gebruiksrechten/GebruiksrechtenHead.java | 2 +- .../drc/webscript/gebruiksrechten/GebruiksrechtenPatch.java | 2 +- .../drc/webscript/gebruiksrechten/GebruiksrechtenPost.java | 2 +- .../drc/webscript/gebruiksrechten/GebruiksrechtenPut.java | 2 +- .../ObjectinformatieobjectenDelete.java | 2 +- .../objectinformatieobjecten/ObjectinformatieobjectenGet.java | 2 +- .../objectinformatieobjecten/ObjectinformatieobjectenHead.java | 2 +- .../objectinformatieobjecten/ObjectinformatieobjectenPost.java | 2 +- 60 files changed, 60 insertions(+), 60 deletions(-) diff --git a/platform/LICENSE_HEADER.txt b/platform/LICENSE_HEADER.txt index 6997026..8bb8373 100644 --- a/platform/LICENSE_HEADER.txt +++ b/platform/LICENSE_HEADER.txt @@ -1,4 +1,4 @@ -Copyright 2022-2024 Contezza BV, the Netherlands. +Copyright 2022-2025 Contezza BV, the Netherlands. Licensed under EUPL, Version 1.2 (the "License"); you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/audit/extractor/AuditMessageDataExtractor.java b/platform/src/main/java/nl/contezza/drc/audit/extractor/AuditMessageDataExtractor.java index f29e463..6002133 100644 --- a/platform/src/main/java/nl/contezza/drc/audit/extractor/AuditMessageDataExtractor.java +++ b/platform/src/main/java/nl/contezza/drc/audit/extractor/AuditMessageDataExtractor.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/audit/extractor/ClientIdDataExtractor.java b/platform/src/main/java/nl/contezza/drc/audit/extractor/ClientIdDataExtractor.java index 817946c..ac23d2d 100644 --- a/platform/src/main/java/nl/contezza/drc/audit/extractor/ClientIdDataExtractor.java +++ b/platform/src/main/java/nl/contezza/drc/audit/extractor/ClientIdDataExtractor.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/audit/extractor/ResourceUrlDataExtractor.java b/platform/src/main/java/nl/contezza/drc/audit/extractor/ResourceUrlDataExtractor.java index 419cb01..59156a9 100644 --- a/platform/src/main/java/nl/contezza/drc/audit/extractor/ResourceUrlDataExtractor.java +++ b/platform/src/main/java/nl/contezza/drc/audit/extractor/ResourceUrlDataExtractor.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/audit/extractor/ResourceViewDataExtractor.java b/platform/src/main/java/nl/contezza/drc/audit/extractor/ResourceViewDataExtractor.java index 7b994c2..17f058d 100644 --- a/platform/src/main/java/nl/contezza/drc/audit/extractor/ResourceViewDataExtractor.java +++ b/platform/src/main/java/nl/contezza/drc/audit/extractor/ResourceViewDataExtractor.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/audit/extractor/StatusCodeDataExtractor.java b/platform/src/main/java/nl/contezza/drc/audit/extractor/StatusCodeDataExtractor.java index 3de73a0..d9cdf96 100644 --- a/platform/src/main/java/nl/contezza/drc/audit/extractor/StatusCodeDataExtractor.java +++ b/platform/src/main/java/nl/contezza/drc/audit/extractor/StatusCodeDataExtractor.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/audit/extractor/UserIdDataExtractor.java b/platform/src/main/java/nl/contezza/drc/audit/extractor/UserIdDataExtractor.java index 1e829f6..1d23d82 100644 --- a/platform/src/main/java/nl/contezza/drc/audit/extractor/UserIdDataExtractor.java +++ b/platform/src/main/java/nl/contezza/drc/audit/extractor/UserIdDataExtractor.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/audit/extractor/UserRepresentationDataExtractor.java b/platform/src/main/java/nl/contezza/drc/audit/extractor/UserRepresentationDataExtractor.java index b68d7bd..0da7ba8 100644 --- a/platform/src/main/java/nl/contezza/drc/audit/extractor/UserRepresentationDataExtractor.java +++ b/platform/src/main/java/nl/contezza/drc/audit/extractor/UserRepresentationDataExtractor.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/audit/extractor/UuidDataExtractor.java b/platform/src/main/java/nl/contezza/drc/audit/extractor/UuidDataExtractor.java index 87674fa..ad8b07f 100644 --- a/platform/src/main/java/nl/contezza/drc/audit/extractor/UuidDataExtractor.java +++ b/platform/src/main/java/nl/contezza/drc/audit/extractor/UuidDataExtractor.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/authentication/DRCRemoteUserAuthenticatorFactory.java b/platform/src/main/java/nl/contezza/drc/authentication/DRCRemoteUserAuthenticatorFactory.java index 2474bc5..8aa917e 100644 --- a/platform/src/main/java/nl/contezza/drc/authentication/DRCRemoteUserAuthenticatorFactory.java +++ b/platform/src/main/java/nl/contezza/drc/authentication/DRCRemoteUserAuthenticatorFactory.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/behaviour/IdentifierAndVersioningBehaviour.java b/platform/src/main/java/nl/contezza/drc/behaviour/IdentifierAndVersioningBehaviour.java index b875cf0..ed8a604 100644 --- a/platform/src/main/java/nl/contezza/drc/behaviour/IdentifierAndVersioningBehaviour.java +++ b/platform/src/main/java/nl/contezza/drc/behaviour/IdentifierAndVersioningBehaviour.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/behaviour/NotificatiesBehaviour.java b/platform/src/main/java/nl/contezza/drc/behaviour/NotificatiesBehaviour.java index 5f2ed87..cd0c054 100644 --- a/platform/src/main/java/nl/contezza/drc/behaviour/NotificatiesBehaviour.java +++ b/platform/src/main/java/nl/contezza/drc/behaviour/NotificatiesBehaviour.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/helper/Bestandsdelen.java b/platform/src/main/java/nl/contezza/drc/helper/Bestandsdelen.java index f6cef77..e216100 100644 --- a/platform/src/main/java/nl/contezza/drc/helper/Bestandsdelen.java +++ b/platform/src/main/java/nl/contezza/drc/helper/Bestandsdelen.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/helper/DRCBestandsdelenHelper.java b/platform/src/main/java/nl/contezza/drc/helper/DRCBestandsdelenHelper.java index 3158104..12eedc5 100644 --- a/platform/src/main/java/nl/contezza/drc/helper/DRCBestandsdelenHelper.java +++ b/platform/src/main/java/nl/contezza/drc/helper/DRCBestandsdelenHelper.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/helper/DRCFieldValidationError.java b/platform/src/main/java/nl/contezza/drc/helper/DRCFieldValidationError.java index eacd40f..15ed890 100644 --- a/platform/src/main/java/nl/contezza/drc/helper/DRCFieldValidationError.java +++ b/platform/src/main/java/nl/contezza/drc/helper/DRCFieldValidationError.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/helper/DRCStatusException.java b/platform/src/main/java/nl/contezza/drc/helper/DRCStatusException.java index 279f720..58f41b2 100644 --- a/platform/src/main/java/nl/contezza/drc/helper/DRCStatusException.java +++ b/platform/src/main/java/nl/contezza/drc/helper/DRCStatusException.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/helper/DRCValidationHelper.java b/platform/src/main/java/nl/contezza/drc/helper/DRCValidationHelper.java index 20dac06..2362665 100644 --- a/platform/src/main/java/nl/contezza/drc/helper/DRCValidationHelper.java +++ b/platform/src/main/java/nl/contezza/drc/helper/DRCValidationHelper.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/messaging/BaseMessage.java b/platform/src/main/java/nl/contezza/drc/messaging/BaseMessage.java index 5e5ba49..0624f70 100644 --- a/platform/src/main/java/nl/contezza/drc/messaging/BaseMessage.java +++ b/platform/src/main/java/nl/contezza/drc/messaging/BaseMessage.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageGenerator.java b/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageGenerator.java index 84c9f8e..1a229ea 100644 --- a/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageGenerator.java +++ b/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageGenerator.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageGeneratorImpl.java b/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageGeneratorImpl.java index 539e23c..45f6bba 100644 --- a/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageGeneratorImpl.java +++ b/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageGeneratorImpl.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageListener.java b/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageListener.java index 49d656a..8064fd1 100644 --- a/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageListener.java +++ b/platform/src/main/java/nl/contezza/drc/messaging/DRCMessageListener.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/messaging/NodeMessage.java b/platform/src/main/java/nl/contezza/drc/messaging/NodeMessage.java index 6775e08..ae64ed5 100644 --- a/platform/src/main/java/nl/contezza/drc/messaging/NodeMessage.java +++ b/platform/src/main/java/nl/contezza/drc/messaging/NodeMessage.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java b/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java index d85e95e..acd27ea 100644 --- a/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java +++ b/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/script/DRCAuditServiceScript.java b/platform/src/main/java/nl/contezza/drc/script/DRCAuditServiceScript.java index 9feaf78..02b7a64 100644 --- a/platform/src/main/java/nl/contezza/drc/script/DRCAuditServiceScript.java +++ b/platform/src/main/java/nl/contezza/drc/script/DRCAuditServiceScript.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/script/DRCServiceScript.java b/platform/src/main/java/nl/contezza/drc/script/DRCServiceScript.java index e6e6d6b..0572e8d 100644 --- a/platform/src/main/java/nl/contezza/drc/script/DRCServiceScript.java +++ b/platform/src/main/java/nl/contezza/drc/script/DRCServiceScript.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/service/AuthLevel.java b/platform/src/main/java/nl/contezza/drc/service/AuthLevel.java index e53afa4..fe256a0 100644 --- a/platform/src/main/java/nl/contezza/drc/service/AuthLevel.java +++ b/platform/src/main/java/nl/contezza/drc/service/AuthLevel.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCAuditService.java b/platform/src/main/java/nl/contezza/drc/service/DRCAuditService.java index 0585f1f..ee9ca70 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCAuditService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCAuditService.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCAutorisatiesService.java b/platform/src/main/java/nl/contezza/drc/service/DRCAutorisatiesService.java index 56fcea2..3fc75be 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCAutorisatiesService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCAutorisatiesService.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCBesluitenService.java b/platform/src/main/java/nl/contezza/drc/service/DRCBesluitenService.java index d19d35f..8875a81 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCBesluitenService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCBesluitenService.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCCatalogiService.java b/platform/src/main/java/nl/contezza/drc/service/DRCCatalogiService.java index b646910..917eb77 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCCatalogiService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCCatalogiService.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCNotificatiesService.java b/platform/src/main/java/nl/contezza/drc/service/DRCNotificatiesService.java index 9ebcee0..b4df73d 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCNotificatiesService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCNotificatiesService.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCService.java b/platform/src/main/java/nl/contezza/drc/service/DRCService.java index 69a348d..58489c0 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCService.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCZakenService.java b/platform/src/main/java/nl/contezza/drc/service/DRCZakenService.java index f4c4599..1b02884 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCZakenService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCZakenService.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/util/CustomAuditQueryParameters.java b/platform/src/main/java/nl/contezza/drc/util/CustomAuditQueryParameters.java index 75b1763..a16ee1c 100644 --- a/platform/src/main/java/nl/contezza/drc/util/CustomAuditQueryParameters.java +++ b/platform/src/main/java/nl/contezza/drc/util/CustomAuditQueryParameters.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/util/DateUtil.java b/platform/src/main/java/nl/contezza/drc/util/DateUtil.java index 956168b..52b161d 100644 --- a/platform/src/main/java/nl/contezza/drc/util/DateUtil.java +++ b/platform/src/main/java/nl/contezza/drc/util/DateUtil.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/util/ETag.java b/platform/src/main/java/nl/contezza/drc/util/ETag.java index 28909dd..cd891b9 100644 --- a/platform/src/main/java/nl/contezza/drc/util/ETag.java +++ b/platform/src/main/java/nl/contezza/drc/util/ETag.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/util/ElfProef.java b/platform/src/main/java/nl/contezza/drc/util/ElfProef.java index 8e6922b..f198ed9 100644 --- a/platform/src/main/java/nl/contezza/drc/util/ElfProef.java +++ b/platform/src/main/java/nl/contezza/drc/util/ElfProef.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java index ca29fa5..fa8a07d 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/V1Get.java b/platform/src/main/java/nl/contezza/drc/webscript/V1Get.java index 7c006a2..ffab8db 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/V1Get.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/V1Get.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/V1SchemaGet.java b/platform/src/main/java/nl/contezza/drc/webscript/V1SchemaGet.java index ad5b086..be8785f 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/V1SchemaGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/V1SchemaGet.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/bestandsdelen/BestandsdelenPut.java b/platform/src/main/java/nl/contezza/drc/webscript/bestandsdelen/BestandsdelenPut.java index 8dd1b8f..e3772c5 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/bestandsdelen/BestandsdelenPut.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/bestandsdelen/BestandsdelenPut.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java index 3a5dee7..265e2cf 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectVersionHistoryNode.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectVersionHistoryNode.java index df9d3dc..d01f55f 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectVersionHistoryNode.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectVersionHistoryNode.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenDelete.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenDelete.java index 619f695..b60291f 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenDelete.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenDelete.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenDownloadGet.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenDownloadGet.java index 3b3241a..ea3c7ca 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenDownloadGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenDownloadGet.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java index 29f36ef..0845442 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenHead.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenHead.java index 41fd35a..e4938ff 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenHead.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenHead.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPatch.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPatch.java index d156708..145299f 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPatch.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPatch.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java index 909d88c..a38e47b 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java index 6cc9a9c..76d3fa3 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenDelete.java b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenDelete.java index 81622d8..b494df2 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenDelete.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenDelete.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java index b4bbacc..31eadc0 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenHead.java b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenHead.java index 28e103a..081eba7 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenHead.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenHead.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPatch.java b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPatch.java index 8990b97..b826573 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPatch.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPatch.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPost.java b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPost.java index 55c1f22..0ae170f 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPost.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPost.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPut.java b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPut.java index 6709a4b..37805a7 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPut.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenPut.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenDelete.java b/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenDelete.java index fbb1625..995da1e 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenDelete.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenDelete.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenGet.java index d833a0b..1d7d550 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenGet.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenHead.java b/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenHead.java index c8f43fb..0075c14 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenHead.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenHead.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenPost.java b/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenPost.java index 1d92603..8cffc0f 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenPost.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/objectinformatieobjecten/ObjectinformatieobjectenPost.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. -- GitLab From e096e7c6708195fd0888e62973311122d8fe87fc Mon Sep 17 00:00:00 2001 From: Rick de Rooij <rick.de.rooij@contezza.nl> Date: Wed, 12 Feb 2025 13:09:50 +0100 Subject: [PATCH 02/22] :pencil: update release notes --- docs/src/docs/asciidoc/includes/_release_notes.adoc | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/src/docs/asciidoc/includes/_release_notes.adoc b/docs/src/docs/asciidoc/includes/_release_notes.adoc index 46ddc1f..1c34382 100644 --- a/docs/src/docs/asciidoc/includes/_release_notes.adoc +++ b/docs/src/docs/asciidoc/includes/_release_notes.adoc @@ -7,6 +7,14 @@ Overzicht van de release notities. |=== |Datum |Versie |Omschrijving +|2025-02-12 +|2.0.0 +|Ondersteuning voor Alfresco 23.x. + +|2025-02-12 +|1.3.0 +|Multiple bestandsdelen support DRC 1.1 (https://support.contezza.nl/issues/30747[#30747]). + |2024-03-19 |1.2.7 |Mogelijkheid voor om DRC API achter proxy te plaatsen met eigenschap `drc.url.overwrite` (https://support.contezza.nl/issues/27511[#27511]). -- GitLab From 3d0017773a964e7dd27e4bcb7925324d6370520b Mon Sep 17 00:00:00 2001 From: Rick de Rooij <rick.de.rooij@contezza.nl> Date: Wed, 12 Feb 2025 13:11:31 +0100 Subject: [PATCH 03/22] :bug: fix purge volumes --- purge.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/purge.sh b/purge.sh index 2a23fc5..2c2caeb 100755 --- a/purge.sh +++ b/purge.sh @@ -1,7 +1,7 @@ docker stop $(docker ps -a -q) && docker rm $(docker ps -a -q) || true && - docker volume rm api-tests_vol_alfdrc_db -f && - docker volume rm api-tests_vol_drc_media -f && - docker volume rm api-tests_vol_drc_private_media -f && - docker volume rm vol_tezza-drc-platform_alf_data -f && - docker volume rm vol_tezza-drc-platform_postgres -f && - docker volume rm vol_tezza-drc-platform_solr_data -f + docker volume rm docker_vol_drc_db -f && + docker volume rm docker_vol_drc_media -f && + docker volume rm docker_vol_drc_private_media -f && + docker volume rm vol_alfresco-documenten-api-platform_alf_data -f && + docker volume rm vol_alfresco-documenten-api-platform_postgres -f && + docker volume rm vol_alfresco-documenten-api-platform_solr_data -f -- GitLab From 98f2cd81ebc437c7176fca8d8a31f82d8321f0e0 Mon Sep 17 00:00:00 2001 From: Rick de Rooij <rick.de.rooij@contezza.nl> Date: Wed, 12 Feb 2025 13:11:52 +0100 Subject: [PATCH 04/22] :green_heart: update jdk build image --- .gitlab-ci.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 8141c2e..44eb071 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,7 +12,7 @@ variables: maven_deploy_snapshot: stage: deploy - image: harbor.contezza.nl/tooling/docker-npm-maven:1.0.1 + image: harbor.contezza.nl/tooling/cicd-image:node18-openjdk17 script: - mvn deploy -DskipTests=true $MAVEN_CLI_OPTS only: @@ -23,8 +23,10 @@ maven_deploy_snapshot: maven_deploy_release: stage: deploy - image: harbor.contezza.nl/tooling/docker-npm-maven:1.0.1 + image: harbor.contezza.nl/tooling/cicd-image:node18-openjdk17 script: + - git config --global user.email "beheer@contezza.nl" + - git config --global user.name "Contezza" - git checkout -B $CI_BUILD_REF_NAME - mvn release:prepare release:perform release:clean -Darguments="-DskipTests=true" $MAVEN_CLI_OPTS only: -- GitLab From a10e84054bfedd5815d48acdaa3bb84b9b67cbaf Mon Sep 17 00:00:00 2001 From: Rick de Rooij <rick.de.rooij@contezza.nl> Date: Wed, 12 Feb 2025 14:20:58 +0100 Subject: [PATCH 05/22] :bug: fix scm urls --- pom.xml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pom.xml b/pom.xml index b0f2906..8e9d42b 100644 --- a/pom.xml +++ b/pom.xml @@ -95,10 +95,9 @@ </distributionManagement> <scm> - <connection>scm:git:https://git.contezza.nl/develop/products/${project.artifactId}.git</connection> - <url>https://git.contezza.nl/develop/products/${project.artifactId}.git</url> - <developerConnection>scm:git:https://git.contezza.nl/develop/products/${project.artifactId}.git</developerConnection> - <tag>HEAD</tag> + <connection>scm:git:https://git.contezza.nl/community/${project.artifactId}.git</connection> + <url>https://git.contezza.nl/community/${project.artifactId}.git</url> + <developerConnection>scm:git:https://git.contezza.nl/community/${project.artifactId}.git</developerConnection> </scm> <build> -- GitLab From 179ea8cb6da86232be88bd0c496bde43e3c13381 Mon Sep 17 00:00:00 2001 From: Rick de Rooij <rick.de.rooij@contezza.nl> Date: Wed, 12 Feb 2025 16:03:23 +0100 Subject: [PATCH 06/22] :rocket: create-release --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 44eb071..282abd5 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -27,7 +27,7 @@ maven_deploy_release: script: - git config --global user.email "beheer@contezza.nl" - git config --global user.name "Contezza" - - git checkout -B $CI_BUILD_REF_NAME + - git checkout -B $CI_COMMIT_REF_NAME - mvn release:prepare release:perform release:clean -Darguments="-DskipTests=true" $MAVEN_CLI_OPTS only: variables: -- GitLab From eacc86b3013e4ad559f57a81d1b284d2bbdfeabd Mon Sep 17 00:00:00 2001 From: Rick de Rooij <rick.de.rooij@contezza.nl> Date: Wed, 12 Feb 2025 16:05:08 +0100 Subject: [PATCH 07/22] :rocket: create-release, remove snapshot --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 8e9d42b..4a90641 100644 --- a/pom.xml +++ b/pom.xml @@ -50,7 +50,7 @@ <alfresco.rm.share.version>23.2.0.72</alfresco.rm.share.version> <!-- Contezza Modules --> - <contezza.contezza-jwt.version>2.0.0-SNAPSHOT</contezza.contezza-jwt.version> + <contezza.contezza-jwt.version>2.0.0</contezza.contezza-jwt.version> <!-- Open Zaak / VNG Realisatie --> <vngr.client-api.version>1.0.0</vngr.client-api.version> -- GitLab From a70f52c9496171563a4c3a43318a1ec09b2c0331 Mon Sep 17 00:00:00 2001 From: Contezza <beheer@contezza.nl> Date: Wed, 12 Feb 2025 16:06:54 +0100 Subject: [PATCH 08/22] [maven-release-plugin] prepare release alfresco-documenten-api-2.0.0 --- docs/pom.xml | 2 +- integration-tests/pom.xml | 2 +- platform/pom.xml | 2 +- pom.xml | 5 +++-- share/pom.xml | 2 +- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/docs/pom.xml b/docs/pom.xml index a0653ef..b061bc8 100644 --- a/docs/pom.xml +++ b/docs/pom.xml @@ -4,7 +4,7 @@ <parent> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0-SNAPSHOT</version> + <version>2.0.0</version> <relativePath>../pom.xml</relativePath> </parent> diff --git a/integration-tests/pom.xml b/integration-tests/pom.xml index adbd267..cd246cb 100644 --- a/integration-tests/pom.xml +++ b/integration-tests/pom.xml @@ -4,7 +4,7 @@ <parent> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0-SNAPSHOT</version> + <version>2.0.0</version> <relativePath>../pom.xml</relativePath> </parent> diff --git a/platform/pom.xml b/platform/pom.xml index 34c3a1f..bf7fe0d 100644 --- a/platform/pom.xml +++ b/platform/pom.xml @@ -5,7 +5,7 @@ <parent> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0-SNAPSHOT</version> + <version>2.0.0</version> <relativePath>../pom.xml</relativePath> </parent> diff --git a/pom.xml b/pom.xml index 4a90641..5625f99 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ <modelVersion>4.0.0</modelVersion> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0-SNAPSHOT</version> + <version>2.0.0</version> <name>Alfresco Documenten API</name> <packaging>pom</packaging> @@ -98,7 +98,8 @@ <connection>scm:git:https://git.contezza.nl/community/${project.artifactId}.git</connection> <url>https://git.contezza.nl/community/${project.artifactId}.git</url> <developerConnection>scm:git:https://git.contezza.nl/community/${project.artifactId}.git</developerConnection> - </scm> + <tag>alfresco-documenten-api-2.0.0</tag> + </scm> <build> <pluginManagement> diff --git a/share/pom.xml b/share/pom.xml index aed34f5..d1e7ff3 100644 --- a/share/pom.xml +++ b/share/pom.xml @@ -4,7 +4,7 @@ <parent> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0-SNAPSHOT</version> + <version>2.0.0</version> <relativePath>../pom.xml</relativePath> </parent> -- GitLab From 992766d0205f6ccf6fe13ca483d3f1092e9efaa2 Mon Sep 17 00:00:00 2001 From: Contezza <beheer@contezza.nl> Date: Wed, 12 Feb 2025 16:06:55 +0100 Subject: [PATCH 09/22] [maven-release-plugin] prepare for next development iteration --- docs/pom.xml | 2 +- integration-tests/pom.xml | 2 +- platform/pom.xml | 2 +- pom.xml | 4 ++-- share/pom.xml | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/pom.xml b/docs/pom.xml index b061bc8..6926553 100644 --- a/docs/pom.xml +++ b/docs/pom.xml @@ -4,7 +4,7 @@ <parent> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0</version> + <version>2.0.1-SNAPSHOT</version> <relativePath>../pom.xml</relativePath> </parent> diff --git a/integration-tests/pom.xml b/integration-tests/pom.xml index cd246cb..06bfb4d 100644 --- a/integration-tests/pom.xml +++ b/integration-tests/pom.xml @@ -4,7 +4,7 @@ <parent> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0</version> + <version>2.0.1-SNAPSHOT</version> <relativePath>../pom.xml</relativePath> </parent> diff --git a/platform/pom.xml b/platform/pom.xml index bf7fe0d..69f224c 100644 --- a/platform/pom.xml +++ b/platform/pom.xml @@ -5,7 +5,7 @@ <parent> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0</version> + <version>2.0.1-SNAPSHOT</version> <relativePath>../pom.xml</relativePath> </parent> diff --git a/pom.xml b/pom.xml index 5625f99..6a66034 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ <modelVersion>4.0.0</modelVersion> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0</version> + <version>2.0.1-SNAPSHOT</version> <name>Alfresco Documenten API</name> <packaging>pom</packaging> @@ -98,7 +98,7 @@ <connection>scm:git:https://git.contezza.nl/community/${project.artifactId}.git</connection> <url>https://git.contezza.nl/community/${project.artifactId}.git</url> <developerConnection>scm:git:https://git.contezza.nl/community/${project.artifactId}.git</developerConnection> - <tag>alfresco-documenten-api-2.0.0</tag> + <tag>HEAD</tag> </scm> <build> diff --git a/share/pom.xml b/share/pom.xml index d1e7ff3..01a20bb 100644 --- a/share/pom.xml +++ b/share/pom.xml @@ -4,7 +4,7 @@ <parent> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> - <version>2.0.0</version> + <version>2.0.1-SNAPSHOT</version> <relativePath>../pom.xml</relativePath> </parent> -- GitLab From 8d5400084d1f0cfbf09266220a6312c9ab25d98b Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Tue, 25 Feb 2025 10:09:09 -0600 Subject: [PATCH 10/22] Update Copyright date --- .../contezza/drc/webscript/verzendingen/VerzendingenDelete.java | 2 +- .../nl/contezza/drc/webscript/verzendingen/VerzendingenGet.java | 2 +- .../contezza/drc/webscript/verzendingen/VerzendingenHead.java | 2 +- .../contezza/drc/webscript/verzendingen/VerzendingenPatch.java | 2 +- .../contezza/drc/webscript/verzendingen/VerzendingenPost.java | 2 +- .../nl/contezza/drc/webscript/verzendingen/VerzendingenPut.java | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenDelete.java b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenDelete.java index 29be576..e0d2586 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenDelete.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenDelete.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenGet.java index d412c95..ee8a250 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenGet.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenHead.java b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenHead.java index e98a20e..b85fcd6 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenHead.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenHead.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPatch.java b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPatch.java index 67ce964..d079aa9 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPatch.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPatch.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPost.java b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPost.java index 43f650f..37f196b 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPost.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPost.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. diff --git a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPut.java b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPut.java index de9771c..371ec72 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPut.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/verzendingen/VerzendingenPut.java @@ -1,5 +1,5 @@ /* - * Copyright 2022-2024 Contezza BV, the Netherlands. + * Copyright 2022-2025 Contezza BV, the Netherlands. * * Licensed under EUPL, Version 1.2 (the "License"); * you may not use this file except in compliance with the License. -- GitLab From 0e9d254174c58120acd7e554323a133b7ba87152 Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Thu, 27 Feb 2025 13:48:20 -0600 Subject: [PATCH 11/22] Update license --- pom.xml | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/pom.xml b/pom.xml index 6a66034..b06eaa1 100644 --- a/pom.xml +++ b/pom.xml @@ -1,5 +1,7 @@ <?xml version="1.0" encoding="UTF-8"?> -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> +<project xmlns="http://maven.apache.org/POM/4.0.0" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>nl.contezza.tezza</groupId> <artifactId>alfresco-documenten-api</artifactId> @@ -21,7 +23,7 @@ <alfresco.bomDependencyArtifactId>acs-packaging</alfresco.bomDependencyArtifactId> <!-- License --> - <contezza.license.version>23.1-2025-02</contezza.license.version> + <contezza.license.version>23.2-2026-02</contezza.license.version> <!-- Alfresco Content Services Versions --> <alfresco.platform.version>23.2.1</alfresco.platform.version> @@ -41,8 +43,10 @@ <docker.share.image>${image.registry}/base/alfresco-enterprise-share/23</docker.share.image> <docker.ass.image>${image.registry}/base/alfresco-search-services</docker.ass.image> <docker.activemq.image>${image.registry}/docker.io/alfresco/alfresco-activemq</docker.activemq.image> - <docker.transform-core-aio.image>${image.registry}/docker.io/alfresco/alfresco-transform-core-aio</docker.transform-core-aio.image> - <docker.shared-file-store.image>${image.registry}/quay.io/alfresco/alfresco-shared-file-store</docker.shared-file-store.image> + <docker.transform-core-aio.image> + ${image.registry}/docker.io/alfresco/alfresco-transform-core-aio</docker.transform-core-aio.image> + <docker.shared-file-store.image> + ${image.registry}/quay.io/alfresco/alfresco-shared-file-store</docker.shared-file-store.image> <docker.transform-router.image>${image.registry}/quay.io/alfresco/alfresco-transform-router</docker.transform-router.image> <!-- Alfresco Modules --> @@ -63,7 +67,8 @@ <acs.port>8080</acs.port> <acs.debug.port>8888</acs.debug.port> - <!-- This parameter is only required for those cases in which ACS is not exposed in http://localhost:8080/alfresco (i.e. Windows Docker) --> + <!-- This parameter is only required for those cases in which ACS is not exposed in + http://localhost:8080/alfresco (i.e. Windows Docker) --> <test.acs.endpoint.path /> <!-- JRebel Hot reloading of classpath stuff and web resource stuff --> @@ -98,8 +103,8 @@ <connection>scm:git:https://git.contezza.nl/community/${project.artifactId}.git</connection> <url>https://git.contezza.nl/community/${project.artifactId}.git</url> <developerConnection>scm:git:https://git.contezza.nl/community/${project.artifactId}.git</developerConnection> - <tag>HEAD</tag> - </scm> + <tag>HEAD</tag> + </scm> <build> <pluginManagement> @@ -182,7 +187,8 @@ <external> <type>compose</type> <basedir>${project.basedir}/src/main/docker</basedir> - <composeFile>${project.basedir}/target/classes/docker/docker-compose.yml</composeFile> + <composeFile> + ${project.basedir}/target/classes/docker/docker-compose.yml</composeFile> </external> </image> </images> -- GitLab From cc4e2b4dff8277915e2ddd6debf98d80f074cf5b Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Thu, 27 Feb 2025 14:50:18 -0600 Subject: [PATCH 12/22] Toevoegen property "trefworden" aan eio, inclusief tests --- .../drc/dataprovider/DRCDataProvider.java | 2 +- .../EnkelvoudigInformatieObjectTest.java | 27 ++++--- ...CustomEnkelvoudigInformatieObjectTest.java | 81 ++++++++++++++++++- .../java/nl/contezza/drc/model/RGBZModel.java | 1 + .../AbstractDrcDeclarativeWebScript.java | 35 ++++++++ .../messages/rgbz-model.properties | 1 + .../messages/rgbz-model_nl.properties | 1 + .../model/rgbz-model.xml | 4 + ...enkelvoudiginformatieobjecten.get.json.ftl | 5 ++ ...kelvoudiginformatieobjecten.patch.json.ftl | 5 ++ ...nkelvoudiginformatieobjecten.post.json.ftl | 5 ++ ...enkelvoudiginformatieobjecten.put.json.ftl | 5 ++ 12 files changed, 156 insertions(+), 16 deletions(-) diff --git a/integration-tests/src/main/java/nl/contezza/drc/dataprovider/DRCDataProvider.java b/integration-tests/src/main/java/nl/contezza/drc/dataprovider/DRCDataProvider.java index c9270a3..81ef3ba 100644 --- a/integration-tests/src/main/java/nl/contezza/drc/dataprovider/DRCDataProvider.java +++ b/integration-tests/src/main/java/nl/contezza/drc/dataprovider/DRCDataProvider.java @@ -54,7 +54,7 @@ public class DRCDataProvider { json.put("beschrijving", "test_beschrijving"); json.put("informatieobjecttype", iot); json.put("vertrouwelijkheidaanduiding", "openbaar"); - json.put("verschijningsvorm", "Een verschijningsvorm"); + json.put("verschijningsvorm", "Vorm A"); return json.toString(); } diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectTest.java index 882dff0..b11d3ad 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectTest.java @@ -65,7 +65,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L44">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_create() { EIOService eioService = new EIOService(); @@ -102,8 +102,11 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { Assert.assertNull(json.getString("indicatieGebruiksrecht")); Assert.assertEquals(json.getString("status"), ""); Assert.assertFalse(json.getBoolean("locked")); + Assert.assertEquals(json.getString("verschijningsvorm"), "Vorm A"); + Assert.assertNull(json.get("trefwoorden")); eioTestObject = json; + } /** @@ -111,7 +114,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L123">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_read() { EIOService eioService = new EIOService(); @@ -156,7 +159,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L177">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_eio_download_with_accept_application_octet_stream_header() { EIOService eioService = new EIOService(); @@ -172,7 +175,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/stable/1.0.x/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L189">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_download_non_existing_eio() { EIOService eioService = new EIOService(); @@ -192,7 +195,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L204">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_bestandsomvang() { EIOService eioService = new EIOService(); @@ -210,7 +213,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L227">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_integrity_empty() { EIOService eioService = new EIOService(); @@ -230,7 +233,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L258">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_integrity_provided() { EIOService eioService = new EIOService(); @@ -255,7 +258,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L295">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_filter_by_identification() { EIOService eioService = new EIOService(); @@ -279,7 +282,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L307">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_destroy_no_relations_allowed() { EIOService eioService = new EIOService(); @@ -294,7 +297,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/stable/1.0.x/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L318">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_destroy_with_relations_not_allowed() { EIOService eioService = new EIOService(); @@ -320,7 +323,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/28c082e806843def864f6be1184fbae295a1c7f2/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L332">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_validate_unknown_query_params() { EIOService eioService = new EIOService(); @@ -337,7 +340,7 @@ public class EnkelvoudigInformatieObjectTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/stable/1.0.x/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L346">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObject") + @Test(groups = "EnkelvoudigInformatieObject", enabled = true) public void test_invalid_inhoud() { EIOService eioService = new EIOService(); diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java index 563ad49..90cd2e0 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java @@ -2,6 +2,7 @@ package nl.contezza.drc.tests.custom; import java.util.Base64; +import org.json.JSONArray; import org.json.JSONObject; import org.testng.Assert; import org.testng.annotations.BeforeTest; @@ -9,6 +10,7 @@ import org.testng.annotations.Test; import io.restassured.path.json.JsonPath; import io.restassured.response.Response; +import nl.contezza.drc.dataprovider.DRCDataProvider; import nl.contezza.drc.rest.RestTest; import nl.contezza.drc.service.EIOService; import nl.contezza.drc.service.ZTCService; @@ -18,7 +20,7 @@ public class CustomEnkelvoudigInformatieObjectTest extends RestTest { /** * Create necessary dependencies when creating enkelvoudiginformatieobject. */ - @BeforeTest(groups = "CustomUpload") + @BeforeTest(groups = "CustomEnkelvoudigInformatieObjectTest") public void init() { // Create random catalogi ZTCService ztcService = new ZTCService(); @@ -46,7 +48,7 @@ public class CustomEnkelvoudigInformatieObjectTest extends RestTest { JSONObject createdEio = new JSONObject(json.prettify()); Assert.assertEquals(res.getStatusCode(), 201); - Assert.assertEquals(json.getString("verschijningsvorm"), "Een verschijningsvorm"); + Assert.assertEquals(json.getString("verschijningsvorm"), "Vorm A"); String eioUrl = json.getString("url"); @@ -54,7 +56,7 @@ public class CustomEnkelvoudigInformatieObjectTest extends RestTest { res = eioService.getEIO(eioUrl, null); json = new JsonPath(res.asString()); - Assert.assertEquals(json.getString("verschijningsvorm"), "Een verschijningsvorm"); + Assert.assertEquals(json.getString("verschijningsvorm"), "Vorm A"); res = eioService.lock(eioUrl); @@ -91,4 +93,77 @@ public class CustomEnkelvoudigInformatieObjectTest extends RestTest { Assert.assertEquals(res.getStatusCode(), 200); Assert.assertEquals(json.getString("verschijningsvorm"), "Een update verschijningsvorm"); } + + @Test(groups = "CustomEnkelvoudigInformatieObjectTest", enabled = true) + public void test_trefwoorden() { + EIOService eioService = new EIOService(); + + // Validate verschijningsvorm at POST + JSONObject bodyCreate = new JSONObject(DRCDataProvider.testCreate(informatieobjecttypeUrl)); + JSONArray trefwoorden = new JSONArray(); + trefwoorden.put("trefwoord1"); + trefwoorden.put("trefwoord2"); + bodyCreate.put("trefwoorden", trefwoorden); + Response res = eioService.testCreate(bodyCreate); + JsonPath json = new JsonPath(res.asString()); + + JSONObject createdEio = new JSONObject(json.prettify()); + + Assert.assertEquals(res.getStatusCode(), 201); + Assert.assertEquals(json.getString("trefwoorden[0]"), "trefwoord1"); + Assert.assertEquals(json.getString("trefwoorden[1]"), "trefwoord2"); + + String eioUrl = json.getString("url"); + + // Validate verschijningsvorm at GET + res = eioService.getEIO(eioUrl, null); + json = new JsonPath(res.asString()); + + Assert.assertEquals(json.getString("verschijningsvorm"), "Vorm A"); + Assert.assertEquals(json.getString("trefwoorden[0]"), "trefwoord1"); + Assert.assertEquals(json.getString("trefwoorden[1]"), "trefwoord2"); + + res = eioService.lock(eioUrl); + + Assert.assertEquals(res.getStatusCode(), 200); + + String lock = res.body().path("lock"); + + // Validate verschijningsvorm at PATCH + JSONObject body = new JSONObject(); + JSONArray trefwoordenPatch = new JSONArray(); + trefwoordenPatch.put("trefwoord3"); + trefwoordenPatch.put("trefwoord4"); + body.put("trefwoorden", trefwoordenPatch); + body.put("lock", lock); + + res = eioService.partialUpdate(eioUrl, body); + json = new JsonPath(res.asString()); + + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals(json.getString("trefwoorden[0]"), "trefwoord3"); + Assert.assertEquals(json.getString("trefwoorden[1]"), "trefwoord4"); + + // Validate verschijningsvorm at PUT + body = new JSONObject(); + JSONArray trefwoordenPut = new JSONArray(); + trefwoordenPut.put("trefwoord5"); + trefwoordenPut.put("trefwoord6"); + body.put("trefwoorden", trefwoordenPut); + body.put("beschrijving", "beschrijving2"); + body.put("inhoud", Base64.getEncoder().encodeToString("some file content".getBytes())); + body.put("bestandsomvang", "some file content".getBytes().length); + body.put("lock", lock); + + JSONObject mergedJson = mergeJSONObjects(createdEio, body); + mergedJson.remove("ondertekening"); + mergedJson.remove("integriteit"); + + // Update EIO + res = eioService.update(eioUrl, mergedJson); + json = new JsonPath(res.asString()); + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals(json.getString("trefwoorden[0]"), "trefwoord5"); + Assert.assertEquals(json.getString("trefwoorden[1]"), "trefwoord6"); + } } diff --git a/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java b/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java index 61faee7..fad5ede 100644 --- a/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java +++ b/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java @@ -68,6 +68,7 @@ public interface RGBZModel { QName PROP_EINDDATUM = QName.createQName(URI, "einddatum"); QName PROP_OMSCHRIJVING_VOORWAARDEN = QName.createQName(URI, "omschrijvingVoorwaarden"); QName PROP_VERSCHIJNINGSVORM = QName.createQName(URI, "verschijningsvorm"); + QName PROP_TREFWOORDEN = QName.createQName(URI, "trefwoorden"); QName PROP_AUDIT_TOELICHTING = QName.createQName(URI, "auditToelichting"); QName PROP_AUDIT_USER_ID = QName.createQName(URI, "auditUserId"); QName PROP_AUDIT_USER_REPRESENTATION = QName.createQName(URI, "auditUserRepresentation"); diff --git a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java index cb53c88..6ac1ad1 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java @@ -23,6 +23,8 @@ import java.util.Date; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.stream.Collectors; +import java.util.stream.IntStream; import org.alfresco.model.ContentModel; import org.alfresco.repo.model.Repository; @@ -42,6 +44,7 @@ import org.apache.commons.logging.LogFactory; import org.apache.http.NameValuePair; import org.apache.http.client.utils.URLEncodedUtils; import org.apache.http.message.BasicNameValuePair; +import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import org.springframework.beans.factory.annotation.Autowired; @@ -495,6 +498,11 @@ public abstract class AbstractDrcDeclarativeWebScript extends DeclarativeWebScri : getJsonString(jsonRequest, RGBZModel.PROP_VERSCHIJNINGSVORM.getLocalName())); } + if (getJsonStringArray(jsonRequest, RGBZModel.PROP_TREFWOORDEN.getLocalName()) != null) { + props.put(RGBZModel.PROP_TREFWOORDEN, (ArrayList<String>) getJsonStringArray(jsonRequest, + RGBZModel.PROP_TREFWOORDEN.getLocalName())); + } + Long bestandsomvang = getJsonLong(jsonRequest, "bestandsomvang"); if (bestandsomvang != null || jsonRequest.has("bestandsomvang")) { props.put(RGBZModel.PROP_BESTANDSOMVANG, bestandsomvang); @@ -918,6 +926,33 @@ public abstract class AbstractDrcDeclarativeWebScript extends DeclarativeWebScri return null; } + /** + * Get string value from json. + * + * @param jsonRequest JSONObject json + * @param value String key + * @return String the value + */ + protected List<String> getJsonStringArray(JSONObject jsonRequest, String value) { + if (jsonRequest.has(value)) { + try { + JSONArray jsonArray = jsonRequest.getJSONArray(value); + List<String> list = IntStream.range(0, jsonArray.length()) + .mapToObj(jsonArray::getString) // Ensures type safety + .collect(Collectors.toList()); + + if (list.isEmpty()) { + return null; + } + + return list; + } catch (JSONException e) { + LOGGER.error(e); + } + } + return null; + } + /** * Get the node refrence * diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model.properties b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model.properties index 0506daa..94007e6 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model.properties +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model.properties @@ -35,6 +35,7 @@ rgbz_model.property.rgbz_integriteitWaarde.title=Waarde (integriteit) rgbz_model.property.rgbz_integriteitDatum.title=Datum (integriteit) rgbz_model.property.rgbz_informatieobjecttype.title=Informatieobjecttype rgbz_model.property.rgbz_verschijningsvorm.title=Verschijningsvorm +rgbz_model.property.rgbz_trefwoorden.title=Trefwoorden #Constraints listconstraint.rgbz_vertrouwelijkheidaanduidingConstraint.openbaar=Openbaar diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model_nl.properties b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model_nl.properties index 0506daa..94007e6 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model_nl.properties +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model_nl.properties @@ -35,6 +35,7 @@ rgbz_model.property.rgbz_integriteitWaarde.title=Waarde (integriteit) rgbz_model.property.rgbz_integriteitDatum.title=Datum (integriteit) rgbz_model.property.rgbz_informatieobjecttype.title=Informatieobjecttype rgbz_model.property.rgbz_verschijningsvorm.title=Verschijningsvorm +rgbz_model.property.rgbz_trefwoorden.title=Trefwoorden #Constraints listconstraint.rgbz_vertrouwelijkheidaanduidingConstraint.openbaar=Openbaar diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/model/rgbz-model.xml b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/model/rgbz-model.xml index 2b65bc3..902a323 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/model/rgbz-model.xml +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/model/rgbz-model.xml @@ -398,6 +398,10 @@ <property name="rgbz:verschijningsvorm"> <type>d:text</type> </property> + <property name="rgbz:trefwoorden"> + <type>d:text</type> + <multiple>true</multiple> + </property> <!-- Wordt gebruikt ter ondersteuning van bestandsdelen --> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.get.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.get.json.ftl index d959f1f..1225785 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.get.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.get.json.ftl @@ -36,6 +36,11 @@ "bestandsdelen" : [<#list item.bestandsdelen as part><@renderFileParts part /><#if part_has_next>,</#if></#list>], "indicatieGebruiksrecht" : <#if item.properties["rgbz:indicatieGebruiksrecht"]??>${item.properties["rgbz:indicatieGebruiksrecht"]?c}<#else>null</#if>, "verschijningsvorm" : "${item.properties["rgbz:verschijningsvorm"]!""}", + "trefwoorden" : <#if item.properties["rgbz:trefwoorden"]?? && item.properties["rgbz:trefwoorden"]?size gt 0> + [ <#list item.properties["rgbz:trefwoorden"] as trefwoord>"${trefwoord}"<#if trefwoord_has_next>, </#if></#list>] + <#else> + null + </#if>, "ondertekening": { "soort": "${item.properties["rgbz:ondertekeningSoort"]!""}", "datum": <#if item.properties["rgbz:ondertekeningDatum"]??>"<@dateFormat item.properties["rgbz:ondertekeningDatum"] />"<#else>null</#if> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.patch.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.patch.json.ftl index 5cb312c..7821086 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.patch.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.patch.json.ftl @@ -35,6 +35,11 @@ "bestandsdelen" : [<#list bestandsdelen as part><@renderFileParts part /><#if part_has_next>,</#if></#list>], "indicatieGebruiksrecht" : <#if item.properties["rgbz:indicatieGebruiksrecht"]??>${item.properties["rgbz:indicatieGebruiksrecht"]?c}<#else>null</#if>, "verschijningsvorm" : "${item.properties["rgbz:verschijningsvorm"]!""}", + "trefwoorden" : <#if item.properties["rgbz:trefwoorden"]?? && item.properties["rgbz:trefwoorden"]?size gt 0> + [ <#list item.properties["rgbz:trefwoorden"] as trefwoord>"${trefwoord}"<#if trefwoord_has_next>, </#if></#list>] + <#else> + null + </#if>, "ondertekening": <#if item.properties["rgbz:ondertekeningDatum"]??>{ "soort": "${item.properties["rgbz:ondertekeningSoort"]!""}", "datum": "<@dateFormat item.properties["rgbz:ondertekeningDatum"] />" diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl index acba979..eb23404 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl @@ -36,6 +36,11 @@ "bestandsdelen" : [<#list item.bestandsdelen as part><@renderFileParts part /><#if part_has_next>,</#if></#list>], "indicatieGebruiksrecht" : <#if item.properties["rgbz:indicatieGebruiksrecht"]??>${item.properties["rgbz:indicatieGebruiksrecht"]?c}<#else>null</#if>, "verschijningsvorm" : "${item.properties["rgbz:verschijningsvorm"]!""}", + "trefwoorden" : <#if item.properties["rgbz:trefwoorden"]?? && item.properties["rgbz:trefwoorden"]?size gt 0> + [ <#list item.properties["rgbz:trefwoorden"] as trefwoord>"${trefwoord}"<#if trefwoord_has_next>, </#if></#list>] + <#else> + null + </#if>, "ondertekening": { "soort": "${item.properties["rgbz:ondertekeningSoort"]!""}", "datum": <#if item.properties["rgbz:ondertekeningDatum"]??>"<@dateFormat item.properties["rgbz:ondertekeningDatum"] />"<#else>null</#if> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.put.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.put.json.ftl index 921bfa4..9fc6f17 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.put.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.put.json.ftl @@ -35,6 +35,11 @@ "bestandsdelen" : [<#list item.bestandsdelen as part><@renderFileParts part /><#if part_has_next>,</#if></#list>], "indicatieGebruiksrecht" : <#if item.properties["rgbz:indicatieGebruiksrecht"]??>${item.properties["rgbz:indicatieGebruiksrecht"]?c}<#else>null</#if>, "verschijningsvorm" : "${item.properties["rgbz:verschijningsvorm"]!""}", + "trefwoorden" : <#if item.properties["rgbz:trefwoorden"]?? && item.properties["rgbz:trefwoorden"]?size gt 0> + [ <#list item.properties["rgbz:trefwoorden"] as trefwoord>"${trefwoord}"<#if trefwoord_has_next>, </#if></#list>] + <#else> + null + </#if>, "ondertekening": <#if item.properties["rgbz:ondertekeningDatum"]??>{ "soort": "${item.properties["rgbz:ondertekeningSoort"]!""}", "datum": "<@dateFormat item.properties["rgbz:ondertekeningDatum"] />" -- GitLab From 5842937b9b2eb0725d56b766d0d36cb43db3f276 Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Fri, 7 Mar 2025 08:33:29 -0600 Subject: [PATCH 13/22] Toevoegen param trefwoorden aan EIO search --- .../tests/custom/CustomFilterParamsTest.java | 41 ++++++++++++++++- .../AbstractDrcDeclarativeWebScript.java | 1 + .../EnkelvoudiginformatieobjectenGet.java | 44 ++++++++++++------- 3 files changed, 70 insertions(+), 16 deletions(-) diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomFilterParamsTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomFilterParamsTest.java index a25c4c4..817303f 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomFilterParamsTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomFilterParamsTest.java @@ -1,5 +1,8 @@ package nl.contezza.drc.tests.custom; +import java.util.HashMap; +import java.util.Map; + import org.json.JSONArray; import org.json.JSONObject; import org.testng.Assert; @@ -8,6 +11,7 @@ import org.testng.annotations.Test; import io.restassured.path.json.JsonPath; import io.restassured.response.Response; +import nl.contezza.drc.dataprovider.DRCDataProvider; import nl.contezza.drc.rest.RestTest; import nl.contezza.drc.service.AuthService; import nl.contezza.drc.service.DRCRequestSpecification; @@ -50,7 +54,7 @@ public class CustomFilterParamsTest extends RestTest { Assert.assertEquals(res.getStatusCode(), 200); } - @Test(groups = "CustomFilterParams") + @Test(groups = "CustomFilterParams", enabled = true) public void filter_with_multiple_iot_without_allAuth() { AuthService authService = new AuthService(); @@ -102,4 +106,39 @@ public class CustomFilterParamsTest extends RestTest { Assert.assertEquals(res.getStatusCode(), 200); Assert.assertEquals((int) res.body().path("results.size()"), 3); } + + @Test(groups = "CustomFilterParams", enabled = true) + public void filter_with_trefwoorden() { + EIOService eioService = new EIOService(); + + JSONObject bodyCreate = new JSONObject(DRCDataProvider.testCreate(informatieobjecttypeUrl)); + JSONArray trefwoorden = new JSONArray(); + trefwoorden.put("filterWord1"); + trefwoorden.put("filterWord2"); + trefwoorden.put("filterWord3"); + bodyCreate.put("trefwoorden", trefwoorden); + Response res = eioService.testCreate(bodyCreate); + JsonPath json = new JsonPath(res.asString()); + + wait(30000); + + // Including filter + Map<String, String> params = new HashMap<>(); + params.put("identificatie", json.getString("identificatie")); + params.put("trefwoorden", "filterWord1,filterWord2"); + res = eioService.listEIO(params); + + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals((int) res.body().path("results.size()"), 1); + + // Test incorrect trefwoorden + params = new HashMap<>(); + params.put("identificatie", json.getString("identificatie")); + params.put("trefwoorden", "filterWord4"); + res = eioService.listEIO(params); + + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals((int) res.body().path("results.size()"), 0); + + } } \ No newline at end of file diff --git a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java index 6ac1ad1..3360719 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java @@ -80,6 +80,7 @@ public abstract class AbstractDrcDeclarativeWebScript extends DeclarativeWebScri public static final String PARAM_INFORMATIEOBJECT = "informatieobject"; public static final String PARAM_IDENTIFICATIE = "identificatie"; public static final String PARAM_BRONORGANISATIE = "bronorganisatie"; + public static final String PARAM_TREFWOORDEN = "trefwoorden"; public static final String PARAM_AARD_RELATIE = "aardRelatie"; public static final String PARAM_BETROKKENE = "betrokkene"; public static final String PARAM_PAGE = "page"; diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java index 0845442..3dfe5d8 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java @@ -24,6 +24,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.Map.Entry; +import java.util.stream.Collectors; import org.alfresco.model.ContentModel; import org.alfresco.service.cmr.repository.NodeRef; @@ -52,9 +53,9 @@ public class EnkelvoudiginformatieobjectenGet extends AbstractDrcDeclarativeWebS private static final String QUERY_EIO_WITH_IOT = "%s AND (%s)"; private static final String QUERY_EIO = "TYPE:\"cm:content\" AND ASPECT:\"rgbz:enkelvoudigInformatieobject\""; - private static final String QUERY_EIO_IDENTIFICATIE = "TYPE:\"cm:content\" AND ASPECT:\"rgbz:enkelvoudigInformatieobject\" AND =@rgbz\\:identificatie:\"%s\""; - private static final String QUERY_EIO_BRONORGANISATIE = "TYPE:\"cm:content\" AND ASPECT:\"rgbz:enkelvoudigInformatieobject\" AND =@rgbz\\:bronorganisatie:\"%s\""; - private static final String QUERY_EIO_IDENTIFICATIE_BRONORGANISATIE = "TYPE:\"cm:content\" AND ASPECT:\"rgbz:enkelvoudigInformatieobject\" AND =@rgbz\\:identificatie:\"%s\" AND =@rgbz\\:bronorganisatie:\"%s\""; + private static final String QUERY_EIO_IDENTIFICATIE = " AND =@rgbz\\:identificatie:\"%s\""; + private static final String QUERY_EIO_BRONORGANISATIE = " AND =@rgbz\\:bronorganisatie:\"%s\""; + private static final String QUERY_TREFWOORDEN = " AND @rgbz\\:trefwoorden:(%s)"; @Value("${drc.maxItems}") private Integer maxItems; @@ -261,7 +262,7 @@ public class EnkelvoudiginformatieobjectenGet extends AbstractDrcDeclarativeWebS String[] params = req.getParameterNames(); for (String param : params) { if (!param.equalsIgnoreCase(PARAM_BRONORGANISATIE) && !param.equalsIgnoreCase(PARAM_IDENTIFICATIE) - && !param.equalsIgnoreCase(PARAM_PAGE)) { + && !param.equalsIgnoreCase(PARAM_TREFWOORDEN) && !param.equalsIgnoreCase(PARAM_PAGE)) { List<DRCFieldValidationError> invalidParams = new ArrayList<DRCFieldValidationError>(); invalidParams.add(drcValidationHelper.newFieldValidationError("nonFieldErrors", DRCValidationHelper.CODE_UNKNOWN_PARAMETERS)); @@ -454,24 +455,33 @@ public class EnkelvoudiginformatieobjectenGet extends AbstractDrcDeclarativeWebS * @return String query based on provided params */ private String buildQuery(WebScriptRequest req) { - if (req.getParameter(PARAM_IDENTIFICATIE) != null && req.getParameter(PARAM_BRONORGANISATIE) != null) { - return String.format(QUERY_EIO_IDENTIFICATIE_BRONORGANISATIE, getParam(req, PARAM_IDENTIFICATIE), - getParam(req, PARAM_BRONORGANISATIE)); - } - if (req.getParameter(PARAM_IDENTIFICATIE) != null && req.getParameter(PARAM_BRONORGANISATIE) == null) { - return String.format(QUERY_EIO_IDENTIFICATIE, getParam(req, PARAM_IDENTIFICATIE)); + String query = QUERY_EIO; + + if (req.getParameter(PARAM_IDENTIFICATIE) != null) { + query += String.format(QUERY_EIO_IDENTIFICATIE, getParam(req, PARAM_IDENTIFICATIE)); } - if (req.getParameter(PARAM_IDENTIFICATIE) == null && req.getParameter(PARAM_BRONORGANISATIE) != null) { - return String.format(QUERY_EIO_BRONORGANISATIE, getParam(req, PARAM_BRONORGANISATIE)); + if (req.getParameter(PARAM_BRONORGANISATIE) != null) { + query += String.format(QUERY_EIO_BRONORGANISATIE, getParam(req, PARAM_BRONORGANISATIE)); } - if (req.getParameter(PARAM_IDENTIFICATIE) == null && req.getParameter(PARAM_BRONORGANISATIE) == null) { - return String.format(QUERY_EIO); + if (req.getParameter(PARAM_TREFWOORDEN) != null) { + String keywordsParam = getParam(req, PARAM_TREFWOORDEN); + List<String> keywords = Arrays.stream(keywordsParam.split(",")) + .map(String::trim).filter(s -> !s.isEmpty()).collect(Collectors.toList()); + + if (!keywords.isEmpty()) { + String trefwoordenQuery = keywords.stream() + .map(keyword -> "\"" + escapeQuery(keyword) + "\"") + .collect(Collectors.joining(" AND ")); + + query += String.format(QUERY_TREFWOORDEN, trefwoordenQuery); + } + } - return null; + return query; } /** @@ -491,4 +501,8 @@ public class EnkelvoudiginformatieobjectenGet extends AbstractDrcDeclarativeWebS return val; } + + private String escapeQuery(String keyword) { + return keyword.replace("\"", "\\\""); + } } \ No newline at end of file -- GitLab From 6d0eca63126483fe8b2f54007ba9438db43f5c99 Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Fri, 7 Mar 2025 14:03:14 -0600 Subject: [PATCH 14/22] Toevoegen property inhoudIsVervallen aan EIO en extra waardes aan statusConstraint --- docs/src/docs/asciidoc/includes/_data.adoc | 2 + .../drc/dataprovider/DRCDataProvider.java | 1 + ...CustomEnkelvoudigInformatieObjectTest.java | 56 +++++++++++++++++++ .../java/nl/contezza/drc/model/RGBZModel.java | 1 + .../AbstractDrcDeclarativeWebScript.java | 6 ++ .../messages/rgbz-model.properties | 1 + .../messages/rgbz-model_nl.properties | 1 + .../model/rgbz-model.xml | 5 ++ ...enkelvoudiginformatieobjecten.get.json.ftl | 1 + ...kelvoudiginformatieobjecten.patch.json.ftl | 1 + ...nkelvoudiginformatieobjecten.post.json.ftl | 1 + .../web-extension/site-config/drc-config.xml | 20 +++++-- 12 files changed, 91 insertions(+), 5 deletions(-) diff --git a/docs/src/docs/asciidoc/includes/_data.adoc b/docs/src/docs/asciidoc/includes/_data.adoc index d793e1a..e4e00ce 100644 --- a/docs/src/docs/asciidoc/includes/_data.adoc +++ b/docs/src/docs/asciidoc/includes/_data.adoc @@ -207,7 +207,9 @@ Waardebeperkingen worden toegepast tijdens integriteitscontroles, meestal aan he <parameter name="allowedValues"> <list> <value>in_bewerking</value> + <value>concept</value> <value>ter_vaststelling</value> + <value>vastgesteld</value> <value>definitief</value> <value>gearchiveerd</value> </list> diff --git a/integration-tests/src/main/java/nl/contezza/drc/dataprovider/DRCDataProvider.java b/integration-tests/src/main/java/nl/contezza/drc/dataprovider/DRCDataProvider.java index 81ef3ba..2aaecc9 100644 --- a/integration-tests/src/main/java/nl/contezza/drc/dataprovider/DRCDataProvider.java +++ b/integration-tests/src/main/java/nl/contezza/drc/dataprovider/DRCDataProvider.java @@ -55,6 +55,7 @@ public class DRCDataProvider { json.put("informatieobjecttype", iot); json.put("vertrouwelijkheidaanduiding", "openbaar"); json.put("verschijningsvorm", "Vorm A"); + json.put("inhoudIsVervallen", false); return json.toString(); } diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java index 90cd2e0..497ee54 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java @@ -166,4 +166,60 @@ public class CustomEnkelvoudigInformatieObjectTest extends RestTest { Assert.assertEquals(json.getString("trefwoorden[0]"), "trefwoord5"); Assert.assertEquals(json.getString("trefwoorden[1]"), "trefwoord6"); } + + @Test(groups = "CustomEnkelvoudigInformatieObjectTest", enabled = true) + public void test_inhoudIsVervallen() { + EIOService eioService = new EIOService(); + + // Validate verschijningsvorm at POST + Response res = eioService.testCreate(informatieobjecttypeUrl); + JsonPath json = new JsonPath(res.asString()); + + JSONObject createdEio = new JSONObject(json.prettify()); + + Assert.assertEquals(res.getStatusCode(), 201); + Assert.assertEquals(json.getBoolean("inhoudIsVervallen"), false); + + String eioUrl = json.getString("url"); + + // Validate verschijningsvorm at GET + res = eioService.getEIO(eioUrl, null); + json = new JsonPath(res.asString()); + + Assert.assertEquals(json.getBoolean("inhoudIsVervallen"), false); + + res = eioService.lock(eioUrl); + + Assert.assertEquals(res.getStatusCode(), 200); + + String lock = res.body().path("lock"); + + // Validate verschijningsvorm at PATCH + JSONObject body = new JSONObject(); + body.put("inhoudIsVervallen", true); + body.put("lock", lock); + + res = eioService.partialUpdate(eioUrl, body); + json = new JsonPath(res.asString()); + + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals(json.getBoolean("inhoudIsVervallen"), true); + + // Validate verschijningsvorm at PUT + body = new JSONObject(); + body.put("inhoudIsVervallen", false); + body.put("inhoud", Base64.getEncoder().encodeToString("some file content".getBytes())); + body.put("bestandsomvang", "some file content".getBytes().length); + body.put("lock", lock); + + JSONObject mergedJson = mergeJSONObjects(createdEio, body); + mergedJson.remove("ondertekening"); + mergedJson.remove("integriteit"); + + // Update EIO + res = eioService.update(eioUrl, mergedJson); + json = new JsonPath(res.asString()); + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals(json.getBoolean("inhoudIsVervallen"), false); + } } diff --git a/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java b/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java index fad5ede..38ea35e 100644 --- a/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java +++ b/platform/src/main/java/nl/contezza/drc/model/RGBZModel.java @@ -69,6 +69,7 @@ public interface RGBZModel { QName PROP_OMSCHRIJVING_VOORWAARDEN = QName.createQName(URI, "omschrijvingVoorwaarden"); QName PROP_VERSCHIJNINGSVORM = QName.createQName(URI, "verschijningsvorm"); QName PROP_TREFWOORDEN = QName.createQName(URI, "trefwoorden"); + QName PROP_INHOUD_IS_VERVALLEN = QName.createQName(URI, "inhoudIsVervallen"); QName PROP_AUDIT_TOELICHTING = QName.createQName(URI, "auditToelichting"); QName PROP_AUDIT_USER_ID = QName.createQName(URI, "auditUserId"); QName PROP_AUDIT_USER_REPRESENTATION = QName.createQName(URI, "auditUserRepresentation"); diff --git a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java index 3360719..46447fa 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java @@ -504,6 +504,12 @@ public abstract class AbstractDrcDeclarativeWebScript extends DeclarativeWebScri RGBZModel.PROP_TREFWOORDEN.getLocalName())); } + if (getJsonBoolean(jsonRequest, RGBZModel.PROP_INHOUD_IS_VERVALLEN.getLocalName()) != null) { + props.put(RGBZModel.PROP_INHOUD_IS_VERVALLEN, + getJsonBoolean(jsonRequest, RGBZModel.PROP_INHOUD_IS_VERVALLEN.getLocalName()) == null ? null + : getJsonBoolean(jsonRequest, RGBZModel.PROP_INHOUD_IS_VERVALLEN.getLocalName())); + } + Long bestandsomvang = getJsonLong(jsonRequest, "bestandsomvang"); if (bestandsomvang != null || jsonRequest.has("bestandsomvang")) { props.put(RGBZModel.PROP_BESTANDSOMVANG, bestandsomvang); diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model.properties b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model.properties index 94007e6..38347b2 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model.properties +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model.properties @@ -36,6 +36,7 @@ rgbz_model.property.rgbz_integriteitDatum.title=Datum (integriteit) rgbz_model.property.rgbz_informatieobjecttype.title=Informatieobjecttype rgbz_model.property.rgbz_verschijningsvorm.title=Verschijningsvorm rgbz_model.property.rgbz_trefwoorden.title=Trefwoorden +rgbz_model.property.rgbz_inhoudIsVervallen.title=Inhoud is vervallen #Constraints listconstraint.rgbz_vertrouwelijkheidaanduidingConstraint.openbaar=Openbaar diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model_nl.properties b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model_nl.properties index 94007e6..38347b2 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model_nl.properties +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/messages/rgbz-model_nl.properties @@ -36,6 +36,7 @@ rgbz_model.property.rgbz_integriteitDatum.title=Datum (integriteit) rgbz_model.property.rgbz_informatieobjecttype.title=Informatieobjecttype rgbz_model.property.rgbz_verschijningsvorm.title=Verschijningsvorm rgbz_model.property.rgbz_trefwoorden.title=Trefwoorden +rgbz_model.property.rgbz_inhoudIsVervallen.title=Inhoud is vervallen #Constraints listconstraint.rgbz_vertrouwelijkheidaanduidingConstraint.openbaar=Openbaar diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/model/rgbz-model.xml b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/model/rgbz-model.xml index 902a323..925b117 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/model/rgbz-model.xml +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/model/rgbz-model.xml @@ -38,7 +38,9 @@ <list> <value></value> <value>in_bewerking</value> + <value>concept</value> <value>ter_vaststelling</value> + <value>vastgesteld</value> <value>definitief</value> <value>gearchiveerd</value> </list> @@ -402,6 +404,9 @@ <type>d:text</type> <multiple>true</multiple> </property> + <property name="rgbz:inhoudIsVervallen"> + <type>d:boolean</type> + </property> <!-- Wordt gebruikt ter ondersteuning van bestandsdelen --> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.get.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.get.json.ftl index 1225785..dd9eb21 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.get.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.get.json.ftl @@ -41,6 +41,7 @@ <#else> null </#if>, + "inhoudIsVervallen" : <#if item.properties["rgbz:inhoudIsVervallen"]??>${item.properties["rgbz:inhoudIsVervallen"]?c}<#else>null</#if>, "ondertekening": { "soort": "${item.properties["rgbz:ondertekeningSoort"]!""}", "datum": <#if item.properties["rgbz:ondertekeningDatum"]??>"<@dateFormat item.properties["rgbz:ondertekeningDatum"] />"<#else>null</#if> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.patch.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.patch.json.ftl index 7821086..aff1add 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.patch.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.patch.json.ftl @@ -40,6 +40,7 @@ <#else> null </#if>, + "inhoudIsVervallen" : <#if item.properties["rgbz:inhoudIsVervallen"]??>${item.properties["rgbz:inhoudIsVervallen"]?c}<#else>null</#if>, "ondertekening": <#if item.properties["rgbz:ondertekeningDatum"]??>{ "soort": "${item.properties["rgbz:ondertekeningSoort"]!""}", "datum": "<@dateFormat item.properties["rgbz:ondertekeningDatum"] />" diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl index eb23404..d8929ca 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl @@ -41,6 +41,7 @@ <#else> null </#if>, + "inhoudIsVervallen" : <#if item.properties["rgbz:inhoudIsVervallen"]??>${item.properties["rgbz:inhoudIsVervallen"]?c}<#else>null</#if>, "ondertekening": { "soort": "${item.properties["rgbz:ondertekeningSoort"]!""}", "datum": <#if item.properties["rgbz:ondertekeningDatum"]??>"<@dateFormat item.properties["rgbz:ondertekeningDatum"] />"<#else>null</#if> diff --git a/share/src/main/resources/alfresco/web-extension/site-config/drc-config.xml b/share/src/main/resources/alfresco/web-extension/site-config/drc-config.xml index 5c99176..ef8b95c 100644 --- a/share/src/main/resources/alfresco/web-extension/site-config/drc-config.xml +++ b/share/src/main/resources/alfresco/web-extension/site-config/drc-config.xml @@ -20,9 +20,13 @@ <show id="rgbz:integriteitWaarde" /> <show id="rgbz:integriteitDatum" /> <show id="rgbz:informatieobjecttype" /> + <show id="rgbz:verschijningsvorm" /> + <show id="rgbz:trefwoorden" /> + <show id="rgbz:inhoudIsVervallen" /> </field-visibility> <appearance> - <set id="rgbzEnkelvoudigInformatieobjectPanel" label-id="aspect.rgbz_enkelvoudigInformatieobject" appearance="panel" /> + <set id="rgbzEnkelvoudigInformatieobjectPanel" + label-id="aspect.rgbz_enkelvoudigInformatieobject" appearance="panel" /> <field id="rgbz:identificatie" set="rgbzEnkelvoudigInformatieobjectPanel" /> <field id="rgbz:bronorganisatie" set="rgbzEnkelvoudigInformatieobjectPanel" /> @@ -32,17 +36,23 @@ <field id="rgbz:link" set="rgbzEnkelvoudigInformatieobjectPanel" /> <field id="rgbz:ontvangstdatum" set="rgbzEnkelvoudigInformatieobjectPanel" /> <field id="rgbz:verzenddatum" set="rgbzEnkelvoudigInformatieobjectPanel" /> - <field id="rgbz:vertrouwelijkheidaanduiding" set="rgbzEnkelvoudigInformatieobjectPanel" /> - <field id="rgbz:indicatieGebruiksrecht" set="rgbzEnkelvoudigInformatieobjectPanel" /> + <field id="rgbz:vertrouwelijkheidaanduiding" + set="rgbzEnkelvoudigInformatieobjectPanel" /> + <field id="rgbz:indicatieGebruiksrecht" + set="rgbzEnkelvoudigInformatieobjectPanel" /> <field id="rgbz:ondertekeningSoort" set="rgbzEnkelvoudigInformatieobjectPanel" /> <field id="rgbz:ondertekeningDatum" set="rgbzEnkelvoudigInformatieobjectPanel" /> <field id="rgbz:integriteitAlgoritme" set="rgbzEnkelvoudigInformatieobjectPanel" /> <field id="rgbz:integriteitWaarde" set="rgbzEnkelvoudigInformatieobjectPanel" /> <field id="rgbz:integriteitDatum" set="rgbzEnkelvoudigInformatieobjectPanel" /> - <field id="rgbz:informatieobjecttype" set="rgbzEnkelvoudigInformatieobjectPanel" readonly="true" /> + <field id="rgbz:verschijningsvorm" set="rgbzEnkelvoudigInformatieobjectPanel" /> + <field id="rgbz:trefwoorden" set="rgbzEnkelvoudigInformatieobjectPanel" /> + <field id="rgbz:inhoudIsVervallen" set="rgbzEnkelvoudigInformatieobjectPanel" /> + <field id="rgbz:informatieobjecttype" set="rgbzEnkelvoudigInformatieobjectPanel" + readonly="true" /> </appearance> </form> </forms> </config> - + </alfresco-config> \ No newline at end of file -- GitLab From d4e4d5567a3e7990c79766e585d1353bebaa0639 Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Fri, 7 Mar 2025 14:20:01 -0600 Subject: [PATCH 15/22] Update YAML naar 1.5.0 --- .../files/openapi.yaml | 2197 ++++++++++------- 1 file changed, 1262 insertions(+), 935 deletions(-) diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/files/openapi.yaml b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/files/openapi.yaml index 52ec40f..ce6e532 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/files/openapi.yaml +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/files/openapi.yaml @@ -1,7 +1,7 @@ openapi: 3.0.3 info: title: Documenten API - version: 1.3.0 + version: 1.5.0 description: "Een API om een documentregistratiecomponent (DRC) te benaderen.\n\n\ In een documentregistratiecomponent worden INFORMATIEOBJECTen opgeslagen. Een\n\ @@ -258,6 +258,23 @@ paths: \ eerste in een samenwerkingsketen heeft vastgelegd." schema: type: string + - name: trefwoorden + required: false + in: query + description: Een lijst van trefwoorden gescheiden door comma's. + schema: + type: string + - name: expand + required: false + in: query + description: + "Examples: \n`expand=zaaktype, status, status.statustype, hoofdzaak.status.statustype,\ + \ hoofdzaak.deelzaken.status.statustype`\nHaal details van gelinkte resources\ + \ direct op. Als je meerdere resources tegelijk wilt ophalen kun je deze\ + \ scheiden met een komma. Voor het ophalen van resources die een laag dieper\ + \ genest zijn wordt de punt-notatie gebruikt." + schema: + type: string - name: page required: false in: query @@ -455,7 +472,7 @@ paths: content: application/json: schema: - $ref: "#/components/schemas/EnkelvoudigInformatieObjectCreateLock" + $ref: "#/components/schemas/SchemaEIO" description: Created "400": headers: @@ -915,6 +932,31 @@ paths: description: Een datumtijd in ISO8601 formaat. De versie van het INFORMATIEOBJECT die qua `begin_registratie` het kortst hiervoor zit wordt opgehaald. + - in: query + name: expand + schema: + type: string + description: + Haal details van gelinkte resources direct op. Als je meerdere + resources tegelijk wilt ophalen kun je deze scheiden met een komma. Voor + het ophalen van resources die een laag dieper genest zijn wordt de punt-notatie + gebruikt. + examples: + ExpandZaaktype: + value: zaaktype + summary: expand zaaktype + ExpandStatus: + value: status + summary: expand status + ExpandStatus.statustype: + value: status.statustype + summary: expand status.statustype + ExpandHoofdzaak.status.statustype: + value: hoofdzaak.status.statustype + summary: expand hoofdzaak.status.statustype + ExpandHoofdzaak.deelzaken.status.statustype: + value: hoofdzaak.deelzaken.status.statustype + summary: expand hoofdzaak.deelzaken.status.statustype tags: - enkelvoudiginformatieobjecten security: @@ -939,7 +981,7 @@ paths: content: application/json: schema: - $ref: "#/components/schemas/EnkelvoudigInformatieObject" + $ref: "#/components/schemas/SchemaEIO" description: OK "401": headers: @@ -1062,8 +1104,7 @@ paths: operationId: enkelvoudiginformatieobject_update description: "Dit cre\xEBert altijd een nieuwe versie van het (ENKELVOUDIG)\ - \ INFORMATIEOBJECT. \n \n**Er wordt gevalideerd op**\n- correcte `lock` waarde\n\ - - status NIET `definitief`" + \ INFORMATIEOBJECT." summary: Werk een (ENKELVOUDIG) INFORMATIEOBJECT in zijn geheel bij. parameters: - in: path @@ -1251,8 +1292,7 @@ paths: operationId: enkelvoudiginformatieobject_partial_update description: "Dit cre\xEBert altijd een nieuwe versie van het (ENKELVOUDIG)\ - \ INFORMATIEOBJECT. \n\n**Er wordt gevalideerd op**\n - correcte `lock` waarde\n\ - \ - status NIET `definitief`" + \ INFORMATIEOBJECT." summary: Werk een (ENKELVOUDIG) INFORMATIEOBJECT deels bij. parameters: - in: path @@ -2182,6 +2222,17 @@ paths: toepassing zijn. schema: type: string + - name: expand + required: false + in: query + description: + "Examples: \n`expand=zaaktype, status, status.statustype, hoofdzaak.status.statustype,\ + \ hoofdzaak.deelzaken.status.statustype`\nHaal details van gelinkte resources\ + \ direct op. Als je meerdere resources tegelijk wilt ophalen kun je deze\ + \ scheiden met een komma. Voor het ophalen van resources die een laag dieper\ + \ genest zijn wordt de punt-notatie gebruikt." + schema: + type: string tags: - gebruiksrechten security: @@ -2525,6 +2576,31 @@ paths: MultipleValues: value: '"79054025255fb1a26e4bc422aef54eb4", "e4d909c290d0fb1ca068ffaddf22cbd0"' summary: Meerdere ETag-waardes + - in: query + name: expand + schema: + type: string + description: + Haal details van gelinkte resources direct op. Als je meerdere + resources tegelijk wilt ophalen kun je deze scheiden met een komma. Voor + het ophalen van resources die een laag dieper genest zijn wordt de punt-notatie + gebruikt. + examples: + ExpandZaaktype: + value: zaaktype + summary: expand zaaktype + ExpandStatus: + value: status + summary: expand status + ExpandStatus.statustype: + value: status.statustype + summary: expand status.statustype + ExpandHoofdzaak.status.statustype: + value: hoofdzaak.status.statustype + summary: expand hoofdzaak.status.statustype + ExpandHoofdzaak.deelzaken.status.statustype: + value: hoofdzaak.deelzaken.status.statustype + summary: expand hoofdzaak.deelzaken.status.statustype tags: - gebruiksrechten security: @@ -3266,6 +3342,17 @@ paths: schema: type: string format: uri + - name: expand + required: false + in: query + description: + "Examples: \n`expand=zaaktype, status, status.statustype, hoofdzaak.status.statustype,\ + \ hoofdzaak.deelzaken.status.statustype`\nHaal details van gelinkte resources\ + \ direct op. Als je meerdere resources tegelijk wilt ophalen kun je deze\ + \ scheiden met een komma. Voor het ophalen van resources die een laag dieper\ + \ genest zijn wordt de punt-notatie gebruikt." + schema: + type: string tags: - objectinformatieobjecten security: @@ -3601,6 +3688,31 @@ paths: MultipleValues: value: '"79054025255fb1a26e4bc422aef54eb4", "e4d909c290d0fb1ca068ffaddf22cbd0"' summary: Meerdere ETag-waardes + - in: query + name: expand + schema: + type: string + description: + Haal details van gelinkte resources direct op. Als je meerdere + resources tegelijk wilt ophalen kun je deze scheiden met een komma. Voor + het ophalen van resources die een laag dieper genest zijn wordt de punt-notatie + gebruikt. + examples: + ExpandZaaktype: + value: zaaktype + summary: expand zaaktype + ExpandStatus: + value: status + summary: expand status + ExpandStatus.statustype: + value: status.statustype + summary: expand status.statustype + ExpandHoofdzaak.status.statustype: + value: hoofdzaak.status.statustype + summary: expand hoofdzaak.status.statustype + ExpandHoofdzaak.deelzaken.status.statustype: + value: hoofdzaak.deelzaken.status.statustype + summary: expand hoofdzaak.deelzaken.status.statustype tags: - objectinformatieobjecten security: @@ -3974,6 +4086,17 @@ paths: schema: type: string format: uri + - name: expand + required: false + in: query + description: + "Examples: \n`expand=zaaktype, status, status.statustype, hoofdzaak.status.statustype,\ + \ hoofdzaak.deelzaken.status.statustype`\nHaal details van gelinkte resources\ + \ direct op. Als je meerdere resources tegelijk wilt ophalen kun je deze\ + \ scheiden met een komma. Voor het ophalen van resources die een laag dieper\ + \ genest zijn wordt de punt-notatie gebruikt." + schema: + type: string - name: page required: false in: query @@ -4302,6 +4425,31 @@ paths: MultipleValues: value: '"79054025255fb1a26e4bc422aef54eb4", "e4d909c290d0fb1ca068ffaddf22cbd0"' summary: Meerdere ETag-waardes + - in: query + name: expand + schema: + type: string + description: + Haal details van gelinkte resources direct op. Als je meerdere + resources tegelijk wilt ophalen kun je deze scheiden met een komma. Voor + het ophalen van resources die een laag dieper genest zijn wordt de punt-notatie + gebruikt. + examples: + ExpandZaaktype: + value: zaaktype + summary: expand zaaktype + ExpandStatus: + value: status + summary: expand status + ExpandStatus.statustype: + value: status.statustype + summary: expand status.statustype + ExpandHoofdzaak.status.statustype: + value: hoofdzaak.status.statustype + summary: expand hoofdzaak.status.statustype + ExpandHoofdzaak.deelzaken.status.statustype: + value: hoofdzaak.deelzaken.status.statustype + summary: expand hoofdzaak.deelzaken.status.statustype tags: - verzendingen responses: @@ -5301,7 +5449,12 @@ components: zeggen: het aantal bytes dat staat genoemd bij grootte is daadwerkelijk ontvangen." title: voltooid + lock: + type: string + description: Hash string, which represents id of the lock of related informatieobject + title: lock required: + - lock - omvang - url - volgnummer @@ -5317,7 +5470,6 @@ components: title: inhoud lock: type: string - writeOnly: true minLength: 1 description: Hash string, which represents id of the lock of related informatieobject title: lock @@ -5675,6 +5827,16 @@ components: title: "" description: Array of unieke resource identifiers (UUID4) title: uuid__in + expand: + type: string + minLength: 1 + description: + "Examples: \n`expand=zaaktype, status, status.statustype, hoofdzaak.status.statustype,\ + \ hoofdzaak.deelzaken.status.statustype`\nHaal details van gelinkte resources\ + \ direct op. Als je meerdere resources tegelijk wilt ophalen kun je deze\ + \ scheiden met een komma. Voor het ophalen van resources die een laag\ + \ dieper genest zijn wordt de punt-notatie gebruikt." + title: expand required: - uuid_In EnkelvoudigInformatieObject: @@ -5765,12 +5927,17 @@ components: * `in_bewerking` - (In bewerking) Aan het informatieobject wordt nog gewerkt. - * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar - moet nog vastgesteld worden. + * `concept` - (Concept) Het document is inhoudelijk klaar om voorgelegd + teworden aan anderen en zo nodig aangepast te worden opbasis van commentaar.. * `definitief` - (Definitief) Informatieobject door bevoegd iets of iemand vastgesteld dan wel ontvangen. + * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar + moet nog vastgesteld worden. + + * `vastgesteld` - (Vastgesteld) Het besluitvormingstraject is afgerond. + * `gearchiveerd` - (Gearchiveerd) Informatieobject duurzaam bewaarbaar gemaakt; een gearchiveerd informatie-element." title: status @@ -5847,25 +6014,27 @@ components: format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht - te registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende - organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden - aan documenten die van of naar andere personen ontvangen of verzonden - zijn waarbij die personen niet deel uit maken van de behandeling van de - zaak waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht te\ + \ registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende\ + \ organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden\ + \ aan documenten die van of naar andere personen ontvangen of verzonden\ + \ zijn waarbij die personen niet deel uit maken van de behandeling van\ + \ de zaak waarin het document een rol speelt." title: ontvangstdatum verzenddatum: type: string format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze - op het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als - uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk - inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan - documenten die van of naar andere personen ontvangen of verzonden zijn - waarbij die personen niet deel uit maken van de behandeling van de zaak - waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze op\ + \ het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als\ + \ uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk\ + \ inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan\ + \ documenten die van of naar andere personen ontvangen of verzonden zijn\ + \ waarbij die personen niet deel uit maken van de behandeling van de zaak\ + \ waarin het document een rol speelt." title: verzenddatum indicatieGebruiksrecht: type: boolean @@ -5919,6 +6088,21 @@ components: $ref: "#/components/schemas/BestandsDeel" readOnly: true title: bestandsdelen + trefwoorden: + type: array + items: + type: string + maxLength: 100 + nullable: true + description: Een lijst van trefwoorden gescheiden door comma's. + title: trefwoorden + inhoudIsVervallen: + type: boolean + nullable: true + description: + Geeft aan of de inhoud van het informatieobject vervallen (dus + niet langer geldig) is. + title: inhoud is vervallen required: - auteur - beginRegistratie @@ -5931,7 +6115,7 @@ components: - titel - url - versie - EnkelvoudigInformatieObjectCreateLock: + EnkelvoudigInformatieObjectCreateLockRequest: type: object description: "This serializer class is used by EnkelvoudigInformatieObjectViewSet @@ -5939,16 +6123,6 @@ components: create operation for large files" properties: - url: - type: string - format: uri - readOnly: true - title: url - description: - URL-referentie naar dit object. Dit is de unieke identificatie - en locatie van dit object. - minLength: 1 - maxLength: 1000 identificatie: type: string description: @@ -5958,6 +6132,7 @@ components: maxLength: 40 bronorganisatie: type: string + minLength: 1 description: "Het RSIN van de Niet-natuurlijk persoon zijnde de organisatie\ \ die het informatieobject heeft gecre\xEBerd of heeft ontvangen en als\ @@ -5971,6 +6146,7 @@ components: title: creatiedatum titel: type: string + minLength: 1 description: De naam waaronder het INFORMATIEOBJECT formeel bekend is. title: titel maxLength: 200 @@ -6004,6 +6180,7 @@ components: - $ref: "#/components/schemas/BlankEnum" auteur: type: string + minLength: 1 description: "De persoon of organisatie die in de eerste plaats verantwoordelijk\ \ is voor het cre\xEBren van de inhoud van het INFORMATIEOBJECT." @@ -6023,12 +6200,17 @@ components: * `in_bewerking` - (In bewerking) Aan het informatieobject wordt nog gewerkt. - * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar - moet nog vastgesteld worden. + * `concept` - (Concept) Het document is inhoudelijk klaar om voorgelegd + teworden aan anderen en zo nodig aangepast te worden opbasis van commentaar.. * `definitief` - (Definitief) Informatieobject door bevoegd iets of iemand vastgesteld dan wel ontvangen. + * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar + moet nog vastgesteld worden. + + * `vastgesteld` - (Vastgesteld) Het besluitvormingstraject is afgerond. + * `gearchiveerd` - (Gearchiveerd) Informatieobject duurzaam bewaarbaar gemaakt; een gearchiveerd informatie-element." title: status @@ -6045,27 +6227,12 @@ components: maxLength: 255 taal: type: string + minLength: 3 description: "Een ISO 639-2/B taalcode waarin de inhoud van het INFORMATIEOBJECT is vastgelegd. Voorbeeld: `dut`. Zie: https://www.iso.org/standard/4767.html" title: taal maxLength: 3 - minLength: 3 - versie: - type: integer - readOnly: true - description: - Het (automatische) versienummer van het INFORMATIEOBJECT. Deze - begint bij 1 als het INFORMATIEOBJECT aangemaakt wordt. - title: versie - beginRegistratie: - type: string - format: date-time - readOnly: true - description: - Een datumtijd in ISO8601 formaat waarop deze versie van het - INFORMATIEOBJECT is aangemaakt of gewijzigd. - title: begin registratie bestandsnaam: type: string description: @@ -6075,8 +6242,8 @@ components: maxLength: 255 inhoud: type: string - format: uri - description: Download URL van de binaire inhoud. + format: byte + description: "Binaire inhoud, in base64 ge\xEBncodeerd." nullable: true title: inhoud bestandsomvang: @@ -6105,25 +6272,27 @@ components: format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht - te registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende - organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden - aan documenten die van of naar andere personen ontvangen of verzonden - zijn waarbij die personen niet deel uit maken van de behandeling van de - zaak waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht te\ + \ registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende\ + \ organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden\ + \ aan documenten die van of naar andere personen ontvangen of verzonden\ + \ zijn waarbij die personen niet deel uit maken van de behandeling van\ + \ de zaak waarin het document een rol speelt." title: ontvangstdatum verzenddatum: type: string format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze - op het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als - uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk - inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan - documenten die van of naar andere personen ontvangen of verzonden zijn - waarbij die personen niet deel uit maken van de behandeling van de zaak - waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze op\ + \ het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als\ + \ uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk\ + \ inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan\ + \ documenten die van of naar andere personen ontvangen of verzonden zijn\ + \ waarbij die personen niet deel uit maken van de behandeling van de zaak\ + \ waarin het document een rol speelt." title: verzenddatum indicatieGebruiksrecht: type: boolean @@ -6141,7 +6310,7 @@ components: title: verschijningsvorm ondertekening: allOf: - - $ref: "#/components/schemas/Ondertekening" + - $ref: "#/components/schemas/OndertekeningRequest" nullable: true description: Aanduiding van de rechtskracht van een informatieobject. Mag @@ -6150,7 +6319,7 @@ components: title: ondertekening integriteit: allOf: - - $ref: "#/components/schemas/Integriteit" + - $ref: "#/components/schemas/IntegriteitRequest" nullable: true description: Uitdrukking van mate van volledigheid en onbeschadigd zijn @@ -6159,53 +6328,53 @@ components: informatieobjecttype: type: string format: uri + minLength: 1 description: URL-referentie naar het INFORMATIEOBJECTTYPE (in de Catalogi API). title: informatieobjecttype maxLength: 200 - locked: - type: boolean - readOnly: true - description: - Geeft aan of het document gelocked is. Alleen als een document - gelocked is, mogen er aanpassingen gemaakt worden. - title: locked - bestandsdelen: + trefwoorden: type: array items: - $ref: "#/components/schemas/BestandsDeel" - readOnly: true - title: bestandsdelen - lock: - type: string - readOnly: true + type: string + minLength: 1 + maxLength: 100 + nullable: true + description: Een lijst van trefwoorden gescheiden door comma's. + title: trefwoorden + inhoudIsVervallen: + type: boolean + nullable: true description: - Lock id generated if the large file is created and should be - used while updating the document. Documents with base64 encoded files - are created without lock - title: lock + Geeft aan of de inhoud van het informatieobject vervallen (dus + niet langer geldig) is. + title: inhoud is vervallen required: - auteur - - beginRegistratie - - bestandsdelen - bronorganisatie - creatiedatum - informatieobjecttype - - lock - - locked - taal - titel - - url - - versie - EnkelvoudigInformatieObjectCreateLockRequest: + EnkelvoudigInformatieObjectWithLock: type: object description: "This serializer class is used by EnkelvoudigInformatieObjectViewSet for - create operation for large files" + update and partial_update operations" properties: + url: + type: string + format: uri + readOnly: true + title: url + description: + URL-referentie naar dit object. Dit is de unieke identificatie + en locatie van dit object. + minLength: 1 + maxLength: 1000 identificatie: type: string description: @@ -6215,7 +6384,6 @@ components: maxLength: 40 bronorganisatie: type: string - minLength: 1 description: "Het RSIN van de Niet-natuurlijk persoon zijnde de organisatie\ \ die het informatieobject heeft gecre\xEBerd of heeft ontvangen en als\ @@ -6229,7 +6397,6 @@ components: title: creatiedatum titel: type: string - minLength: 1 description: De naam waaronder het INFORMATIEOBJECT formeel bekend is. title: titel maxLength: 200 @@ -6263,7 +6430,6 @@ components: - $ref: "#/components/schemas/BlankEnum" auteur: type: string - minLength: 1 description: "De persoon of organisatie die in de eerste plaats verantwoordelijk\ \ is voor het cre\xEBren van de inhoud van het INFORMATIEOBJECT." @@ -6283,12 +6449,17 @@ components: * `in_bewerking` - (In bewerking) Aan het informatieobject wordt nog gewerkt. - * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar - moet nog vastgesteld worden. + * `concept` - (Concept) Het document is inhoudelijk klaar om voorgelegd + teworden aan anderen en zo nodig aangepast te worden opbasis van commentaar.. * `definitief` - (Definitief) Informatieobject door bevoegd iets of iemand vastgesteld dan wel ontvangen. + * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar + moet nog vastgesteld worden. + + * `vastgesteld` - (Vastgesteld) Het besluitvormingstraject is afgerond. + * `gearchiveerd` - (Gearchiveerd) Informatieobject duurzaam bewaarbaar gemaakt; een gearchiveerd informatie-element." title: status @@ -6305,12 +6476,27 @@ components: maxLength: 255 taal: type: string - minLength: 3 description: "Een ISO 639-2/B taalcode waarin de inhoud van het INFORMATIEOBJECT is vastgelegd. Voorbeeld: `dut`. Zie: https://www.iso.org/standard/4767.html" title: taal maxLength: 3 + minLength: 3 + versie: + type: integer + readOnly: true + description: + Het (automatische) versienummer van het INFORMATIEOBJECT. Deze + begint bij 1 als het INFORMATIEOBJECT aangemaakt wordt. + title: versie + beginRegistratie: + type: string + format: date-time + readOnly: true + description: + Een datumtijd in ISO8601 formaat waarop deze versie van het + INFORMATIEOBJECT is aangemaakt of gewijzigd. + title: begin registratie bestandsnaam: type: string description: @@ -6320,8 +6506,8 @@ components: maxLength: 255 inhoud: type: string - format: byte - description: "Binaire inhoud, in base64 ge\xEBncodeerd." + format: uri + description: Download URL van de binaire inhoud. nullable: true title: inhoud bestandsomvang: @@ -6350,25 +6536,27 @@ components: format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht - te registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende - organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden - aan documenten die van of naar andere personen ontvangen of verzonden - zijn waarbij die personen niet deel uit maken van de behandeling van de - zaak waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht te\ + \ registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende\ + \ organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden\ + \ aan documenten die van of naar andere personen ontvangen of verzonden\ + \ zijn waarbij die personen niet deel uit maken van de behandeling van\ + \ de zaak waarin het document een rol speelt." title: ontvangstdatum verzenddatum: type: string format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze - op het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als - uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk - inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan - documenten die van of naar andere personen ontvangen of verzonden zijn - waarbij die personen niet deel uit maken van de behandeling van de zaak - waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze op\ + \ het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als\ + \ uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk\ + \ inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan\ + \ documenten die van of naar andere personen ontvangen of verzonden zijn\ + \ waarbij die personen niet deel uit maken van de behandeling van de zaak\ + \ waarin het document een rol speelt." title: verzenddatum indicatieGebruiksrecht: type: boolean @@ -6386,7 +6574,7 @@ components: title: verschijningsvorm ondertekening: allOf: - - $ref: "#/components/schemas/OndertekeningRequest" + - $ref: "#/components/schemas/Ondertekening" nullable: true description: Aanduiding van de rechtskracht van een informatieobject. Mag @@ -6395,7 +6583,7 @@ components: title: ondertekening integriteit: allOf: - - $ref: "#/components/schemas/IntegriteitRequest" + - $ref: "#/components/schemas/Integriteit" nullable: true description: Uitdrukking van mate van volledigheid en onbeschadigd zijn @@ -6404,20 +6592,52 @@ components: informatieobjecttype: type: string format: uri - minLength: 1 description: URL-referentie naar het INFORMATIEOBJECTTYPE (in de Catalogi API). title: informatieobjecttype maxLength: 200 + locked: + type: boolean + readOnly: true + description: + Geeft aan of het document gelocked is. Alleen als een document + gelocked is, mogen er aanpassingen gemaakt worden. + title: locked + bestandsdelen: + type: array + items: + $ref: "#/components/schemas/BestandsDeel" + readOnly: true + title: bestandsdelen + trefwoorden: + type: array + items: + type: string + maxLength: 100 + nullable: true + description: Een lijst van trefwoorden gescheiden door comma's. + title: trefwoorden + inhoudIsVervallen: + type: boolean + nullable: true + description: + Geeft aan of de inhoud van het informatieobject vervallen (dus + niet langer geldig) is. + title: inhoud is vervallen required: - auteur + - beginRegistratie + - bestandsdelen - bronorganisatie - creatiedatum - informatieobjecttype + - locked - taal - titel - EnkelvoudigInformatieObjectWithLock: + - url + - versie + EnkelvoudigInformatieObjectWithLockRequest: type: object description: "This serializer class is used by EnkelvoudigInformatieObjectViewSet @@ -6425,17 +6645,7 @@ components: update and partial_update operations" properties: - url: - type: string - format: uri - readOnly: true - title: url - description: - URL-referentie naar dit object. Dit is de unieke identificatie - en locatie van dit object. - minLength: 1 - maxLength: 1000 - identificatie: + identificatie: type: string description: Een binnen een gegeven context ondubbelzinnige referentie naar @@ -6444,6 +6654,7 @@ components: maxLength: 40 bronorganisatie: type: string + minLength: 1 description: "Het RSIN van de Niet-natuurlijk persoon zijnde de organisatie\ \ die het informatieobject heeft gecre\xEBerd of heeft ontvangen en als\ @@ -6457,6 +6668,7 @@ components: title: creatiedatum titel: type: string + minLength: 1 description: De naam waaronder het INFORMATIEOBJECT formeel bekend is. title: titel maxLength: 200 @@ -6490,6 +6702,7 @@ components: - $ref: "#/components/schemas/BlankEnum" auteur: type: string + minLength: 1 description: "De persoon of organisatie die in de eerste plaats verantwoordelijk\ \ is voor het cre\xEBren van de inhoud van het INFORMATIEOBJECT." @@ -6509,12 +6722,17 @@ components: * `in_bewerking` - (In bewerking) Aan het informatieobject wordt nog gewerkt. - * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar - moet nog vastgesteld worden. + * `concept` - (Concept) Het document is inhoudelijk klaar om voorgelegd + teworden aan anderen en zo nodig aangepast te worden opbasis van commentaar.. * `definitief` - (Definitief) Informatieobject door bevoegd iets of iemand vastgesteld dan wel ontvangen. + * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar + moet nog vastgesteld worden. + + * `vastgesteld` - (Vastgesteld) Het besluitvormingstraject is afgerond. + * `gearchiveerd` - (Gearchiveerd) Informatieobject duurzaam bewaarbaar gemaakt; een gearchiveerd informatie-element." title: status @@ -6531,27 +6749,12 @@ components: maxLength: 255 taal: type: string + minLength: 3 description: "Een ISO 639-2/B taalcode waarin de inhoud van het INFORMATIEOBJECT is vastgelegd. Voorbeeld: `dut`. Zie: https://www.iso.org/standard/4767.html" title: taal maxLength: 3 - minLength: 3 - versie: - type: integer - readOnly: true - description: - Het (automatische) versienummer van het INFORMATIEOBJECT. Deze - begint bij 1 als het INFORMATIEOBJECT aangemaakt wordt. - title: versie - beginRegistratie: - type: string - format: date-time - readOnly: true - description: - Een datumtijd in ISO8601 formaat waarop deze versie van het - INFORMATIEOBJECT is aangemaakt of gewijzigd. - title: begin registratie bestandsnaam: type: string description: @@ -6561,8 +6764,8 @@ components: maxLength: 255 inhoud: type: string - format: uri - description: Download URL van de binaire inhoud. + format: byte + description: "Binaire inhoud, in base64 ge\xEBncodeerd." nullable: true title: inhoud bestandsomvang: @@ -6591,25 +6794,27 @@ components: format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht - te registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende - organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden - aan documenten die van of naar andere personen ontvangen of verzonden - zijn waarbij die personen niet deel uit maken van de behandeling van de - zaak waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht te\ + \ registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende\ + \ organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden\ + \ aan documenten die van of naar andere personen ontvangen of verzonden\ + \ zijn waarbij die personen niet deel uit maken van de behandeling van\ + \ de zaak waarin het document een rol speelt." title: ontvangstdatum verzenddatum: type: string format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze - op het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als - uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk - inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan - documenten die van of naar andere personen ontvangen of verzonden zijn - waarbij die personen niet deel uit maken van de behandeling van de zaak - waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze op\ + \ het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als\ + \ uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk\ + \ inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan\ + \ documenten die van of naar andere personen ontvangen of verzonden zijn\ + \ waarbij die personen niet deel uit maken van de behandeling van de zaak\ + \ waarin het document een rol speelt." title: verzenddatum indicatieGebruiksrecht: type: boolean @@ -6627,7 +6832,7 @@ components: title: verschijningsvorm ondertekening: allOf: - - $ref: "#/components/schemas/Ondertekening" + - $ref: "#/components/schemas/OndertekeningRequest" nullable: true description: Aanduiding van de rechtskracht van een informatieobject. Mag @@ -6636,7 +6841,7 @@ components: title: ondertekening integriteit: allOf: - - $ref: "#/components/schemas/Integriteit" + - $ref: "#/components/schemas/IntegriteitRequest" nullable: true description: Uitdrukking van mate van volledigheid en onbeschadigd zijn @@ -6645,669 +6850,449 @@ components: informatieobjecttype: type: string format: uri + minLength: 1 description: URL-referentie naar het INFORMATIEOBJECTTYPE (in de Catalogi API). title: informatieobjecttype maxLength: 200 - locked: - type: boolean - readOnly: true - description: - Geeft aan of het document gelocked is. Alleen als een document - gelocked is, mogen er aanpassingen gemaakt worden. - title: locked - bestandsdelen: + trefwoorden: type: array items: - $ref: "#/components/schemas/BestandsDeel" - readOnly: true - title: bestandsdelen + type: string + minLength: 1 + maxLength: 100 + nullable: true + description: Een lijst van trefwoorden gescheiden door comma's. + title: trefwoorden + inhoudIsVervallen: + type: boolean + nullable: true + description: + Geeft aan of de inhoud van het informatieobject vervallen (dus + niet langer geldig) is. + title: inhoud is vervallen + lock: + type: string + writeOnly: true + minLength: 1 + description: + Tijdens het updaten van een document (PATCH, PUT) moet het + `lock` veld opgegeven worden. Bij het aanmaken (POST) mag het geen waarde + hebben. + title: lock required: - auteur - - beginRegistratie - - bestandsdelen - bronorganisatie - creatiedatum - informatieobjecttype - - locked + - lock - taal - titel - - url - - versie - EnkelvoudigInformatieObjectWithLockRequest: + FieldValidationError: type: object - description: - "This serializer class is used by EnkelvoudigInformatieObjectViewSet - for - - update and partial_update operations" + description: Formaat van validatiefouten. properties: - identificatie: + name: + type: string + description: Naam van het veld met ongeldige gegevens + title: name + code: + type: string + description: Systeemcode die het type fout aangeeft + title: code + reason: + type: string + description: Uitleg wat er precies fout is met de gegevens + title: reason + required: + - code + - name + - reason + Fout: + type: object + description: Formaat van HTTP 4xx en 5xx fouten. + properties: + type: + type: string + description: URI referentie naar het type fout, bedoeld voor developers + title: type + code: + type: string + description: Systeemcode die het type fout aangeeft + title: code + title: + type: string + description: Generieke titel voor het type fout + title: title + status: + type: integer + description: De HTTP status code + title: status + detail: + type: string + description: Extra informatie bij de fout, indien beschikbaar + title: detail + instance: type: string description: - Een binnen een gegeven context ondubbelzinnige referentie naar - het INFORMATIEOBJECT. - title: identificatie - maxLength: 40 - bronorganisatie: + URI met referentie naar dit specifiek voorkomen van de fout. + Deze kan gebruikt worden in combinatie met server logs, bijvoorbeeld. + title: instance + required: + - code + - detail + - instance + - status + - title + Gebruiksrechten: + type: object + properties: + url: type: string + format: uri + readOnly: true + title: url + description: + URL-referentie naar dit object. Dit is de unieke identificatie + en locatie van dit object. minLength: 1 + maxLength: 1000 + informatieobject: + type: string + format: uri + description: URL-referentie naar het INFORMATIEOBJECT. + title: informatieobject + startdatum: + type: string + format: date-time description: - "Het RSIN van de Niet-natuurlijk persoon zijnde de organisatie\ - \ die het informatieobject heeft gecre\xEBerd of heeft ontvangen en als\ - \ eerste in een samenwerkingsketen heeft vastgelegd." - title: bronorganisatie - maxLength: 9 - creatiedatum: + Begindatum van de periode waarin de gebruiksrechtvoorwaarden + van toepassing zijn. Doorgaans is de datum van creatie van het informatieobject + de startdatum. + title: startdatum + einddatum: type: string - format: date - description: Een datum of een gebeurtenis in de levenscyclus van het INFORMATIEOBJECT. - title: creatiedatum - titel: + format: date-time + nullable: true + title: Startdatum + description: + Einddatum van de periode waarin de gebruiksrechtvoorwaarden + van toepassing zijn. + omschrijvingVoorwaarden: + type: string + description: + Omschrijving van de van toepassing zijnde voorwaarden aan het + gebruik anders dan raadpleging + title: omschrijving voorwaarden + required: + - informatieobject + - omschrijvingVoorwaarden + - startdatum + - url + GebruiksrechtenRequest: + type: object + properties: + informatieobject: + type: string + format: uri + description: URL-referentie naar het INFORMATIEOBJECT. + title: informatieobject + startdatum: + type: string + format: date-time + description: + Begindatum van de periode waarin de gebruiksrechtvoorwaarden + van toepassing zijn. Doorgaans is de datum van creatie van het informatieobject + de startdatum. + title: startdatum + einddatum: + type: string + format: date-time + nullable: true + title: Startdatum + description: + Einddatum van de periode waarin de gebruiksrechtvoorwaarden + van toepassing zijn. + omschrijvingVoorwaarden: type: string minLength: 1 - description: De naam waaronder het INFORMATIEOBJECT formeel bekend is. - title: titel - maxLength: 200 - vertrouwelijkheidaanduiding: description: - "Aanduiding van de mate waarin het INFORMATIEOBJECT voor de - openbaarheid bestemd is. + Omschrijving van de van toepassing zijnde voorwaarden aan het + gebruik anders dan raadpleging + title: omschrijving voorwaarden + required: + - informatieobject + - omschrijvingVoorwaarden + - startdatum + Integriteit: + type: object + description: + Uitdrukking van mate van volledigheid en onbeschadigd zijn van + digitaal bestand. + properties: + algoritme: + allOf: + - $ref: "#/components/schemas/AlgoritmeEnum" + description: + "Aanduiding van algoritme, gebruikt om de checksum te maken. Uitleg bij mogelijke waarden: - * `openbaar` - Openbaar + * `crc_16` - CRC-16 - * `beperkt_openbaar` - Beperkt openbaar + * `crc_32` - CRC-32 - * `intern` - Intern + * `crc_64` - CRC-64 - * `zaakvertrouwelijk` - Zaakvertrouwelijk + * `fletcher_4` - Fletcher-4 - * `vertrouwelijk` - Vertrouwelijk + * `fletcher_8` - Fletcher-8 - * `confidentieel` - Confidentieel + * `fletcher_16` - Fletcher-16 - * `geheim` - Geheim + * `fletcher_32` - Fletcher-32 - * `zeer_geheim` - Zeer geheim" - title: vertrouwelijkheidaanduiding - oneOf: - - $ref: "#/components/schemas/VertrouwelijkheidaanduidingEnum" - - $ref: "#/components/schemas/BlankEnum" - auteur: + * `hmac` - HMAC + + * `md5` - MD5 + + * `sha_1` - SHA-1 + + * `sha_256` - SHA-256 + + * `sha_512` - SHA-512 + + * `sha_3` - SHA-3" + title: integriteit algoritme + waarde: type: string - minLength: 1 - description: - "De persoon of organisatie die in de eerste plaats verantwoordelijk\ - \ is voor het cre\xEBren van de inhoud van het INFORMATIEOBJECT." - title: auteur - maxLength: 200 - status: + description: De waarde van de checksum. + title: integriteit waarde + maxLength: 128 + datum: + type: string + format: date + description: Datum waarop de checksum is gemaakt. + title: integriteit datum + required: + - algoritme + - datum + - waarde + nullable: true + IntegriteitRequest: + type: object + description: + Uitdrukking van mate van volledigheid en onbeschadigd zijn van + digitaal bestand. + properties: + algoritme: + allOf: + - $ref: "#/components/schemas/AlgoritmeEnum" description: - "Aanduiding van de stand van zaken van een INFORMATIEOBJECT. - De waarden 'in bewerking' en 'ter vaststelling' komen niet voor als - het attribuut `ontvangstdatum` van een waarde is voorzien. Wijziging van - de Status in 'gearchiveerd' impliceert dat het informatieobject een - duurzaam, niet-wijzigbaar Formaat dient te hebben. + "Aanduiding van algoritme, gebruikt om de checksum te maken. Uitleg bij mogelijke waarden: - * `in_bewerking` - (In bewerking) Aan het informatieobject wordt nog gewerkt. + * `crc_16` - CRC-16 - * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar - moet nog vastgesteld worden. + * `crc_32` - CRC-32 - * `definitief` - (Definitief) Informatieobject door bevoegd iets of iemand - vastgesteld dan wel ontvangen. + * `crc_64` - CRC-64 - * `gearchiveerd` - (Gearchiveerd) Informatieobject duurzaam bewaarbaar - gemaakt; een gearchiveerd informatie-element." - title: status - oneOf: - - $ref: "#/components/schemas/StatusEnum" - - $ref: "#/components/schemas/BlankEnum" - formaat: - type: string - description: - 'Het "Media Type" (voorheen "MIME type") voor de wijze waaropde - inhoud van het INFORMATIEOBJECT is vastgelegd in een computerbestand. - Voorbeeld: `application/msword`. Zie: https://www.iana.org/assignments/media-types/media-types.xhtml' - title: formaat - maxLength: 255 - taal: + * `fletcher_4` - Fletcher-4 + + * `fletcher_8` - Fletcher-8 + + * `fletcher_16` - Fletcher-16 + + * `fletcher_32` - Fletcher-32 + + * `hmac` - HMAC + + * `md5` - MD5 + + * `sha_1` - SHA-1 + + * `sha_256` - SHA-256 + + * `sha_512` - SHA-512 + + * `sha_3` - SHA-3" + title: integriteit algoritme + waarde: type: string - minLength: 3 - description: - "Een ISO 639-2/B taalcode waarin de inhoud van het INFORMATIEOBJECT - is vastgelegd. Voorbeeld: `dut`. Zie: https://www.iso.org/standard/4767.html" - title: taal - maxLength: 3 - bestandsnaam: + minLength: 1 + description: De waarde van de checksum. + title: integriteit waarde + maxLength: 128 + datum: type: string - description: - De naam van het fysieke bestand waarin de inhoud van het informatieobject - is vastgelegd, inclusief extensie. - title: bestandsnaam - maxLength: 255 - inhoud: + format: date + description: Datum waarop de checksum is gemaakt. + title: integriteit datum + required: + - algoritme + - datum + - waarde + nullable: true + LockEnkelvoudigInformatieObject: + type: object + description: + "Serializer for the lock action of EnkelvoudigInformatieObjectCanonical + + model" + properties: + lock: type: string - format: byte - description: "Binaire inhoud, in base64 ge\xEBncodeerd." - nullable: true - title: inhoud - bestandsomvang: - type: integer - maximum: 9223372036854775807 - minimum: 0 - format: int64 - nullable: true - description: Aantal bytes dat de inhoud van INFORMATIEOBJECT in beslag neemt. - title: bestandsomvang - link: + readOnly: true + description: Hash string, wordt gebruikt als ID voor de lock + title: lock + required: + - lock + ObjectInformatieObject: + type: object + properties: + url: type: string format: uri + readOnly: true + title: url description: - De URL waarmee de inhoud van het INFORMATIEOBJECT op te vragen - is. - title: link - maxLength: 200 - beschrijving: - type: string - description: Een generieke beschrijving van de inhoud van het INFORMATIEOBJECT. - title: beschrijving + URL-referentie naar dit object. Dit is de unieke identificatie + en locatie van dit object. + minLength: 1 maxLength: 1000 - ontvangstdatum: - type: string - format: date - nullable: true - description: - De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht - te registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende - organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden - aan documenten die van of naar andere personen ontvangen of verzonden - zijn waarbij die personen niet deel uit maken van de behandeling van de - zaak waarin het document een rol speelt. - title: ontvangstdatum - verzenddatum: + informatieobject: type: string - format: date - nullable: true - description: - De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze - op het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als - uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk - inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan - documenten die van of naar andere personen ontvangen of verzonden zijn - waarbij die personen niet deel uit maken van de behandeling van de zaak - waarin het document een rol speelt. - title: verzenddatum - indicatieGebruiksrecht: - type: boolean - nullable: true - description: - Indicatie of er beperkingen gelden aangaande het gebruik van - het informatieobject anders dan raadpleging. Dit veld mag `null` zijn - om aan te geven dat de indicatie nog niet bekend is. Als de indicatie - gezet is, dan kan je de gebruiksrechten die van toepassing zijn raadplegen - via de GEBRUIKSRECHTen resource. - title: indicatie gebruiksrecht - verschijningsvorm: + format: uri + description: URL-referentie naar het INFORMATIEOBJECT. + title: informatieobject + object: type: string - description: "De essenti\xEBle opmaakaspecten van een INFORMATIEOBJECT." - title: verschijningsvorm - ondertekening: - allOf: - - $ref: "#/components/schemas/OndertekeningRequest" - nullable: true + format: uri description: - Aanduiding van de rechtskracht van een informatieobject. Mag - niet van een waarde zijn voorzien als de `status` de waarde 'in bewerking' - of 'ter vaststelling' heeft. - title: ondertekening - integriteit: + URL-referentie naar het gerelateerde OBJECT (in deze of een + andere API). + title: object + maxLength: 1000 + objectType: allOf: - - $ref: "#/components/schemas/IntegriteitRequest" - nullable: true - description: - Uitdrukking van mate van volledigheid en onbeschadigd zijn - van digitaal bestand. - title: integriteit - informatieobjecttype: + - $ref: "#/components/schemas/ObjectTypeEnum" + title: Objecttype + description: "Het type van het gerelateerde OBJECT. + + + Uitleg bij mogelijke waarden: + + + * `besluit` - Besluit + + * `zaak` - Zaak" + required: + - informatieobject + - object + - objectType + - url + ObjectInformatieObjectRequest: + type: object + properties: + informatieobject: + type: string + format: uri + description: URL-referentie naar het INFORMATIEOBJECT. + title: informatieobject + object: type: string format: uri minLength: 1 description: - URL-referentie naar het INFORMATIEOBJECTTYPE (in de Catalogi - API). - title: informatieobjecttype - maxLength: 200 - lock: - type: string - writeOnly: true - minLength: 1 - description: - Tijdens het updaten van een document (PATCH, PUT) moet het - `lock` veld opgegeven worden. Bij het aanmaken (POST) mag het geen waarde - hebben. - title: lock - required: - - auteur - - bronorganisatie - - creatiedatum - - informatieobjecttype - - lock - - taal - - titel - FieldValidationError: - type: object - description: Formaat van validatiefouten. - properties: - name: - type: string - description: Naam van het veld met ongeldige gegevens - title: name - code: - type: string - description: Systeemcode die het type fout aangeeft - title: code - reason: - type: string - description: Uitleg wat er precies fout is met de gegevens - title: reason - required: - - code - - name - - reason - Fout: - type: object - description: Formaat van HTTP 4xx en 5xx fouten. - properties: - type: - type: string - description: URI referentie naar het type fout, bedoeld voor developers - title: type - code: - type: string - description: Systeemcode die het type fout aangeeft - title: code - title: - type: string - description: Generieke titel voor het type fout - title: title - status: - type: integer - description: De HTTP status code - title: status - detail: - type: string - description: Extra informatie bij de fout, indien beschikbaar - title: detail - instance: - type: string - description: - URI met referentie naar dit specifiek voorkomen van de fout. - Deze kan gebruikt worden in combinatie met server logs, bijvoorbeeld. - title: instance - required: - - code - - detail - - instance - - status - - title - Gebruiksrechten: - type: object - properties: - url: - type: string - format: uri - readOnly: true - title: url - description: - URL-referentie naar dit object. Dit is de unieke identificatie - en locatie van dit object. - minLength: 1 + URL-referentie naar het gerelateerde OBJECT (in deze of een + andere API). + title: object maxLength: 1000 - informatieobject: - type: string - format: uri - description: URL-referentie naar het INFORMATIEOBJECT. - title: informatieobject - startdatum: - type: string - format: date-time - description: - Begindatum van de periode waarin de gebruiksrechtvoorwaarden - van toepassing zijn. Doorgaans is de datum van creatie van het informatieobject - de startdatum. - title: startdatum - einddatum: - type: string - format: date-time - nullable: true - title: Startdatum - description: - Einddatum van de periode waarin de gebruiksrechtvoorwaarden - van toepassing zijn. - omschrijvingVoorwaarden: - type: string - description: - Omschrijving van de van toepassing zijnde voorwaarden aan het - gebruik anders dan raadpleging - title: omschrijving voorwaarden - required: - - informatieobject - - omschrijvingVoorwaarden - - startdatum - - url - GebruiksrechtenRequest: - type: object - properties: - informatieobject: - type: string - format: uri - description: URL-referentie naar het INFORMATIEOBJECT. - title: informatieobject - startdatum: - type: string - format: date-time - description: - Begindatum van de periode waarin de gebruiksrechtvoorwaarden - van toepassing zijn. Doorgaans is de datum van creatie van het informatieobject - de startdatum. - title: startdatum - einddatum: - type: string - format: date-time - nullable: true - title: Startdatum - description: - Einddatum van de periode waarin de gebruiksrechtvoorwaarden - van toepassing zijn. - omschrijvingVoorwaarden: - type: string - minLength: 1 - description: - Omschrijving van de van toepassing zijnde voorwaarden aan het - gebruik anders dan raadpleging - title: omschrijving voorwaarden + objectType: + allOf: + - $ref: "#/components/schemas/ObjectTypeEnum" + title: Objecttype + description: "Het type van het gerelateerde OBJECT. + + + Uitleg bij mogelijke waarden: + + + * `besluit` - Besluit + + * `zaak` - Zaak" required: - informatieobject - - omschrijvingVoorwaarden - - startdatum - Integriteit: + - object + - objectType + ObjectTypeEnum: + enum: + - besluit + - zaak + - verzoek + type: string + Ondertekening: type: object description: - Uitdrukking van mate van volledigheid en onbeschadigd zijn van - digitaal bestand. + Aanduiding van de rechtskracht van een informatieobject. Mag niet + van een waarde zijn voorzien als de `status` de waarde 'in bewerking' of 'ter + vaststelling' heeft. properties: - algoritme: + soort: allOf: - - $ref: "#/components/schemas/AlgoritmeEnum" + - $ref: "#/components/schemas/SoortEnum" + title: Ondertekeningsoort description: - "Aanduiding van algoritme, gebruikt om de checksum te maken. + "Aanduiding van de wijze van ondertekening van het INFORMATIEOBJECT Uitleg bij mogelijke waarden: - * `crc_16` - CRC-16 - - * `crc_32` - CRC-32 - - * `crc_64` - CRC-64 - - * `fletcher_4` - Fletcher-4 - - * `fletcher_8` - Fletcher-8 - - * `fletcher_16` - Fletcher-16 - - * `fletcher_32` - Fletcher-32 - - * `hmac` - HMAC - - * `md5` - MD5 - - * `sha_1` - SHA-1 - - * `sha_256` - SHA-256 + * `analoog` - Analoog - * `sha_512` - SHA-512 + * `digitaal` - Digitaal - * `sha_3` - SHA-3" - title: integriteit algoritme - waarde: - type: string - description: De waarde van de checksum. - title: integriteit waarde - maxLength: 128 + * `pki` - PKI" datum: type: string format: date - description: Datum waarop de checksum is gemaakt. - title: integriteit datum + title: Ondertekeningdatum + description: + De datum waarop de ondertekening van het INFORMATIEOBJECT heeft + plaatsgevonden. required: - - algoritme - datum - - waarde + - soort nullable: true - IntegriteitRequest: + OndertekeningRequest: type: object description: - Uitdrukking van mate van volledigheid en onbeschadigd zijn van - digitaal bestand. + Aanduiding van de rechtskracht van een informatieobject. Mag niet + van een waarde zijn voorzien als de `status` de waarde 'in bewerking' of 'ter + vaststelling' heeft. properties: - algoritme: + soort: allOf: - - $ref: "#/components/schemas/AlgoritmeEnum" + - $ref: "#/components/schemas/SoortEnum" + title: Ondertekeningsoort description: - "Aanduiding van algoritme, gebruikt om de checksum te maken. + "Aanduiding van de wijze van ondertekening van het INFORMATIEOBJECT Uitleg bij mogelijke waarden: - * `crc_16` - CRC-16 - - * `crc_32` - CRC-32 - - * `crc_64` - CRC-64 + * `analoog` - Analoog - * `fletcher_4` - Fletcher-4 - - * `fletcher_8` - Fletcher-8 - - * `fletcher_16` - Fletcher-16 - - * `fletcher_32` - Fletcher-32 - - * `hmac` - HMAC - - * `md5` - MD5 - - * `sha_1` - SHA-1 - - * `sha_256` - SHA-256 - - * `sha_512` - SHA-512 - - * `sha_3` - SHA-3" - title: integriteit algoritme - waarde: - type: string - minLength: 1 - description: De waarde van de checksum. - title: integriteit waarde - maxLength: 128 - datum: - type: string - format: date - description: Datum waarop de checksum is gemaakt. - title: integriteit datum - required: - - algoritme - - datum - - waarde - nullable: true - LockEnkelvoudigInformatieObject: - type: object - description: - "Serializer for the lock action of EnkelvoudigInformatieObjectCanonical - - model" - properties: - lock: - type: string - readOnly: true - description: Hash string, wordt gebruikt als ID voor de lock - title: lock - required: - - lock - ObjectInformatieObject: - type: object - properties: - url: - type: string - format: uri - readOnly: true - title: url - description: - URL-referentie naar dit object. Dit is de unieke identificatie - en locatie van dit object. - minLength: 1 - maxLength: 1000 - informatieobject: - type: string - format: uri - description: URL-referentie naar het INFORMATIEOBJECT. - title: informatieobject - object: - type: string - format: uri - description: - URL-referentie naar het gerelateerde OBJECT (in deze of een - andere API). - title: object - maxLength: 1000 - objectType: - allOf: - - $ref: "#/components/schemas/ObjectTypeEnum" - title: Objecttype - description: "Het type van het gerelateerde OBJECT. - - - Uitleg bij mogelijke waarden: - - - * `besluit` - Besluit - - * `zaak` - Zaak" - required: - - informatieobject - - object - - objectType - - url - ObjectInformatieObjectRequest: - type: object - properties: - informatieobject: - type: string - format: uri - description: URL-referentie naar het INFORMATIEOBJECT. - title: informatieobject - object: - type: string - format: uri - minLength: 1 - description: - URL-referentie naar het gerelateerde OBJECT (in deze of een - andere API). - title: object - maxLength: 1000 - objectType: - allOf: - - $ref: "#/components/schemas/ObjectTypeEnum" - title: Objecttype - description: "Het type van het gerelateerde OBJECT. - - - Uitleg bij mogelijke waarden: - - - * `besluit` - Besluit - - * `zaak` - Zaak" - required: - - informatieobject - - object - - objectType - ObjectTypeEnum: - enum: - - besluit - - zaak - - verzoek - type: string - Ondertekening: - type: object - description: - Aanduiding van de rechtskracht van een informatieobject. Mag niet - van een waarde zijn voorzien als de `status` de waarde 'in bewerking' of 'ter - vaststelling' heeft. - properties: - soort: - allOf: - - $ref: "#/components/schemas/SoortEnum" - title: Ondertekeningsoort - description: - "Aanduiding van de wijze van ondertekening van het INFORMATIEOBJECT - - - Uitleg bij mogelijke waarden: - - - * `analoog` - Analoog - - * `digitaal` - Digitaal - - * `pki` - PKI" - datum: - type: string - format: date - title: Ondertekeningdatum - description: - De datum waarop de ondertekening van het INFORMATIEOBJECT heeft - plaatsgevonden. - required: - - datum - - soort - nullable: true - OndertekeningRequest: - type: object - description: - Aanduiding van de rechtskracht van een informatieobject. Mag niet - van een waarde zijn voorzien als de `status` de waarde 'in bewerking' of 'ter - vaststelling' heeft. - properties: - soort: - allOf: - - $ref: "#/components/schemas/SoortEnum" - title: Ondertekeningsoort - description: - "Aanduiding van de wijze van ondertekening van het INFORMATIEOBJECT - - - Uitleg bij mogelijke waarden: - - - * `analoog` - Analoog - - * `digitaal` - Digitaal + * `digitaal` - Digitaal * `pki` - PKI" datum: @@ -7378,7 +7363,467 @@ components: maxLength: 40 bronorganisatie: type: string - minLength: 1 + minLength: 1 + description: + "Het RSIN van de Niet-natuurlijk persoon zijnde de organisatie\ + \ die het informatieobject heeft gecre\xEBerd of heeft ontvangen en als\ + \ eerste in een samenwerkingsketen heeft vastgelegd." + title: bronorganisatie + maxLength: 9 + creatiedatum: + type: string + format: date + description: Een datum of een gebeurtenis in de levenscyclus van het INFORMATIEOBJECT. + title: creatiedatum + titel: + type: string + minLength: 1 + description: De naam waaronder het INFORMATIEOBJECT formeel bekend is. + title: titel + maxLength: 200 + vertrouwelijkheidaanduiding: + description: + "Aanduiding van de mate waarin het INFORMATIEOBJECT voor de + openbaarheid bestemd is. + + + Uitleg bij mogelijke waarden: + + + * `openbaar` - Openbaar + + * `beperkt_openbaar` - Beperkt openbaar + + * `intern` - Intern + + * `zaakvertrouwelijk` - Zaakvertrouwelijk + + * `vertrouwelijk` - Vertrouwelijk + + * `confidentieel` - Confidentieel + + * `geheim` - Geheim + + * `zeer_geheim` - Zeer geheim" + title: vertrouwelijkheidaanduiding + oneOf: + - $ref: "#/components/schemas/VertrouwelijkheidaanduidingEnum" + - $ref: "#/components/schemas/BlankEnum" + auteur: + type: string + minLength: 1 + description: + "De persoon of organisatie die in de eerste plaats verantwoordelijk\ + \ is voor het cre\xEBren van de inhoud van het INFORMATIEOBJECT." + title: auteur + maxLength: 200 + status: + description: + "Aanduiding van de stand van zaken van een INFORMATIEOBJECT. + De waarden 'in bewerking' en 'ter vaststelling' komen niet voor als + het attribuut `ontvangstdatum` van een waarde is voorzien. Wijziging van + de Status in 'gearchiveerd' impliceert dat het informatieobject een + duurzaam, niet-wijzigbaar Formaat dient te hebben. + + + Uitleg bij mogelijke waarden: + + + * `in_bewerking` - (In bewerking) Aan het informatieobject wordt nog gewerkt. + + * `concept` - (Concept) Het document is inhoudelijk klaar om voorgelegd + teworden aan anderen en zo nodig aangepast te worden opbasis van commentaar.. + + * `definitief` - (Definitief) Informatieobject door bevoegd iets of iemand + vastgesteld dan wel ontvangen. + + * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar + moet nog vastgesteld worden. + + * `vastgesteld` - (Vastgesteld) Het besluitvormingstraject is afgerond. + + * `gearchiveerd` - (Gearchiveerd) Informatieobject duurzaam bewaarbaar + gemaakt; een gearchiveerd informatie-element." + title: status + oneOf: + - $ref: "#/components/schemas/StatusEnum" + - $ref: "#/components/schemas/BlankEnum" + formaat: + type: string + description: + 'Het "Media Type" (voorheen "MIME type") voor de wijze waaropde + inhoud van het INFORMATIEOBJECT is vastgelegd in een computerbestand. + Voorbeeld: `application/msword`. Zie: https://www.iana.org/assignments/media-types/media-types.xhtml' + title: formaat + maxLength: 255 + taal: + type: string + minLength: 3 + description: + "Een ISO 639-2/B taalcode waarin de inhoud van het INFORMATIEOBJECT + is vastgelegd. Voorbeeld: `dut`. Zie: https://www.iso.org/standard/4767.html" + title: taal + maxLength: 3 + bestandsnaam: + type: string + description: + De naam van het fysieke bestand waarin de inhoud van het informatieobject + is vastgelegd, inclusief extensie. + title: bestandsnaam + maxLength: 255 + inhoud: + type: string + format: byte + description: "Binaire inhoud, in base64 ge\xEBncodeerd." + nullable: true + title: inhoud + bestandsomvang: + type: integer + maximum: 9223372036854775807 + minimum: 0 + format: int64 + nullable: true + description: Aantal bytes dat de inhoud van INFORMATIEOBJECT in beslag neemt. + title: bestandsomvang + link: + type: string + format: uri + description: + De URL waarmee de inhoud van het INFORMATIEOBJECT op te vragen + is. + title: link + maxLength: 200 + beschrijving: + type: string + description: Een generieke beschrijving van de inhoud van het INFORMATIEOBJECT. + title: beschrijving + maxLength: 1000 + ontvangstdatum: + type: string + format: date + nullable: true + description: + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht te\ + \ registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende\ + \ organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden\ + \ aan documenten die van of naar andere personen ontvangen of verzonden\ + \ zijn waarbij die personen niet deel uit maken van de behandeling van\ + \ de zaak waarin het document een rol speelt." + title: ontvangstdatum + verzenddatum: + type: string + format: date + nullable: true + description: + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze op\ + \ het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als\ + \ uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk\ + \ inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan\ + \ documenten die van of naar andere personen ontvangen of verzonden zijn\ + \ waarbij die personen niet deel uit maken van de behandeling van de zaak\ + \ waarin het document een rol speelt." + title: verzenddatum + indicatieGebruiksrecht: + type: boolean + nullable: true + description: + Indicatie of er beperkingen gelden aangaande het gebruik van + het informatieobject anders dan raadpleging. Dit veld mag `null` zijn + om aan te geven dat de indicatie nog niet bekend is. Als de indicatie + gezet is, dan kan je de gebruiksrechten die van toepassing zijn raadplegen + via de GEBRUIKSRECHTen resource. + title: indicatie gebruiksrecht + verschijningsvorm: + type: string + description: "De essenti\xEBle opmaakaspecten van een INFORMATIEOBJECT." + title: verschijningsvorm + ondertekening: + allOf: + - $ref: "#/components/schemas/OndertekeningRequest" + nullable: true + description: + Aanduiding van de rechtskracht van een informatieobject. Mag + niet van een waarde zijn voorzien als de `status` de waarde 'in bewerking' + of 'ter vaststelling' heeft. + title: ondertekening + integriteit: + allOf: + - $ref: "#/components/schemas/IntegriteitRequest" + nullable: true + description: + Uitdrukking van mate van volledigheid en onbeschadigd zijn + van digitaal bestand. + title: integriteit + informatieobjecttype: + type: string + format: uri + minLength: 1 + description: + URL-referentie naar het INFORMATIEOBJECTTYPE (in de Catalogi + API). + title: informatieobjecttype + maxLength: 200 + trefwoorden: + type: array + items: + type: string + minLength: 1 + maxLength: 100 + nullable: true + description: Een lijst van trefwoorden gescheiden door comma's. + title: trefwoorden + inhoudIsVervallen: + type: boolean + nullable: true + description: + Geeft aan of de inhoud van het informatieobject vervallen (dus + niet langer geldig) is. + title: inhoud is vervallen + lock: + type: string + writeOnly: true + minLength: 1 + description: + Tijdens het updaten van een document (PATCH, PUT) moet het + `lock` veld opgegeven worden. Bij het aanmaken (POST) mag het geen waarde + hebben. + title: lock + PatchedGebruiksrechtenRequest: + type: object + properties: + informatieobject: + type: string + format: uri + description: URL-referentie naar het INFORMATIEOBJECT. + title: informatieobject + startdatum: + type: string + format: date-time + description: + Begindatum van de periode waarin de gebruiksrechtvoorwaarden + van toepassing zijn. Doorgaans is de datum van creatie van het informatieobject + de startdatum. + title: startdatum + einddatum: + type: string + format: date-time + nullable: true + title: Startdatum + description: + Einddatum van de periode waarin de gebruiksrechtvoorwaarden + van toepassing zijn. + omschrijvingVoorwaarden: + type: string + minLength: 1 + description: + Omschrijving van de van toepassing zijnde voorwaarden aan het + gebruik anders dan raadpleging + title: omschrijving voorwaarden + PatchedVerzendingRequest: + type: object + description: "Set gegevensgroepdata from validated nested data. + + + Usage: include the mixin on the ModelSerializer that has gegevensgroepen." + properties: + betrokkene: + type: string + format: uri + minLength: 1 + description: + URL-referentie naar de betrokkene waarvan het informatieobject + is ontvangen of waaraan dit is verzonden. + title: betrokkene + maxLength: 200 + informatieobject: + type: string + format: uri + description: + URL-referentie naar het informatieobject dat is ontvangen of + verzonden. + title: informatieobject + aardRelatie: + allOf: + - $ref: "#/components/schemas/AardRelatieEnum" + description: + Omschrijving van de aard van de relatie van de BETROKKENE tot + het INFORMATIEOBJECT. + title: aard relatie + toelichting: + type: string + description: Verduidelijking van de afzender- of geadresseerde-relatie. + title: toelichting + maxLength: 200 + ontvangstdatum: + type: string + format: date + nullable: true + description: + De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht + te registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende + organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden + aan documenten die van of naar andere personen ontvangen of verzonden + zijn waarbij die personen niet deel uit maken van de behandeling van de + zaak waarin het document een rol speelt. Vervangt het gelijknamige attribuut + uit Informatieobject. Verplicht gevuld wanneer aardRelatie de waarde 'afzender' + heeft. + title: ontvangstdatum + verzenddatum: + type: string + format: date + nullable: true + description: + De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze + op het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als + uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk + inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan + documenten die van of naar andere personen ontvangen of verzonden zijn + waarbij die personen niet deel uit maken van de behandeling van de zaak + waarin het document een rol speelt. Vervangt het gelijknamige attribuut + uit Informatieobject. Verplicht gevuld wanneer aardRelatie de waarde 'geadresseerde' + heeft. + title: verzenddatum + contactPersoon: + type: string + format: uri + minLength: 1 + title: Contactpersoon + description: + URL-referentie naar de persoon die als aanspreekpunt fungeert + voor de BETROKKENE inzake het ontvangen of verzonden INFORMATIEOBJECT. + maxLength: 1000 + contactpersoonnaam: + type: string + description: + De opgemaakte naam van de persoon die als aanspreekpunt fungeert + voorde BETROKKENE inzake het ontvangen of verzonden INFORMATIEOBJECT. + title: contactpersoonnaam + maxLength: 40 + binnenlandsCorrespondentieadres: + allOf: + - $ref: "#/components/schemas/BinnenlandsCorrespondentieadresVerzendingRequest" + nullable: true + description: + Het correspondentieadres, betreffende een adresseerbaar object, + van de BETROKKENE, zijnde afzender of geadresseerde, zoals vermeld in + het ontvangen of verzonden INFORMATIEOBJECT indien dat afwijkt van het + reguliere binnenlandse correspondentieadres van BETROKKENE. + title: binnenlandsCorrespondentieadres + buitenlandsCorrespondentieadres: + allOf: + - $ref: "#/components/schemas/BuitenlandsCorrespondentieadresVerzendingRequest" + nullable: true + description: + De gegevens van het adres in het buitenland van BETROKKENE, + zijnde afzender of geadresseerde, zoals vermeld in het ontvangen of verzonden + INFORMATIEOBJECT en dat afwijkt van de reguliere correspondentiegegevens + van BETROKKENE. + title: buitenlandsCorrespondentieadres + correspondentiePostadres: + allOf: + - $ref: "#/components/schemas/BuitenlandsCorrespondentiepostadresVerzendingRequest" + nullable: true + description: + De gegevens die tezamen een postbusadres of antwoordnummeradres + vormen van BETROKKENE, zijnde afzender of geadresseerde, zoals vermeld + in het ontvangen of verzonden INFORMATIEOBJECT en dat afwijkt van de reguliere + correspondentiegegevens van BETROKKENE. + title: correspondentiePostadres + faxnummer: + type: string + nullable: true + description: faxnummer van de ontvanger of afzender. + title: faxnummer + maxLength: 15 + emailadres: + type: string + nullable: true + description: emailadres van de ontvanger of afzender. + title: emailadres + maxLength: 100 + mijnOverheid: + type: boolean + description: + is het informatieobject verzonden via mijnOverheid naar de + ontvanger. + title: mijn overheid + telefoonnummer: + type: string + nullable: true + description: telefoonnummer van de ontvanger of afzender. + title: telefoonnummer + maxLength: 15 + PostadresTypeEnum: + enum: + - antwoordnummer + - postbusnummer + type: string + SchemaBestandsDeel: + type: object + properties: + url: + type: string + format: uri + readOnly: true + title: url + description: + URL-referentie naar dit object. Dit is de unieke identificatie + en locatie van dit object. + minLength: 1 + maxLength: 1000 + volgnummer: + type: integer + readOnly: true + description: Een volgnummer dat de volgorde van de bestandsdelen aangeeft. + title: volgnummer + omvang: + type: integer + readOnly: true + description: De grootte van dit specifieke bestandsdeel. + title: omvang + voltooid: + type: boolean + readOnly: true + description: + "Indicatie of dit bestandsdeel volledig is geupload. Dat wil + zeggen: het aantal bytes dat staat genoemd bij grootte is daadwerkelijk + ontvangen." + title: voltooid + lock: + type: string + description: Hash string, which represents id of the lock of related informatieobject + title: lock + required: + - lock + - omvang + - url + - volgnummer + - voltooid + SchemaEIO: + type: object + description: Serializer for the EnkelvoudigInformatieObject model + properties: + url: + type: string + format: uri + readOnly: true + title: url + description: + URL-referentie naar dit object. Dit is de unieke identificatie + en locatie van dit object. + minLength: 1 + maxLength: 1000 + identificatie: + type: string + description: + Een binnen een gegeven context ondubbelzinnige referentie naar + het INFORMATIEOBJECT. + title: identificatie + maxLength: 40 + bronorganisatie: + type: string description: "Het RSIN van de Niet-natuurlijk persoon zijnde de organisatie\ \ die het informatieobject heeft gecre\xEBerd of heeft ontvangen en als\ @@ -7392,7 +7837,6 @@ components: title: creatiedatum titel: type: string - minLength: 1 description: De naam waaronder het INFORMATIEOBJECT formeel bekend is. title: titel maxLength: 200 @@ -7426,7 +7870,6 @@ components: - $ref: "#/components/schemas/BlankEnum" auteur: type: string - minLength: 1 description: "De persoon of organisatie die in de eerste plaats verantwoordelijk\ \ is voor het cre\xEBren van de inhoud van het INFORMATIEOBJECT." @@ -7446,12 +7889,17 @@ components: * `in_bewerking` - (In bewerking) Aan het informatieobject wordt nog gewerkt. - * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar - moet nog vastgesteld worden. + * `concept` - (Concept) Het document is inhoudelijk klaar om voorgelegd + teworden aan anderen en zo nodig aangepast te worden opbasis van commentaar.. * `definitief` - (Definitief) Informatieobject door bevoegd iets of iemand vastgesteld dan wel ontvangen. + * `ter_vaststelling` - (Ter vaststelling) Informatieobject gereed maar + moet nog vastgesteld worden. + + * `vastgesteld` - (Vastgesteld) Het besluitvormingstraject is afgerond. + * `gearchiveerd` - (Gearchiveerd) Informatieobject duurzaam bewaarbaar gemaakt; een gearchiveerd informatie-element." title: status @@ -7468,12 +7916,27 @@ components: maxLength: 255 taal: type: string - minLength: 3 description: "Een ISO 639-2/B taalcode waarin de inhoud van het INFORMATIEOBJECT is vastgelegd. Voorbeeld: `dut`. Zie: https://www.iso.org/standard/4767.html" title: taal maxLength: 3 + minLength: 3 + versie: + type: integer + readOnly: true + description: + Het (automatische) versienummer van het INFORMATIEOBJECT. Deze + begint bij 1 als het INFORMATIEOBJECT aangemaakt wordt. + title: versie + beginRegistratie: + type: string + format: date-time + readOnly: true + description: + Een datumtijd in ISO8601 formaat waarop deze versie van het + INFORMATIEOBJECT is aangemaakt of gewijzigd. + title: begin registratie bestandsnaam: type: string description: @@ -7483,8 +7946,8 @@ components: maxLength: 255 inhoud: type: string - format: byte - description: "Binaire inhoud, in base64 ge\xEBncodeerd." + format: uri + description: Download URL van de binaire inhoud. nullable: true title: inhoud bestandsomvang: @@ -7513,25 +7976,27 @@ components: format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht - te registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende - organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden - aan documenten die van of naar andere personen ontvangen of verzonden - zijn waarbij die personen niet deel uit maken van de behandeling van de - zaak waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht te\ + \ registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende\ + \ organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden\ + \ aan documenten die van of naar andere personen ontvangen of verzonden\ + \ zijn waarbij die personen niet deel uit maken van de behandeling van\ + \ de zaak waarin het document een rol speelt." title: ontvangstdatum verzenddatum: type: string format: date nullable: true description: - De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze - op het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als - uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk - inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan - documenten die van of naar andere personen ontvangen of verzonden zijn - waarbij die personen niet deel uit maken van de behandeling van de zaak - waarin het document een rol speelt. + "**DEPRECATED** Dit attribuut is verplaatst naar resource Verzending.\ + \ \n\n De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze op\ + \ het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als\ + \ uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk\ + \ inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan\ + \ documenten die van of naar andere personen ontvangen of verzonden zijn\ + \ waarbij die personen niet deel uit maken van de behandeling van de zaak\ + \ waarin het document een rol speelt." title: verzenddatum indicatieGebruiksrecht: type: boolean @@ -7549,7 +8014,7 @@ components: title: verschijningsvorm ondertekening: allOf: - - $ref: "#/components/schemas/OndertekeningRequest" + - $ref: "#/components/schemas/Ondertekening" nullable: true description: Aanduiding van de rechtskracht van een informatieobject. Mag @@ -7558,7 +8023,7 @@ components: title: ondertekening integriteit: allOf: - - $ref: "#/components/schemas/IntegriteitRequest" + - $ref: "#/components/schemas/Integriteit" nullable: true description: Uitdrukking van mate van volledigheid en onbeschadigd zijn @@ -7567,191 +8032,51 @@ components: informatieobjecttype: type: string format: uri - minLength: 1 description: URL-referentie naar het INFORMATIEOBJECTTYPE (in de Catalogi API). title: informatieobjecttype maxLength: 200 - lock: - type: string - writeOnly: true - minLength: 1 - description: - Tijdens het updaten van een document (PATCH, PUT) moet het - `lock` veld opgegeven worden. Bij het aanmaken (POST) mag het geen waarde - hebben. - title: lock - PatchedGebruiksrechtenRequest: - type: object - properties: - informatieobject: - type: string - format: uri - description: URL-referentie naar het INFORMATIEOBJECT. - title: informatieobject - startdatum: - type: string - format: date-time - description: - Begindatum van de periode waarin de gebruiksrechtvoorwaarden - van toepassing zijn. Doorgaans is de datum van creatie van het informatieobject - de startdatum. - title: startdatum - einddatum: - type: string - format: date-time - nullable: true - title: Startdatum - description: - Einddatum van de periode waarin de gebruiksrechtvoorwaarden - van toepassing zijn. - omschrijvingVoorwaarden: - type: string - minLength: 1 - description: - Omschrijving van de van toepassing zijnde voorwaarden aan het - gebruik anders dan raadpleging - title: omschrijving voorwaarden - PatchedVerzendingRequest: - type: object - description: "Set gegevensgroepdata from validated nested data. - - - Usage: include the mixin on the ModelSerializer that has gegevensgroepen." - properties: - betrokkene: - type: string - format: uri - minLength: 1 - description: - URL-referentie naar de betrokkene waarvan het informatieobject - is ontvangen of waaraan dit is verzonden. - title: betrokkene - maxLength: 200 - informatieobject: - type: string - format: uri - description: - URL-referentie naar het informatieobject dat is ontvangen of - verzonden. - title: informatieobject - aardRelatie: - allOf: - - $ref: "#/components/schemas/AardRelatieEnum" - description: - Omschrijving van de aard van de relatie van de BETROKKENE tot - het INFORMATIEOBJECT. - title: aard relatie - toelichting: - type: string - description: Verduidelijking van de afzender- of geadresseerde-relatie. - title: toelichting - maxLength: 200 - ontvangstdatum: - type: string - format: date - nullable: true - description: - De datum waarop het INFORMATIEOBJECT ontvangen is. Verplicht - te registreren voor INFORMATIEOBJECTen die van buiten de zaakbehandelende - organisatie(s) ontvangen zijn. Ontvangst en verzending is voorbehouden - aan documenten die van of naar andere personen ontvangen of verzonden - zijn waarbij die personen niet deel uit maken van de behandeling van de - zaak waarin het document een rol speelt. Vervangt het gelijknamige attribuut - uit Informatieobject. Verplicht gevuld wanneer aardRelatie de waarde 'afzender' - heeft. - title: ontvangstdatum - verzenddatum: - type: string - format: date - nullable: true - description: - De datum waarop het INFORMATIEOBJECT verzonden is, zoals deze - op het INFORMATIEOBJECT vermeld is. Dit geldt voor zowel inkomende als - uitgaande INFORMATIEOBJECTen. Eenzelfde informatieobject kan niet tegelijk - inkomend en uitgaand zijn. Ontvangst en verzending is voorbehouden aan - documenten die van of naar andere personen ontvangen of verzonden zijn - waarbij die personen niet deel uit maken van de behandeling van de zaak - waarin het document een rol speelt. Vervangt het gelijknamige attribuut - uit Informatieobject. Verplicht gevuld wanneer aardRelatie de waarde 'geadresseerde' - heeft. - title: verzenddatum - contactPersoon: - type: string - format: uri - minLength: 1 - title: Contactpersoon - description: - URL-referentie naar de persoon die als aanspreekpunt fungeert - voor de BETROKKENE inzake het ontvangen of verzonden INFORMATIEOBJECT. - maxLength: 1000 - contactpersoonnaam: - type: string - description: - De opgemaakte naam van de persoon die als aanspreekpunt fungeert - voorde BETROKKENE inzake het ontvangen of verzonden INFORMATIEOBJECT. - title: contactpersoonnaam - maxLength: 40 - binnenlandsCorrespondentieadres: - allOf: - - $ref: "#/components/schemas/BinnenlandsCorrespondentieadresVerzendingRequest" - nullable: true - description: - Het correspondentieadres, betreffende een adresseerbaar object, - van de BETROKKENE, zijnde afzender of geadresseerde, zoals vermeld in - het ontvangen of verzonden INFORMATIEOBJECT indien dat afwijkt van het - reguliere binnenlandse correspondentieadres van BETROKKENE. - title: binnenlandsCorrespondentieadres - buitenlandsCorrespondentieadres: - allOf: - - $ref: "#/components/schemas/BuitenlandsCorrespondentieadresVerzendingRequest" - nullable: true - description: - De gegevens van het adres in het buitenland van BETROKKENE, - zijnde afzender of geadresseerde, zoals vermeld in het ontvangen of verzonden - INFORMATIEOBJECT en dat afwijkt van de reguliere correspondentiegegevens - van BETROKKENE. - title: buitenlandsCorrespondentieadres - correspondentiePostadres: - allOf: - - $ref: "#/components/schemas/BuitenlandsCorrespondentiepostadresVerzendingRequest" - nullable: true + locked: + type: boolean + readOnly: true description: - De gegevens die tezamen een postbusadres of antwoordnummeradres - vormen van BETROKKENE, zijnde afzender of geadresseerde, zoals vermeld - in het ontvangen of verzonden INFORMATIEOBJECT en dat afwijkt van de reguliere - correspondentiegegevens van BETROKKENE. - title: correspondentiePostadres - faxnummer: - type: string - nullable: true - description: faxnummer van de ontvanger of afzender. - title: faxnummer - maxLength: 15 - emailadres: - type: string + Geeft aan of het document gelocked is. Alleen als een document + gelocked is, mogen er aanpassingen gemaakt worden. + title: locked + bestandsdelen: + type: array + items: + $ref: "#/components/schemas/SchemaBestandsDeel" + readOnly: true + title: bestandsdelen + trefwoorden: + type: array + items: + type: string + maxLength: 100 nullable: true - description: emailadres van de ontvanger of afzender. - title: emailadres - maxLength: 100 - mijnOverheid: + description: Een lijst van trefwoorden gescheiden door comma's. + title: trefwoorden + inhoudIsVervallen: type: boolean - description: - is het informatieobject verzonden via mijnOverheid naar de - ontvanger. - title: mijn overheid - telefoonnummer: - type: string nullable: true - description: telefoonnummer van de ontvanger of afzender. - title: telefoonnummer - maxLength: 15 - PostadresTypeEnum: - enum: - - antwoordnummer - - postbusnummer - type: string + description: + Geeft aan of de inhoud van het informatieobject vervallen (dus + niet langer geldig) is. + title: inhoud is vervallen + required: + - auteur + - beginRegistratie + - bestandsdelen + - bronorganisatie + - creatiedatum + - informatieobjecttype + - locked + - taal + - titel + - url + - versie SoortEnum: enum: - analoog @@ -7761,8 +8086,10 @@ components: StatusEnum: enum: - in_bewerking - - ter_vaststelling + - concept - definitief + - ter_vaststelling + - vastgesteld - gearchiveerd type: string UnlockEnkelvoudigInformatieObjectRequest: -- GitLab From f8a7a8f1c04fdf376df0a7ebb2402dcae8805c5d Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Wed, 19 Mar 2025 15:15:05 -0600 Subject: [PATCH 16/22] Eerste implementatie expand, nog niet volledig --- .../nl/contezza/drc/service/EIOService.java | 14 ++ .../drc/service/GebruiksrechtenService.java | 13 ++ .../nl/contezza/drc/service/OIOService.java | 21 +++ .../EnkelvoudigInformatieObjectZoekTest.java | 55 +++++++ .../drc/tests/GebruiksrechtenReadTest.java | 33 ++++ .../InformatieObjectReadCorrectScopeTest.java | 33 ++++ .../nl/contezza/drc/tests/OioReadTest.java | 60 +++++++ platform/pom.xml | 34 ++-- .../contezza/drc/helper/DRCExpandHelper.java | 149 ++++++++++++++++++ .../drc/helper/WebScriptInternalInvoker.java | 50 ++++++ .../nl/contezza/drc/service/DRCService.java | 2 +- .../AbstractDrcDeclarativeWebScript.java | 4 + ...kelvoudiginformatieobjectTemplateNode.java | 14 +- .../EnkelvoudiginformatieobjectenGet.java | 5 +- .../EnkelvoudiginformatieobjectenPost.java | 26 ++- .../EnkelvoudiginformatieobjectenPut.java | 2 +- .../gebruiksrechten/GebruiksrechtenGet.java | 28 +++- .../context/service-context.xml | 8 +- ...nkelvoudiginformatieobjecten.post.json.ftl | 9 +- .../gebruiksrechten.get.json.ftl | 13 +- 20 files changed, 548 insertions(+), 25 deletions(-) create mode 100644 platform/src/main/java/nl/contezza/drc/helper/DRCExpandHelper.java create mode 100644 platform/src/main/java/nl/contezza/drc/helper/WebScriptInternalInvoker.java diff --git a/integration-tests/src/main/java/nl/contezza/drc/service/EIOService.java b/integration-tests/src/main/java/nl/contezza/drc/service/EIOService.java index 4b890b2..4a20d69 100644 --- a/integration-tests/src/main/java/nl/contezza/drc/service/EIOService.java +++ b/integration-tests/src/main/java/nl/contezza/drc/service/EIOService.java @@ -513,6 +513,20 @@ public class EIOService { // @formatter:on } + public Response searchByParams(JSONObject searchParams) { + // @formatter:off + return given() + .spec(DRCRequestSpecification.getDefault()) + // .params(searchParams) + .body(searchParams.toString()) + .when() + .post("/enkelvoudiginformatieobjecten/_zoek") + .then() + .extract() + .response(); + // @formatter:on + } + public InputStream downloadEIO(String url, Integer version) { // @formatter:off return given().param("versie", version) diff --git a/integration-tests/src/main/java/nl/contezza/drc/service/GebruiksrechtenService.java b/integration-tests/src/main/java/nl/contezza/drc/service/GebruiksrechtenService.java index 047e9c9..2a5d3ee 100644 --- a/integration-tests/src/main/java/nl/contezza/drc/service/GebruiksrechtenService.java +++ b/integration-tests/src/main/java/nl/contezza/drc/service/GebruiksrechtenService.java @@ -40,6 +40,19 @@ public class GebruiksrechtenService { // @formatter:on } + public Response list(Map<String, String> params) { + // @formatter:off + return given() + .params(params) + .spec(DRCRequestSpecification.getDefault()) + .when() + .get("/gebruiksrechten") + .then() + .extract() + .response(); + // @formatter:on + } + public Response list(RequestSpecification req, String informatieobject) { Map<String, String> params = new HashMap<String, String>(); if (informatieobject != null) { diff --git a/integration-tests/src/main/java/nl/contezza/drc/service/OIOService.java b/integration-tests/src/main/java/nl/contezza/drc/service/OIOService.java index 02bfb09..f129b86 100644 --- a/integration-tests/src/main/java/nl/contezza/drc/service/OIOService.java +++ b/integration-tests/src/main/java/nl/contezza/drc/service/OIOService.java @@ -55,6 +55,27 @@ public class OIOService { // @formatter:on } + public Response listOIO(RequestSpecification req, Map<String, String> params) { + // Map<String, String> params = new HashMap<String, String>(); + // if (object != null) { + // params.put("object", object); + // } + + // if (informatieobject != null) { + // params.put("informatieobject", informatieobject); + // } + // @formatter:off + return given() + .params(params) + .spec(req) + .when() + .get("/objectinformatieobjecten") + .then() + .extract() + .response(); + // @formatter:on + } + public Response getOIO(String url) { return getOIO(DRCRequestSpecification.getDefault(), url); } diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java index 176ce7a..132269b 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java @@ -1,12 +1,14 @@ package nl.contezza.drc.tests; import org.json.JSONArray; +import org.json.JSONObject; import org.testng.Assert; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; import io.restassured.path.json.JsonPath; import io.restassured.response.Response; +import nl.contezza.drc.dataprovider.DRCDataProvider; import nl.contezza.drc.rest.RestTest; import nl.contezza.drc.service.EIOService; import nl.contezza.drc.service.ZTCService; @@ -68,6 +70,59 @@ public class EnkelvoudigInformatieObjectZoekTest extends RestTest { Assert.assertEquals((int) res.body().path("results.size()"), 1); } + /** + * See {@link <a href= + * "https://github.com/VNG-Realisatie/documenten-api/blob/1.5.0/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L701">python + * code</a>}. + */ + @Test(groups = "EnkelvoudigInformatieObjectZoek", enabled = true) + public void test_zoek_expand() { + // eio1, eio2, eio3 = EnkelvoudigInformatieObjectFactory.create_batch(3) + // url = get_operation_url("enkelvoudiginformatieobject__zoek") + // data = {"uuid__in": [eio1.uuid, eio2.uuid], "expand": "url"} + // response = self.client.post(url, data) + + // self.assertEqual(response.status_code, status.HTTP_200_OK) + + // data = response.json()["results"] + // data = sorted(data, key=lambda eio: eio["identificatie"]) + // self.assertEqual(len(data), 2) + // self.assertTrue(bool(data[0]["_expand"])) + + EIOService eioService = new EIOService(); + + // @formatter:off + JSONObject bodyCreate = new JSONObject(DRCDataProvider.testCreate(informatieobjecttypeUrl)); + bodyCreate.put("status", "concept"); + bodyCreate.put("link", "http://drc.local:8000/api/v1/enkelvoudiginformatieobjecten/8b503791-c567-402c-9f35-0b213715119c"); + Response res = eioService.testCreate(bodyCreate); + Assert.assertEquals(res.getStatusCode(), 201); + String url1 = new JsonPath(res.asString()).getString("url"); + String url2 = new JsonPath(eioService.testCreate(bodyCreate).asString()).getString("url"); + String url3 = new JsonPath(eioService.testCreate(informatieobjecttypeUrl).asString()).getString("url"); + // @formatter:on + + // Wait for Solr to be indexed + wait(20000); + + String uuid1 = url1.substring(url1.lastIndexOf('/') + 1).trim(); + String uuid2 = url2.substring(url2.lastIndexOf('/') + 1).trim(); + String static_uuid = "6ea998ee-8c38-4403-a310-7c5f39c25559"; + // String uuid3 = url3.substring(url3.lastIndexOf('/') + 1).trim(); + + JSONObject body = new JSONObject(); + // body.put("uuid_In", new JSONArray().put(static_uuid)); + body.put("uuid_In", new JSONArray().put(uuid1).put(uuid2)); + body.put("expand", "url,informatieobjecttype,link"); + + res = eioService.searchByParams(body); + JsonPath json = new JsonPath(res.body().asString()); + + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals((int) res.body().path("results.size()"), 2); + Assert.assertTrue(json.getString("results[0]._expand.url.url") != null); + } + /** * See {@link <a href= * "https://github.com/VNG-Realisatie/documenten-api/blob/1.3.0/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L697">python diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/GebruiksrechtenReadTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/GebruiksrechtenReadTest.java index 5865fdc..f63d768 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/GebruiksrechtenReadTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/GebruiksrechtenReadTest.java @@ -1,5 +1,8 @@ package nl.contezza.drc.tests; +import java.util.HashMap; +import java.util.Map; + import org.json.JSONArray; import org.testng.Assert; import org.testng.annotations.BeforeTest; @@ -91,4 +94,34 @@ public class GebruiksrechtenReadTest extends RestTest { Assert.assertEquals(res1.getStatusCode(), 403); Assert.assertEquals(res2.getStatusCode(), 403); } + + /** + * See {@link <a href= + * "https://github.com/VNG-Realisatie/documenten-api/blob/1.4.0/src/drc/api/tests/test_gebruiksrechten.py#L135">python + * code</a>}. + */ + @Test(groups = "GebruiksrechtenRead", enabled = true) + public void test_expand_mechanism() { + EIOService eioService = new EIOService(); + + JsonPath json1 = new JsonPath( + eioService.testCreate(informatieobjecttypeUrl, "beschrijving1", "inhoud1", + "openbaar").asString()); + + GebruiksrechtenService gebruiksrechtenService = new GebruiksrechtenService(); + Response res = gebruiksrechtenService.create(json1.getString("url")); + + Assert.assertEquals(res.getStatusCode(), 201); + + // wait(20000); + Map<String, String> params = new HashMap<>(); + params.put("informatieobject", json1.getString("url")); + // params.put("informatieobject", + // "http://drc-docker-platform.local:8080/alfresco/service/drc/v1/enkelvoudiginformatieobjecten/cc85fc57-901b-4df5-ba95-957c33817ff3"); + params.put("expand", "informatieobject,omschrijvingVoorwaarden"); + + res = gebruiksrechtenService.list(params); + + Assert.assertEquals(res.getStatusCode(), 200); + } } diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/InformatieObjectReadCorrectScopeTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/InformatieObjectReadCorrectScopeTest.java index 4cd7f24..75daccf 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/InformatieObjectReadCorrectScopeTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/InformatieObjectReadCorrectScopeTest.java @@ -142,4 +142,37 @@ public class InformatieObjectReadCorrectScopeTest extends RestTest { Assert.assertEquals(res.getStatusCode(), 200); Assert.assertEquals((int) res.body().path("results.size()"), 4); } + + @Test(groups = "InformatieObjectReadCorrectScope") + public void test_io_list_expand() { + EIOService eioService = new EIOService(); + + eioService.testCreate(informatieobjecttypeUrl, "beschrijving1", "inhoud1", "openbaar"); + eioService.testCreate(informatieobjecttypeUrl, "beschrijving2", "inhoud2", "zeer_geheim"); + eioService.testCreate("https://informatieobjecttype.nl/not_ok", "beschrijving3", "inhoud3", "openbaar"); + eioService.testCreate("https://informatieobjecttype.nl/not_ok", "beschrijving4", "inhoud4", "zeer_geheim"); + + AuthService authService = new AuthService(); + Response res = authService.list(DRCRequestSpecification.CLIENT_ID_READONLY, null); + + String acUrl = res.body().path("results[0].url"); + res = authService.updatePartial(acUrl, new JSONArray().put(DRCRequestSpecification.CLIENT_ID_READONLY), + new JSONArray().put("documenten.lezen"), informatieobjecttypeUrl, + "openbaar"); + + wait(2000); + + Assert.assertEquals(res.getStatusCode(), 200); + + wait(20000); + + res = eioService.listEIO(DRCRequestSpecification.getReadonly(), null, null, null); + + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals((int) res.body().path("results.size()"), 1); + + String iot = res.body().path("results[0].informatieobjecttype"); + Assert.assertEquals(iot.replace(ZTC_BASE_URI, ZTC_DOCKER_URI), informatieobjecttypeUrl); + Assert.assertEquals(res.body().path("results[0].vertrouwelijkheidaanduiding"), "openbaar"); + } } diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java index d0bca23..916b7a4 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java @@ -209,4 +209,64 @@ public class OioReadTest extends RestTest { Assert.assertEquals(res3.getStatusCode(), 403); } + + @Test(groups = "OioRead", enabled = true) + public void test_list_oio_expand() { + + String zaakUrl = zaakTestObject.getString("url").replace(ZRC_BASE_URI, ZRC_DOCKER_URI); + + // apparently we need to use localhost only for internal DRC?? + if (DRCRequestSpecification.BASE_PATH.equals("/documenten/api/v1")) { + zaakUrl = zaakTestObject.getString("url"); + } + + EIOService eioService = new EIOService(); + + JsonPath json1 = new JsonPath( + eioService.testCreate(informatieobjecttypeUrl, "beschrijving1", "inhoud1", "openbaar").asString()); + JsonPath json2 = new JsonPath( + eioService.testCreate(informatieobjecttypeUrl, "beschrijving2", "inhoud2", "vertrouwelijk").asString()); + JsonPath json3 = new JsonPath( + eioService.testCreate(informatieobjecttypeUrl, "beschrijving3", "inhoud3", "zeer_geheim").asString()); + + log.debug(zaakTestObject.getString("identificatie")); + + ZRCService zrcService = new ZRCService(); + Response res = zrcService.createZio(json1.getString("url").replace(DRC_BASE_URI, DRC_DOCKER_URI), zaakUrl); + + Assert.assertEquals(res.getStatusCode(), 201); + + res = zrcService.createZio(json2.getString("url").replace(DRC_BASE_URI, DRC_DOCKER_URI), zaakUrl); + + Assert.assertEquals(res.getStatusCode(), 201); + + res = zrcService.createZio(json3.getString("url").replace(DRC_BASE_URI, DRC_DOCKER_URI), zaakUrl); + + Assert.assertEquals(res.getStatusCode(), 201); + + AuthService authService = new AuthService(); + res = authService.list(DRCRequestSpecification.CLIENT_ID_READONLY, null); + + String acUrl = res.body().path("results[0].url"); + Response resAuth = authService.updatePartial(acUrl, + new JSONArray().put(DRCRequestSpecification.CLIENT_ID_READONLY), + new JSONArray().put("documenten.lezen"), + informatieobjecttypeUrl, "openbaar"); + + Assert.assertEquals(resAuth.getStatusCode(), 200); + + OIOService oioService = new OIOService(); + res = oioService.listOIO(zaakUrl, null); + + Assert.assertEquals((int) res.body().path("results.size()"), 3); + + wait(2000); + Map<String, String> params = new HashMap<>(); + params.put("object", zaakUrl); + params.put("expand", "object"); + + res = oioService.listOIO(DRCRequestSpecification.getReadonly(), params); + + Assert.assertEquals((int) res.body().path("results.size()"), 1); + } } diff --git a/platform/pom.xml b/platform/pom.xml index 69f224c..7a7ed0e 100644 --- a/platform/pom.xml +++ b/platform/pom.xml @@ -1,5 +1,7 @@ <?xml version="1.0" encoding="UTF-8"?> -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> +<project xmlns="http://maven.apache.org/POM/4.0.0" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> @@ -108,6 +110,11 @@ <scope>test</scope> </dependency> + <dependency> + <groupId>com.fasterxml.jackson.datatype</groupId> + <artifactId>jackson-datatype-jsr310</artifactId> + <version>2.15.2</version> + </dependency> </dependencies> <dependencyManagement> @@ -157,7 +164,8 @@ <version>3.1.0</version> <configuration> <encoding>UTF-8</encoding> - <nonFilteredFileExtensions> <!-- jpg, jpeg, gif, bmp and png are added automatically --> + <nonFilteredFileExtensions> <!-- jpg, jpeg, gif, bmp and png are added + automatically --> <nonFilteredFileExtension>ftl</nonFilteredFileExtension> <nonFilteredFileExtension>acp</nonFilteredFileExtension> <nonFilteredFileExtension>svg</nonFilteredFileExtension> @@ -301,8 +309,10 @@ <excludeScope>compile</excludeScope> </configuration> </execution> - <!-- Collect extensions (JARs or AMPs) declared in this module to be deployed to docker --> - <!-- https://stackoverflow.com/questions/30642630/artifact-has-not-been-packaged-yet --> + <!-- Collect extensions (JARs or AMPs) declared in this module to be deployed to + docker --> + <!-- + https://stackoverflow.com/questions/30642630/artifact-has-not-been-packaged-yet --> <execution> <id>collect-extensions</id> <phase>package</phase> @@ -312,7 +322,8 @@ <configuration> <outputDirectory>${project.build.directory}/extensions</outputDirectory> <includeScope>runtime</includeScope> - <!-- IMPORTANT: if using amp dependencies only, add <includeTypes>amp</includeTypes> --> + <!-- IMPORTANT: if using amp dependencies only, add + <includeTypes>amp</includeTypes> --> </configuration> </execution> @@ -400,7 +411,8 @@ <configuration> <target> <!-- Use Ant's copy task to copy files --> - <copy todir="${project.build.outputDirectory}/alfresco/module/${project.artifactId}"> + <copy + todir="${project.build.outputDirectory}/alfresco/module/${project.artifactId}"> <fileset dir="../docs/target/generated-docs" includes="*.pdf" /> </copy> </target> @@ -423,7 +435,8 @@ </executions> </plugin> - <!-- Runs the integration tests, any class that follows naming convention "**/IT*.java", "**/*IT.java", and "**/*ITCase.java" will be considered an integration test --> + <!-- Runs the integration tests, any class that follows naming convention "**/IT*.java", + "**/*IT.java", and "**/*ITCase.java" will be considered an integration test --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-failsafe-plugin</artifactId> @@ -473,7 +486,8 @@ </execution> </executions> <configuration> - <!-- For more information about how to configure JRebel plugin see: http://manuals.zeroturnaround.com/jrebel/standalone/maven.html#maven-rebel-xml --> + <!-- For more information about how to configure JRebel plugin see: + http://manuals.zeroturnaround.com/jrebel/standalone/maven.html#maven-rebel-xml --> <classpath> <fallback>all</fallback> <resources> @@ -484,7 +498,9 @@ </resources> </classpath> - <!-- alwaysGenerate - default is false If 'false' - rebel.xml is generated if timestamps of pom.xml and the current rebel.xml file are not equal. If 'true' - rebel.xml will always + <!-- alwaysGenerate - default is false If 'false' - rebel.xml is generated if + timestamps of pom.xml and the current rebel.xml file are not equal. If 'true' - + rebel.xml will always be generated --> <alwaysGenerate>true</alwaysGenerate> </configuration> diff --git a/platform/src/main/java/nl/contezza/drc/helper/DRCExpandHelper.java b/platform/src/main/java/nl/contezza/drc/helper/DRCExpandHelper.java new file mode 100644 index 0000000..78a00c8 --- /dev/null +++ b/platform/src/main/java/nl/contezza/drc/helper/DRCExpandHelper.java @@ -0,0 +1,149 @@ +/* + * Copyright 2022-2025 Contezza BV, the Netherlands. + * + * Licensed under EUPL, Version 1.2 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package nl.contezza.drc.helper; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.regex.Matcher; +import java.util.regex.Pattern; + +import org.alfresco.repo.service.ServiceDescriptorRegistry; +import org.alfresco.service.cmr.repository.NodeRef; +import org.alfresco.service.cmr.repository.NodeService; +import org.alfresco.service.namespace.QName; +import org.alfresco.util.UrlUtil; +import org.json.JSONObject; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Qualifier; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.extensions.webscripts.WebScriptRequest; + +import nl.contezza.drc.model.RGBZModel; +import nl.contezza.drc.service.DRCCatalogiService; +import nl.contezza.drc.service.DRCService; +import nl.contezza.drc.webscript.AbstractDrcDeclarativeWebScript; +import nl.vngrealisatie.ztc.model.InformatieObjectType; + +import com.fasterxml.jackson.databind.ObjectMapper; +import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule; + +public class DRCExpandHelper { + + private static final ObjectMapper objectMapper = new ObjectMapper() + .registerModule(new JavaTimeModule()); + private static final String UUID_REGEX = "([a-f0-9]{8}-[a-f0-9]{4}-[1-5][a-f0-9]{3}-[89ab][a-f0-9]{3}-[a-f0-9]{12})$"; + private static final String URL_REGEX = "^(https?://[\\w.-]+(:\\d+)?(/.*)?)" + UUID_REGEX; + + @Autowired + @Qualifier("DRCService") + protected DRCService drcService; + @Autowired + @Qualifier("NodeService") + protected NodeService nodeService; + @Autowired + private WebScriptInternalInvoker webScriptInvoker; + @Autowired + @Qualifier("ServiceRegistry") + protected ServiceDescriptorRegistry serviceDescriptorRegistry; + @Autowired + @Qualifier("DRCCatalogiService") + protected DRCCatalogiService drcCatalogiService; + + @Value("${drc.url.overwrite}") + protected String URL_OVERWRITE; + + public Map<String, JSONObject> getExpandedFields(NodeRef nodeRef, List<String> expandFields, WebScriptRequest req) { + Map<String, JSONObject> expandedFields = new HashMap<>(); + String authToken = getAlfrescoTicket(req); + for (String field : expandFields) { + if (field.equals("url")) { + JSONObject json = callScript(buildUrl(nodeRef), authToken); + expandedFields.put(field, json); + } else if (field.equals("informatieobjecttype")) { + String informatieobjecttypeUrl = (String) nodeService.getProperty(nodeRef, + RGBZModel.PROP_INFORMATIEOBJECTTYPE); + if (informatieobjecttypeUrl != null && isValidUrl(informatieobjecttypeUrl)) { + InformatieObjectType informatieobjecttype = drcCatalogiService + .informatieobjecttypeRead(extractUuid(informatieobjecttypeUrl)).getData(); + expandedFields.put(field, transformInformatieObjectType(informatieobjecttype)); + } + } else { + Object property = nodeService.getProperty(nodeRef, QName.createQName(RGBZModel.URI, field)); + if (property != null && property instanceof String && isLocalUrl((String) property)) { + JSONObject json = callScript((String) property, authToken); + expandedFields.put(field, json); + } else { + expandedFields.put(field, new JSONObject("{}")); + } + } + } + return expandedFields; + } + + public boolean isValidUrl(String urlString) { + Pattern pattern = Pattern.compile(URL_REGEX, Pattern.CASE_INSENSITIVE); + Matcher matcher = pattern.matcher(urlString); + + if (matcher.matches()) { + return true; + } + return false; + } + + private JSONObject callScript(String url, String authToken) { + JSONObject response = webScriptInvoker.callWebScript(url, authToken); + return response; + } + + private String getAlfrescoTicket(WebScriptRequest req) { + String ticket = req.getHeader("Authorization"); + return ticket; + } + + /** + * Build bestandsdelen URL. + * + * @param nodeRef NodeRef + * @return String url with id of node ref + */ + private String buildUrl(NodeRef nodeRef) { + return URL_OVERWRITE != null && !URL_OVERWRITE.isEmpty() + ? URL_OVERWRITE + "/enkelvoudiginformatieobjecten/" + nodeRef.getId() + : String.format( + AbstractDrcDeclarativeWebScript.ENDPOINT_EIO, + UrlUtil.getAlfrescoUrl(serviceDescriptorRegistry.getSysAdminParams())) + "/" + nodeRef.getId(); + } + + private String extractUuid(String url) { + String[] parts = url.split("/"); + return parts[parts.length - 1]; + } + + private JSONObject transformInformatieObjectType(InformatieObjectType informatieObjectType) { + try { + String jsonString = objectMapper.writeValueAsString(informatieObjectType); + return new JSONObject(jsonString); + } catch (Exception e) { + throw new RuntimeException("Failed to convert to JSON", e); + } + } + + private boolean isLocalUrl(String url) { + String localUrl = UrlUtil.getAlfrescoUrl(serviceDescriptorRegistry.getSysAdminParams()); + return url.startsWith(localUrl); + } +} diff --git a/platform/src/main/java/nl/contezza/drc/helper/WebScriptInternalInvoker.java b/platform/src/main/java/nl/contezza/drc/helper/WebScriptInternalInvoker.java new file mode 100644 index 0000000..88e954f --- /dev/null +++ b/platform/src/main/java/nl/contezza/drc/helper/WebScriptInternalInvoker.java @@ -0,0 +1,50 @@ +/* + * Copyright 2022-2025 Contezza BV, the Netherlands. + * + * Licensed under EUPL, Version 1.2 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package nl.contezza.drc.helper; + +import org.springframework.stereotype.Component; +import org.springframework.web.client.RestTemplate; +import org.springframework.http.ResponseEntity; +import org.json.JSONObject; + +import org.springframework.http.HttpHeaders; +import org.springframework.http.HttpMethod; +import org.springframework.http.HttpEntity; + +@Component +public class WebScriptInternalInvoker { + + public JSONObject callWebScript(String url, String authToken) { + RestTemplate restTemplate = new RestTemplate(); + try { + // String jsonResponse = restTemplate.getForObject(url, String.class); + + HttpHeaders headers = new HttpHeaders(); + headers.set("Authorization", authToken); + + // Create HttpEntity with headers + HttpEntity<String> entity = new HttpEntity<>(headers); + + // Perform the GET request with headers + ResponseEntity<String> response = restTemplate.exchange(url, HttpMethod.GET, entity, String.class); + String jsonResponse = response.getBody(); + return new JSONObject(jsonResponse); + } catch (Exception e) { + e.printStackTrace(); + return null; + } + } +} diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCService.java b/platform/src/main/java/nl/contezza/drc/service/DRCService.java index 40ac3e3..7b39a4e 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCService.java @@ -978,7 +978,7 @@ public class DRCService { query += String.format("AND =@rgbz\\:informatieobject:\"%s\"", eio); } - ResultSet resultSet = performSearch(query); + ResultSet resultSet = performFTSSearch(query); return resultSet; } diff --git a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java index 46447fa..47f6884 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java @@ -57,6 +57,7 @@ import com.auth0.jwt.JWT; import com.auth0.jwt.interfaces.DecodedJWT; import nl.contezza.drc.helper.DRCBestandsdelenHelper; +import nl.contezza.drc.helper.DRCExpandHelper; import nl.contezza.drc.helper.DRCFieldValidationError; import nl.contezza.drc.helper.DRCValidationHelper; import nl.contezza.drc.model.RGBZModel; @@ -140,6 +141,9 @@ public abstract class AbstractDrcDeclarativeWebScript extends DeclarativeWebScri @Qualifier("DRCBestandsdelenHelper") protected DRCBestandsdelenHelper drcBestandsdelenHelper; @Autowired + @Qualifier("DRCExpandHelper") + protected DRCExpandHelper drcExpandHelper; + @Autowired @Qualifier("CheckOutCheckInService") protected CheckOutCheckInService checkOutCheckInService; @Autowired diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java index 265e2cf..1502ada 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java @@ -35,6 +35,7 @@ import org.alfresco.service.namespace.NamespacePrefixResolver; import org.alfresco.service.namespace.NamespacePrefixResolverProvider; import org.alfresco.service.namespace.QName; import org.alfresco.service.namespace.QNameMap; +import org.json.JSONObject; import nl.contezza.drc.helper.Bestandsdelen; @@ -50,6 +51,7 @@ public class EnkelvoudiginformatieobjectTemplateNode extends BaseContentNode private List<Bestandsdelen> bestandsdelen; private String id; private boolean propsRetrieved = false; + private Map<String, JSONObject> expandFields; private PropertyConverter propertyConverter = new TemplatePropertyConverter(); @@ -62,7 +64,7 @@ public class EnkelvoudiginformatieobjectTemplateNode extends BaseContentNode * @param bestandsdelen List of components for the information object. */ public EnkelvoudiginformatieobjectTemplateNode(NodeRef nodeRef, ServiceRegistry services, - TemplateImageResolver resolver, List<Bestandsdelen> bestandsdelen) { + TemplateImageResolver resolver, List<Bestandsdelen> bestandsdelen, Map<String, JSONObject> expandFields) { if (nodeRef == null) { throw new IllegalArgumentException("NodeRef must be supplied."); } @@ -79,6 +81,8 @@ public class EnkelvoudiginformatieobjectTemplateNode extends BaseContentNode this.properties = new QNameMap<String, Serializable>(this); this.bestandsdelen = bestandsdelen; + + this.expandFields = expandFields; } public List<Bestandsdelen> getBestandsdelen() { @@ -178,6 +182,14 @@ public class EnkelvoudiginformatieobjectTemplateNode extends BaseContentNode return locked; } + public Map<String, JSONObject> getExpandFields() { + return expandFields; + } + + public void setExpandFields(Map<String, JSONObject> expandFields) { + this.expandFields = expandFields; + } + /** * Class to convert properties into template accessible objects */ diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java index 3dfe5d8..c7eac66 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java @@ -209,7 +209,8 @@ public class EnkelvoudiginformatieobjectenGet extends AbstractDrcDeclarativeWebS model.put("itemId", itemId); model.put("providedVersion", providedVersion); model.put("item", - new EnkelvoudiginformatieobjectTemplateNode(nodeRef, serviceRegistry, null, bestandsdelen)); + new EnkelvoudiginformatieobjectTemplateNode(nodeRef, serviceRegistry, null, bestandsdelen, + null)); // Generate eTag String curETag = ETag.generate((Date) nodeService.getProperty(nodeRef, ContentModel.PROP_MODIFIED)); @@ -307,7 +308,7 @@ public class EnkelvoudiginformatieobjectenGet extends AbstractDrcDeclarativeWebS NodeRef ref = resultSet.getNodeRef(i); if (isAuthorized(ref, authLevels)) { items.add(new EnkelvoudiginformatieobjectTemplateNode(ref, serviceRegistry, null, - drcBestandsdelenHelper.getBestandsdelen(ref))); + drcBestandsdelenHelper.getBestandsdelen(ref), null)); } i++; diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java index a38e47b..e86bf2e 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java @@ -17,10 +17,12 @@ package nl.contezza.drc.webscript.enkelvoudiginformatieobjecten; import java.io.Serializable; import java.util.ArrayList; +import java.util.Arrays; import java.util.Collection; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.stream.Collectors; import org.alfresco.model.ContentModel; import org.alfresco.repo.version.VersionModel; @@ -160,6 +162,8 @@ public class EnkelvoudiginformatieobjectenPost extends AbstractDrcDeclarativeWeb drcValidationHelper.createDrcException(DRCValidationHelper.CODE_PERMISSION_DENIED, 403); } + List<String> expandFields = getExpandList(req); + // Build query String query = buildQuery(req); @@ -205,8 +209,13 @@ public class EnkelvoudiginformatieobjectenPost extends AbstractDrcDeclarativeWeb List<EnkelvoudiginformatieobjectTemplateNode> items = new ArrayList<EnkelvoudiginformatieobjectTemplateNode>(); for (NodeRef ref : resultSet.getNodeRefs()) { if (isAuthorized(ref, authLevels)) { + + Map<String, JSONObject> expandedFields = null; + if (expandFields != null) { + expandedFields = drcExpandHelper.getExpandedFields(ref, expandFields, req); + } items.add(new EnkelvoudiginformatieobjectTemplateNode(ref, serviceRegistry, null, - drcBestandsdelenHelper.getBestandsdelen(ref))); + drcBestandsdelenHelper.getBestandsdelen(ref), expandedFields)); } } @@ -271,7 +280,8 @@ public class EnkelvoudiginformatieobjectenPost extends AbstractDrcDeclarativeWeb model.put("itemId", itemId); model.put("item", - new EnkelvoudiginformatieobjectTemplateNode(nodeRef, serviceRegistry, null, bestandsdelen)); + new EnkelvoudiginformatieobjectTemplateNode(nodeRef, serviceRegistry, null, bestandsdelen, + null)); model.put("url", getUrl(ENDPOINT_EIO)); } return model; @@ -338,4 +348,16 @@ public class EnkelvoudiginformatieobjectenPost extends AbstractDrcDeclarativeWeb return list; } + private List<String> getExpandList(WebScriptRequest req) { + JSONObject jsonRequest = (JSONObject) req.parseContent(); + if (jsonRequest.has("expand")) { + String expand = jsonRequest.getString("expand"); + + return Arrays.stream(expand.split(",")) + .map(String::trim).filter(s -> !s.isEmpty()).collect(Collectors.toList()); + } + + return null; + } + } \ No newline at end of file diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java index 76d3fa3..7344975 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java @@ -98,7 +98,7 @@ public class EnkelvoudiginformatieobjectenPut extends AbstractDrcDeclarativeWebS // Build model Map<String, Object> model = new HashMap<String, Object>(); model.put("item", new EnkelvoudiginformatieobjectTemplateNode(fileRef, serviceRegistry, null, - drcBestandsdelenHelper.getBestandsdelen(fileRef))); + drcBestandsdelenHelper.getBestandsdelen(fileRef), null)); model.put("url", getUrl(ENDPOINT_EIO)); return model; } diff --git a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java index 34069f6..1f9c4b5 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java @@ -21,11 +21,13 @@ import java.util.Date; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.stream.Collectors; import org.alfresco.model.ContentModel; import org.alfresco.service.cmr.repository.NodeRef; import org.alfresco.service.cmr.search.ResultSet; import org.alfresco.service.cmr.search.ResultSetRow; +import org.json.JSONObject; import org.springframework.extensions.webscripts.Cache; import org.springframework.extensions.webscripts.Status; import org.springframework.extensions.webscripts.WebScriptRequest; @@ -50,7 +52,7 @@ public class GebruiksrechtenGet extends AbstractDrcDeclarativeWebScript { validateItemOrOIOAuth(nodeRef, req); Map<String, Object> model = new HashMap<String, Object>(); - model.put("item", buildModel(nodeRef)); + model.put("item", buildModel(nodeRef, null)); model.put("url", getUrl(ENDPOINT_GEBRUIKSRECHTEN)); // Generate eTag @@ -83,12 +85,18 @@ public class GebruiksrechtenGet extends AbstractDrcDeclarativeWebScript { drcValidationHelper.createDrcException(DRCValidationHelper.CODE_PERMISSION_DENIED, 403); } + List<String> expandFields = getExpandList(req); + Map<String, Object> model = new HashMap<String, Object>(); List<Map<String, Object>> items = new ArrayList<Map<String, Object>>(resultSet.length()); for (int i = 0; i < resultSet.length(); i++) { ResultSetRow row = resultSet.getRow(i); if (canAccessItemOrOIO(row.getNodeRef(), authLevels)) { - items.add(buildModel(row.getNodeRef())); + Map<String, JSONObject> expandedFields = null; + if (expandFields != null) { + expandedFields = drcExpandHelper.getExpandedFields(row.getNodeRef(), expandFields, req); + } + items.add(buildModel(row.getNodeRef(), expandedFields)); } } @@ -102,13 +110,27 @@ public class GebruiksrechtenGet extends AbstractDrcDeclarativeWebScript { * @param nodeRef NodeRef gebruiksrecht * @return Map<String, Object> model */ - private Map<String, Object> buildModel(NodeRef nodeRef) { + private Map<String, Object> buildModel(NodeRef nodeRef, Map<String, JSONObject> expandFields) { Map<String, Object> map = new HashMap<String, Object>(); map.put("url", getUrl(ENDPOINT_OIO) + "/" + nodeRef.getId()); map.put("informatieobject", nodeService.getProperty(nodeRef, RGBZModel.PROP_INFORMATIEOBJECT)); map.put("startdatum", nodeService.getProperty(nodeRef, RGBZModel.PROP_STARTDATUM)); map.put("einddatum", nodeService.getProperty(nodeRef, RGBZModel.PROP_EINDDATUM)); map.put("omschrijvingVoorwaarden", nodeService.getProperty(nodeRef, RGBZModel.PROP_OMSCHRIJVING_VOORWAARDEN)); + map.put("expandFields", expandFields); return map; } + + private List<String> getExpandList(WebScriptRequest req) { + String expand = req.getParameter("expand"); + // JSONObject jsonRequest = (JSONObject) req.parseContent(); + if (expand != null && !expand.isEmpty()) { + // String expand = jsonRequest.getString("expand"); + + return Arrays.stream(expand.split(",")) + .map(String::trim).filter(s -> !s.isEmpty()).collect(Collectors.toList()); + } + + return null; + } } \ No newline at end of file diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/context/service-context.xml b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/context/service-context.xml index 60d9e7d..dfb234e 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/context/service-context.xml +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/context/service-context.xml @@ -20,17 +20,21 @@ <!-- Helper --> <bean id="DRCBestandsdelenHelper" class="nl.contezza.drc.helper.DRCBestandsdelenHelper" /> + <bean id="DRCExpandHelper" class="nl.contezza.drc.helper.DRCExpandHelper" /> <bean id="DRCValidationHelper" class="nl.contezza.drc.helper.DRCValidationHelper" /> + <bean id="WebScriptInternalInvoker" class="nl.contezza.drc.helper.WebScriptInternalInvoker" /> <!-- DRC Audit Script --> - <bean id="scriptDRCAuditService" parent="baseJavaScriptExtension" class="nl.contezza.drc.script.DRCAuditServiceScript"> + <bean id="scriptDRCAuditService" parent="baseJavaScriptExtension" + class="nl.contezza.drc.script.DRCAuditServiceScript"> <property name="extensionName" value="drcAudit" /> </bean> <!-- DRC Script --> - <bean id="scriptDRCService" parent="baseJavaScriptExtension" class="nl.contezza.drc.script.DRCServiceScript"> + <bean id="scriptDRCService" parent="baseJavaScriptExtension" + class="nl.contezza.drc.script.DRCServiceScript"> <property name="extensionName" value="drc" /> </bean> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl index d8929ca..efe874d 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl @@ -55,7 +55,14 @@ <#if lock??>,"lock" : "${lock}"</#if> </#escape> </#if> -} + <#if item.getExpandFields()??> + ,"_expand": { + <#list item.getExpandFields()?keys as key> + "${key}": ${item.getExpandFields()[key]?string?trim}<#if key_has_next>,</#if> + </#list> + } + </#if> + } </#macro> <#if item??> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/gebruiksrechten/gebruiksrechten.get.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/gebruiksrechten/gebruiksrechten.get.json.ftl index 3f4a4ef..cddd8bd 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/gebruiksrechten/gebruiksrechten.get.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/gebruiksrechten/gebruiksrechten.get.json.ftl @@ -1,15 +1,22 @@ <#macro renderItem item> - <#escape y as jsonUtils.encodeJSONString(y)> { <#if item??> "url": "${item.url}", "informatieobject": "${item.informatieobject!""}", "startdatum": "<#if item.startdatum??>${xmldate(item.startdatum)}</#if>", "einddatum": "<#if item.einddatum??>${xmldate(item.einddatum)}</#if>", - "omschrijvingVoorwaarden": "${item.omschrijvingVoorwaarden!""}" + "omschrijvingVoorwaarden": "${item.omschrijvingVoorwaarden!""}" + <#if item.expandFields??> + ,"_expand": { + <#list item.expandFields?keys as key> + "${key}": ${item.expandFields[key]?string?trim}<#if key_has_next>,</#if> + </#list> + } + <#else> + ,"_expand": "empty" + </#if> </#if> } - </#escape> </#macro> <#if items??> -- GitLab From bf9959cac0230980c717835a0e92f62ac2626c8b Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Thu, 20 Mar 2025 12:28:33 -0600 Subject: [PATCH 17/22] Bijwerken tests --- .../EnkelvoudigInformatieObjectZoekTest.java | 32 ++++--------------- .../nl/contezza/drc/tests/OioReadTest.java | 3 ++ 2 files changed, 9 insertions(+), 26 deletions(-) diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java index 132269b..86ad7ce 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java @@ -8,7 +8,6 @@ import org.testng.annotations.Test; import io.restassured.path.json.JsonPath; import io.restassured.response.Response; -import nl.contezza.drc.dataprovider.DRCDataProvider; import nl.contezza.drc.rest.RestTest; import nl.contezza.drc.service.EIOService; import nl.contezza.drc.service.ZTCService; @@ -41,7 +40,7 @@ public class EnkelvoudigInformatieObjectZoekTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/1.3.0/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L683">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObjectZoek") + @Test(groups = "EnkelvoudigInformatieObjectZoek", enabled = true) public void test_zoek_uuid_in() { EIOService eioService = new EIOService(); @@ -77,28 +76,12 @@ public class EnkelvoudigInformatieObjectZoekTest extends RestTest { */ @Test(groups = "EnkelvoudigInformatieObjectZoek", enabled = true) public void test_zoek_expand() { - // eio1, eio2, eio3 = EnkelvoudigInformatieObjectFactory.create_batch(3) - // url = get_operation_url("enkelvoudiginformatieobject__zoek") - // data = {"uuid__in": [eio1.uuid, eio2.uuid], "expand": "url"} - // response = self.client.post(url, data) - - // self.assertEqual(response.status_code, status.HTTP_200_OK) - - // data = response.json()["results"] - // data = sorted(data, key=lambda eio: eio["identificatie"]) - // self.assertEqual(len(data), 2) - // self.assertTrue(bool(data[0]["_expand"])) - EIOService eioService = new EIOService(); // @formatter:off - JSONObject bodyCreate = new JSONObject(DRCDataProvider.testCreate(informatieobjecttypeUrl)); - bodyCreate.put("status", "concept"); - bodyCreate.put("link", "http://drc.local:8000/api/v1/enkelvoudiginformatieobjecten/8b503791-c567-402c-9f35-0b213715119c"); - Response res = eioService.testCreate(bodyCreate); - Assert.assertEquals(res.getStatusCode(), 201); - String url1 = new JsonPath(res.asString()).getString("url"); - String url2 = new JsonPath(eioService.testCreate(bodyCreate).asString()).getString("url"); + String url1 = new JsonPath(eioService.testCreate(informatieobjecttypeUrl).asString()).getString("url"); + String url2 = new JsonPath(eioService.testCreate(informatieobjecttypeUrl).asString()).getString("url"); + @SuppressWarnings("unused") String url3 = new JsonPath(eioService.testCreate(informatieobjecttypeUrl).asString()).getString("url"); // @formatter:on @@ -107,15 +90,12 @@ public class EnkelvoudigInformatieObjectZoekTest extends RestTest { String uuid1 = url1.substring(url1.lastIndexOf('/') + 1).trim(); String uuid2 = url2.substring(url2.lastIndexOf('/') + 1).trim(); - String static_uuid = "6ea998ee-8c38-4403-a310-7c5f39c25559"; - // String uuid3 = url3.substring(url3.lastIndexOf('/') + 1).trim(); JSONObject body = new JSONObject(); - // body.put("uuid_In", new JSONArray().put(static_uuid)); body.put("uuid_In", new JSONArray().put(uuid1).put(uuid2)); body.put("expand", "url,informatieobjecttype,link"); - res = eioService.searchByParams(body); + Response res = eioService.searchByParams(body); JsonPath json = new JsonPath(res.body().asString()); Assert.assertEquals(res.getStatusCode(), 200); @@ -128,7 +108,7 @@ public class EnkelvoudigInformatieObjectZoekTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/1.3.0/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L697">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObjectZoek") + @Test(groups = "EnkelvoudigInformatieObjectZoek", enabled = true) public void test_zoek_without_params() { EIOService eioService = new EIOService(); diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java index 916b7a4..408800c 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java @@ -1,5 +1,8 @@ package nl.contezza.drc.tests; +import java.util.HashMap; +import java.util.Map; + import org.json.JSONArray; import org.testng.Assert; import org.testng.annotations.BeforeTest; -- GitLab From 2b3aaee219ea9514e68545f6620a18f69f5df446 Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Thu, 20 Mar 2025 14:52:18 -0600 Subject: [PATCH 18/22] Revert "Eerste implementatie expand, nog niet volledig" This reverts commit f8a7a8f1c04fdf376df0a7ebb2402dcae8805c5d. --- .../nl/contezza/drc/service/EIOService.java | 14 -- .../drc/service/GebruiksrechtenService.java | 13 -- .../nl/contezza/drc/service/OIOService.java | 21 --- .../EnkelvoudigInformatieObjectZoekTest.java | 39 +---- .../drc/tests/GebruiksrechtenReadTest.java | 33 ---- .../InformatieObjectReadCorrectScopeTest.java | 33 ---- .../nl/contezza/drc/tests/OioReadTest.java | 63 -------- platform/pom.xml | 34 ++-- .../contezza/drc/helper/DRCExpandHelper.java | 149 ------------------ .../drc/helper/WebScriptInternalInvoker.java | 50 ------ .../nl/contezza/drc/service/DRCService.java | 2 +- .../AbstractDrcDeclarativeWebScript.java | 4 - ...kelvoudiginformatieobjectTemplateNode.java | 14 +- .../EnkelvoudiginformatieobjectenGet.java | 5 +- .../EnkelvoudiginformatieobjectenPost.java | 26 +-- .../EnkelvoudiginformatieobjectenPut.java | 2 +- .../gebruiksrechten/GebruiksrechtenGet.java | 28 +--- .../context/service-context.xml | 8 +- ...nkelvoudiginformatieobjecten.post.json.ftl | 9 +- .../gebruiksrechten.get.json.ftl | 13 +- 20 files changed, 27 insertions(+), 533 deletions(-) delete mode 100644 platform/src/main/java/nl/contezza/drc/helper/DRCExpandHelper.java delete mode 100644 platform/src/main/java/nl/contezza/drc/helper/WebScriptInternalInvoker.java diff --git a/integration-tests/src/main/java/nl/contezza/drc/service/EIOService.java b/integration-tests/src/main/java/nl/contezza/drc/service/EIOService.java index 4a20d69..4b890b2 100644 --- a/integration-tests/src/main/java/nl/contezza/drc/service/EIOService.java +++ b/integration-tests/src/main/java/nl/contezza/drc/service/EIOService.java @@ -513,20 +513,6 @@ public class EIOService { // @formatter:on } - public Response searchByParams(JSONObject searchParams) { - // @formatter:off - return given() - .spec(DRCRequestSpecification.getDefault()) - // .params(searchParams) - .body(searchParams.toString()) - .when() - .post("/enkelvoudiginformatieobjecten/_zoek") - .then() - .extract() - .response(); - // @formatter:on - } - public InputStream downloadEIO(String url, Integer version) { // @formatter:off return given().param("versie", version) diff --git a/integration-tests/src/main/java/nl/contezza/drc/service/GebruiksrechtenService.java b/integration-tests/src/main/java/nl/contezza/drc/service/GebruiksrechtenService.java index 2a5d3ee..047e9c9 100644 --- a/integration-tests/src/main/java/nl/contezza/drc/service/GebruiksrechtenService.java +++ b/integration-tests/src/main/java/nl/contezza/drc/service/GebruiksrechtenService.java @@ -40,19 +40,6 @@ public class GebruiksrechtenService { // @formatter:on } - public Response list(Map<String, String> params) { - // @formatter:off - return given() - .params(params) - .spec(DRCRequestSpecification.getDefault()) - .when() - .get("/gebruiksrechten") - .then() - .extract() - .response(); - // @formatter:on - } - public Response list(RequestSpecification req, String informatieobject) { Map<String, String> params = new HashMap<String, String>(); if (informatieobject != null) { diff --git a/integration-tests/src/main/java/nl/contezza/drc/service/OIOService.java b/integration-tests/src/main/java/nl/contezza/drc/service/OIOService.java index f129b86..02bfb09 100644 --- a/integration-tests/src/main/java/nl/contezza/drc/service/OIOService.java +++ b/integration-tests/src/main/java/nl/contezza/drc/service/OIOService.java @@ -55,27 +55,6 @@ public class OIOService { // @formatter:on } - public Response listOIO(RequestSpecification req, Map<String, String> params) { - // Map<String, String> params = new HashMap<String, String>(); - // if (object != null) { - // params.put("object", object); - // } - - // if (informatieobject != null) { - // params.put("informatieobject", informatieobject); - // } - // @formatter:off - return given() - .params(params) - .spec(req) - .when() - .get("/objectinformatieobjecten") - .then() - .extract() - .response(); - // @formatter:on - } - public Response getOIO(String url) { return getOIO(DRCRequestSpecification.getDefault(), url); } diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java index 86ad7ce..176ce7a 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/EnkelvoudigInformatieObjectZoekTest.java @@ -1,7 +1,6 @@ package nl.contezza.drc.tests; import org.json.JSONArray; -import org.json.JSONObject; import org.testng.Assert; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; @@ -40,7 +39,7 @@ public class EnkelvoudigInformatieObjectZoekTest extends RestTest { * "https://github.com/VNG-Realisatie/documenten-api/blob/1.3.0/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L683">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObjectZoek", enabled = true) + @Test(groups = "EnkelvoudigInformatieObjectZoek") public void test_zoek_uuid_in() { EIOService eioService = new EIOService(); @@ -69,46 +68,12 @@ public class EnkelvoudigInformatieObjectZoekTest extends RestTest { Assert.assertEquals((int) res.body().path("results.size()"), 1); } - /** - * See {@link <a href= - * "https://github.com/VNG-Realisatie/documenten-api/blob/1.5.0/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L701">python - * code</a>}. - */ - @Test(groups = "EnkelvoudigInformatieObjectZoek", enabled = true) - public void test_zoek_expand() { - EIOService eioService = new EIOService(); - - // @formatter:off - String url1 = new JsonPath(eioService.testCreate(informatieobjecttypeUrl).asString()).getString("url"); - String url2 = new JsonPath(eioService.testCreate(informatieobjecttypeUrl).asString()).getString("url"); - @SuppressWarnings("unused") - String url3 = new JsonPath(eioService.testCreate(informatieobjecttypeUrl).asString()).getString("url"); - // @formatter:on - - // Wait for Solr to be indexed - wait(20000); - - String uuid1 = url1.substring(url1.lastIndexOf('/') + 1).trim(); - String uuid2 = url2.substring(url2.lastIndexOf('/') + 1).trim(); - - JSONObject body = new JSONObject(); - body.put("uuid_In", new JSONArray().put(uuid1).put(uuid2)); - body.put("expand", "url,informatieobjecttype,link"); - - Response res = eioService.searchByParams(body); - JsonPath json = new JsonPath(res.body().asString()); - - Assert.assertEquals(res.getStatusCode(), 200); - Assert.assertEquals((int) res.body().path("results.size()"), 2); - Assert.assertTrue(json.getString("results[0]._expand.url.url") != null); - } - /** * See {@link <a href= * "https://github.com/VNG-Realisatie/documenten-api/blob/1.3.0/src/drc/api/tests/test_enkelvoudiginformatieobject.py#L697">python * code</a>}. */ - @Test(groups = "EnkelvoudigInformatieObjectZoek", enabled = true) + @Test(groups = "EnkelvoudigInformatieObjectZoek") public void test_zoek_without_params() { EIOService eioService = new EIOService(); diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/GebruiksrechtenReadTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/GebruiksrechtenReadTest.java index f63d768..5865fdc 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/GebruiksrechtenReadTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/GebruiksrechtenReadTest.java @@ -1,8 +1,5 @@ package nl.contezza.drc.tests; -import java.util.HashMap; -import java.util.Map; - import org.json.JSONArray; import org.testng.Assert; import org.testng.annotations.BeforeTest; @@ -94,34 +91,4 @@ public class GebruiksrechtenReadTest extends RestTest { Assert.assertEquals(res1.getStatusCode(), 403); Assert.assertEquals(res2.getStatusCode(), 403); } - - /** - * See {@link <a href= - * "https://github.com/VNG-Realisatie/documenten-api/blob/1.4.0/src/drc/api/tests/test_gebruiksrechten.py#L135">python - * code</a>}. - */ - @Test(groups = "GebruiksrechtenRead", enabled = true) - public void test_expand_mechanism() { - EIOService eioService = new EIOService(); - - JsonPath json1 = new JsonPath( - eioService.testCreate(informatieobjecttypeUrl, "beschrijving1", "inhoud1", - "openbaar").asString()); - - GebruiksrechtenService gebruiksrechtenService = new GebruiksrechtenService(); - Response res = gebruiksrechtenService.create(json1.getString("url")); - - Assert.assertEquals(res.getStatusCode(), 201); - - // wait(20000); - Map<String, String> params = new HashMap<>(); - params.put("informatieobject", json1.getString("url")); - // params.put("informatieobject", - // "http://drc-docker-platform.local:8080/alfresco/service/drc/v1/enkelvoudiginformatieobjecten/cc85fc57-901b-4df5-ba95-957c33817ff3"); - params.put("expand", "informatieobject,omschrijvingVoorwaarden"); - - res = gebruiksrechtenService.list(params); - - Assert.assertEquals(res.getStatusCode(), 200); - } } diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/InformatieObjectReadCorrectScopeTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/InformatieObjectReadCorrectScopeTest.java index 75daccf..4cd7f24 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/InformatieObjectReadCorrectScopeTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/InformatieObjectReadCorrectScopeTest.java @@ -142,37 +142,4 @@ public class InformatieObjectReadCorrectScopeTest extends RestTest { Assert.assertEquals(res.getStatusCode(), 200); Assert.assertEquals((int) res.body().path("results.size()"), 4); } - - @Test(groups = "InformatieObjectReadCorrectScope") - public void test_io_list_expand() { - EIOService eioService = new EIOService(); - - eioService.testCreate(informatieobjecttypeUrl, "beschrijving1", "inhoud1", "openbaar"); - eioService.testCreate(informatieobjecttypeUrl, "beschrijving2", "inhoud2", "zeer_geheim"); - eioService.testCreate("https://informatieobjecttype.nl/not_ok", "beschrijving3", "inhoud3", "openbaar"); - eioService.testCreate("https://informatieobjecttype.nl/not_ok", "beschrijving4", "inhoud4", "zeer_geheim"); - - AuthService authService = new AuthService(); - Response res = authService.list(DRCRequestSpecification.CLIENT_ID_READONLY, null); - - String acUrl = res.body().path("results[0].url"); - res = authService.updatePartial(acUrl, new JSONArray().put(DRCRequestSpecification.CLIENT_ID_READONLY), - new JSONArray().put("documenten.lezen"), informatieobjecttypeUrl, - "openbaar"); - - wait(2000); - - Assert.assertEquals(res.getStatusCode(), 200); - - wait(20000); - - res = eioService.listEIO(DRCRequestSpecification.getReadonly(), null, null, null); - - Assert.assertEquals(res.getStatusCode(), 200); - Assert.assertEquals((int) res.body().path("results.size()"), 1); - - String iot = res.body().path("results[0].informatieobjecttype"); - Assert.assertEquals(iot.replace(ZTC_BASE_URI, ZTC_DOCKER_URI), informatieobjecttypeUrl); - Assert.assertEquals(res.body().path("results[0].vertrouwelijkheidaanduiding"), "openbaar"); - } } diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java index 408800c..d0bca23 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/OioReadTest.java @@ -1,8 +1,5 @@ package nl.contezza.drc.tests; -import java.util.HashMap; -import java.util.Map; - import org.json.JSONArray; import org.testng.Assert; import org.testng.annotations.BeforeTest; @@ -212,64 +209,4 @@ public class OioReadTest extends RestTest { Assert.assertEquals(res3.getStatusCode(), 403); } - - @Test(groups = "OioRead", enabled = true) - public void test_list_oio_expand() { - - String zaakUrl = zaakTestObject.getString("url").replace(ZRC_BASE_URI, ZRC_DOCKER_URI); - - // apparently we need to use localhost only for internal DRC?? - if (DRCRequestSpecification.BASE_PATH.equals("/documenten/api/v1")) { - zaakUrl = zaakTestObject.getString("url"); - } - - EIOService eioService = new EIOService(); - - JsonPath json1 = new JsonPath( - eioService.testCreate(informatieobjecttypeUrl, "beschrijving1", "inhoud1", "openbaar").asString()); - JsonPath json2 = new JsonPath( - eioService.testCreate(informatieobjecttypeUrl, "beschrijving2", "inhoud2", "vertrouwelijk").asString()); - JsonPath json3 = new JsonPath( - eioService.testCreate(informatieobjecttypeUrl, "beschrijving3", "inhoud3", "zeer_geheim").asString()); - - log.debug(zaakTestObject.getString("identificatie")); - - ZRCService zrcService = new ZRCService(); - Response res = zrcService.createZio(json1.getString("url").replace(DRC_BASE_URI, DRC_DOCKER_URI), zaakUrl); - - Assert.assertEquals(res.getStatusCode(), 201); - - res = zrcService.createZio(json2.getString("url").replace(DRC_BASE_URI, DRC_DOCKER_URI), zaakUrl); - - Assert.assertEquals(res.getStatusCode(), 201); - - res = zrcService.createZio(json3.getString("url").replace(DRC_BASE_URI, DRC_DOCKER_URI), zaakUrl); - - Assert.assertEquals(res.getStatusCode(), 201); - - AuthService authService = new AuthService(); - res = authService.list(DRCRequestSpecification.CLIENT_ID_READONLY, null); - - String acUrl = res.body().path("results[0].url"); - Response resAuth = authService.updatePartial(acUrl, - new JSONArray().put(DRCRequestSpecification.CLIENT_ID_READONLY), - new JSONArray().put("documenten.lezen"), - informatieobjecttypeUrl, "openbaar"); - - Assert.assertEquals(resAuth.getStatusCode(), 200); - - OIOService oioService = new OIOService(); - res = oioService.listOIO(zaakUrl, null); - - Assert.assertEquals((int) res.body().path("results.size()"), 3); - - wait(2000); - Map<String, String> params = new HashMap<>(); - params.put("object", zaakUrl); - params.put("expand", "object"); - - res = oioService.listOIO(DRCRequestSpecification.getReadonly(), params); - - Assert.assertEquals((int) res.body().path("results.size()"), 1); - } } diff --git a/platform/pom.xml b/platform/pom.xml index 7a7ed0e..69f224c 100644 --- a/platform/pom.xml +++ b/platform/pom.xml @@ -1,7 +1,5 @@ <?xml version="1.0" encoding="UTF-8"?> -<project xmlns="http://maven.apache.org/POM/4.0.0" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> @@ -110,11 +108,6 @@ <scope>test</scope> </dependency> - <dependency> - <groupId>com.fasterxml.jackson.datatype</groupId> - <artifactId>jackson-datatype-jsr310</artifactId> - <version>2.15.2</version> - </dependency> </dependencies> <dependencyManagement> @@ -164,8 +157,7 @@ <version>3.1.0</version> <configuration> <encoding>UTF-8</encoding> - <nonFilteredFileExtensions> <!-- jpg, jpeg, gif, bmp and png are added - automatically --> + <nonFilteredFileExtensions> <!-- jpg, jpeg, gif, bmp and png are added automatically --> <nonFilteredFileExtension>ftl</nonFilteredFileExtension> <nonFilteredFileExtension>acp</nonFilteredFileExtension> <nonFilteredFileExtension>svg</nonFilteredFileExtension> @@ -309,10 +301,8 @@ <excludeScope>compile</excludeScope> </configuration> </execution> - <!-- Collect extensions (JARs or AMPs) declared in this module to be deployed to - docker --> - <!-- - https://stackoverflow.com/questions/30642630/artifact-has-not-been-packaged-yet --> + <!-- Collect extensions (JARs or AMPs) declared in this module to be deployed to docker --> + <!-- https://stackoverflow.com/questions/30642630/artifact-has-not-been-packaged-yet --> <execution> <id>collect-extensions</id> <phase>package</phase> @@ -322,8 +312,7 @@ <configuration> <outputDirectory>${project.build.directory}/extensions</outputDirectory> <includeScope>runtime</includeScope> - <!-- IMPORTANT: if using amp dependencies only, add - <includeTypes>amp</includeTypes> --> + <!-- IMPORTANT: if using amp dependencies only, add <includeTypes>amp</includeTypes> --> </configuration> </execution> @@ -411,8 +400,7 @@ <configuration> <target> <!-- Use Ant's copy task to copy files --> - <copy - todir="${project.build.outputDirectory}/alfresco/module/${project.artifactId}"> + <copy todir="${project.build.outputDirectory}/alfresco/module/${project.artifactId}"> <fileset dir="../docs/target/generated-docs" includes="*.pdf" /> </copy> </target> @@ -435,8 +423,7 @@ </executions> </plugin> - <!-- Runs the integration tests, any class that follows naming convention "**/IT*.java", - "**/*IT.java", and "**/*ITCase.java" will be considered an integration test --> + <!-- Runs the integration tests, any class that follows naming convention "**/IT*.java", "**/*IT.java", and "**/*ITCase.java" will be considered an integration test --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-failsafe-plugin</artifactId> @@ -486,8 +473,7 @@ </execution> </executions> <configuration> - <!-- For more information about how to configure JRebel plugin see: - http://manuals.zeroturnaround.com/jrebel/standalone/maven.html#maven-rebel-xml --> + <!-- For more information about how to configure JRebel plugin see: http://manuals.zeroturnaround.com/jrebel/standalone/maven.html#maven-rebel-xml --> <classpath> <fallback>all</fallback> <resources> @@ -498,9 +484,7 @@ </resources> </classpath> - <!-- alwaysGenerate - default is false If 'false' - rebel.xml is generated if - timestamps of pom.xml and the current rebel.xml file are not equal. If 'true' - - rebel.xml will always + <!-- alwaysGenerate - default is false If 'false' - rebel.xml is generated if timestamps of pom.xml and the current rebel.xml file are not equal. If 'true' - rebel.xml will always be generated --> <alwaysGenerate>true</alwaysGenerate> </configuration> diff --git a/platform/src/main/java/nl/contezza/drc/helper/DRCExpandHelper.java b/platform/src/main/java/nl/contezza/drc/helper/DRCExpandHelper.java deleted file mode 100644 index 78a00c8..0000000 --- a/platform/src/main/java/nl/contezza/drc/helper/DRCExpandHelper.java +++ /dev/null @@ -1,149 +0,0 @@ -/* - * Copyright 2022-2025 Contezza BV, the Netherlands. - * - * Licensed under EUPL, Version 1.2 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package nl.contezza.drc.helper; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -import org.alfresco.repo.service.ServiceDescriptorRegistry; -import org.alfresco.service.cmr.repository.NodeRef; -import org.alfresco.service.cmr.repository.NodeService; -import org.alfresco.service.namespace.QName; -import org.alfresco.util.UrlUtil; -import org.json.JSONObject; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.beans.factory.annotation.Qualifier; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.extensions.webscripts.WebScriptRequest; - -import nl.contezza.drc.model.RGBZModel; -import nl.contezza.drc.service.DRCCatalogiService; -import nl.contezza.drc.service.DRCService; -import nl.contezza.drc.webscript.AbstractDrcDeclarativeWebScript; -import nl.vngrealisatie.ztc.model.InformatieObjectType; - -import com.fasterxml.jackson.databind.ObjectMapper; -import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule; - -public class DRCExpandHelper { - - private static final ObjectMapper objectMapper = new ObjectMapper() - .registerModule(new JavaTimeModule()); - private static final String UUID_REGEX = "([a-f0-9]{8}-[a-f0-9]{4}-[1-5][a-f0-9]{3}-[89ab][a-f0-9]{3}-[a-f0-9]{12})$"; - private static final String URL_REGEX = "^(https?://[\\w.-]+(:\\d+)?(/.*)?)" + UUID_REGEX; - - @Autowired - @Qualifier("DRCService") - protected DRCService drcService; - @Autowired - @Qualifier("NodeService") - protected NodeService nodeService; - @Autowired - private WebScriptInternalInvoker webScriptInvoker; - @Autowired - @Qualifier("ServiceRegistry") - protected ServiceDescriptorRegistry serviceDescriptorRegistry; - @Autowired - @Qualifier("DRCCatalogiService") - protected DRCCatalogiService drcCatalogiService; - - @Value("${drc.url.overwrite}") - protected String URL_OVERWRITE; - - public Map<String, JSONObject> getExpandedFields(NodeRef nodeRef, List<String> expandFields, WebScriptRequest req) { - Map<String, JSONObject> expandedFields = new HashMap<>(); - String authToken = getAlfrescoTicket(req); - for (String field : expandFields) { - if (field.equals("url")) { - JSONObject json = callScript(buildUrl(nodeRef), authToken); - expandedFields.put(field, json); - } else if (field.equals("informatieobjecttype")) { - String informatieobjecttypeUrl = (String) nodeService.getProperty(nodeRef, - RGBZModel.PROP_INFORMATIEOBJECTTYPE); - if (informatieobjecttypeUrl != null && isValidUrl(informatieobjecttypeUrl)) { - InformatieObjectType informatieobjecttype = drcCatalogiService - .informatieobjecttypeRead(extractUuid(informatieobjecttypeUrl)).getData(); - expandedFields.put(field, transformInformatieObjectType(informatieobjecttype)); - } - } else { - Object property = nodeService.getProperty(nodeRef, QName.createQName(RGBZModel.URI, field)); - if (property != null && property instanceof String && isLocalUrl((String) property)) { - JSONObject json = callScript((String) property, authToken); - expandedFields.put(field, json); - } else { - expandedFields.put(field, new JSONObject("{}")); - } - } - } - return expandedFields; - } - - public boolean isValidUrl(String urlString) { - Pattern pattern = Pattern.compile(URL_REGEX, Pattern.CASE_INSENSITIVE); - Matcher matcher = pattern.matcher(urlString); - - if (matcher.matches()) { - return true; - } - return false; - } - - private JSONObject callScript(String url, String authToken) { - JSONObject response = webScriptInvoker.callWebScript(url, authToken); - return response; - } - - private String getAlfrescoTicket(WebScriptRequest req) { - String ticket = req.getHeader("Authorization"); - return ticket; - } - - /** - * Build bestandsdelen URL. - * - * @param nodeRef NodeRef - * @return String url with id of node ref - */ - private String buildUrl(NodeRef nodeRef) { - return URL_OVERWRITE != null && !URL_OVERWRITE.isEmpty() - ? URL_OVERWRITE + "/enkelvoudiginformatieobjecten/" + nodeRef.getId() - : String.format( - AbstractDrcDeclarativeWebScript.ENDPOINT_EIO, - UrlUtil.getAlfrescoUrl(serviceDescriptorRegistry.getSysAdminParams())) + "/" + nodeRef.getId(); - } - - private String extractUuid(String url) { - String[] parts = url.split("/"); - return parts[parts.length - 1]; - } - - private JSONObject transformInformatieObjectType(InformatieObjectType informatieObjectType) { - try { - String jsonString = objectMapper.writeValueAsString(informatieObjectType); - return new JSONObject(jsonString); - } catch (Exception e) { - throw new RuntimeException("Failed to convert to JSON", e); - } - } - - private boolean isLocalUrl(String url) { - String localUrl = UrlUtil.getAlfrescoUrl(serviceDescriptorRegistry.getSysAdminParams()); - return url.startsWith(localUrl); - } -} diff --git a/platform/src/main/java/nl/contezza/drc/helper/WebScriptInternalInvoker.java b/platform/src/main/java/nl/contezza/drc/helper/WebScriptInternalInvoker.java deleted file mode 100644 index 88e954f..0000000 --- a/platform/src/main/java/nl/contezza/drc/helper/WebScriptInternalInvoker.java +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Copyright 2022-2025 Contezza BV, the Netherlands. - * - * Licensed under EUPL, Version 1.2 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package nl.contezza.drc.helper; - -import org.springframework.stereotype.Component; -import org.springframework.web.client.RestTemplate; -import org.springframework.http.ResponseEntity; -import org.json.JSONObject; - -import org.springframework.http.HttpHeaders; -import org.springframework.http.HttpMethod; -import org.springframework.http.HttpEntity; - -@Component -public class WebScriptInternalInvoker { - - public JSONObject callWebScript(String url, String authToken) { - RestTemplate restTemplate = new RestTemplate(); - try { - // String jsonResponse = restTemplate.getForObject(url, String.class); - - HttpHeaders headers = new HttpHeaders(); - headers.set("Authorization", authToken); - - // Create HttpEntity with headers - HttpEntity<String> entity = new HttpEntity<>(headers); - - // Perform the GET request with headers - ResponseEntity<String> response = restTemplate.exchange(url, HttpMethod.GET, entity, String.class); - String jsonResponse = response.getBody(); - return new JSONObject(jsonResponse); - } catch (Exception e) { - e.printStackTrace(); - return null; - } - } -} diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCService.java b/platform/src/main/java/nl/contezza/drc/service/DRCService.java index 7b39a4e..40ac3e3 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCService.java @@ -978,7 +978,7 @@ public class DRCService { query += String.format("AND =@rgbz\\:informatieobject:\"%s\"", eio); } - ResultSet resultSet = performFTSSearch(query); + ResultSet resultSet = performSearch(query); return resultSet; } diff --git a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java index 47f6884..46447fa 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/AbstractDrcDeclarativeWebScript.java @@ -57,7 +57,6 @@ import com.auth0.jwt.JWT; import com.auth0.jwt.interfaces.DecodedJWT; import nl.contezza.drc.helper.DRCBestandsdelenHelper; -import nl.contezza.drc.helper.DRCExpandHelper; import nl.contezza.drc.helper.DRCFieldValidationError; import nl.contezza.drc.helper.DRCValidationHelper; import nl.contezza.drc.model.RGBZModel; @@ -141,9 +140,6 @@ public abstract class AbstractDrcDeclarativeWebScript extends DeclarativeWebScri @Qualifier("DRCBestandsdelenHelper") protected DRCBestandsdelenHelper drcBestandsdelenHelper; @Autowired - @Qualifier("DRCExpandHelper") - protected DRCExpandHelper drcExpandHelper; - @Autowired @Qualifier("CheckOutCheckInService") protected CheckOutCheckInService checkOutCheckInService; @Autowired diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java index 1502ada..265e2cf 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectTemplateNode.java @@ -35,7 +35,6 @@ import org.alfresco.service.namespace.NamespacePrefixResolver; import org.alfresco.service.namespace.NamespacePrefixResolverProvider; import org.alfresco.service.namespace.QName; import org.alfresco.service.namespace.QNameMap; -import org.json.JSONObject; import nl.contezza.drc.helper.Bestandsdelen; @@ -51,7 +50,6 @@ public class EnkelvoudiginformatieobjectTemplateNode extends BaseContentNode private List<Bestandsdelen> bestandsdelen; private String id; private boolean propsRetrieved = false; - private Map<String, JSONObject> expandFields; private PropertyConverter propertyConverter = new TemplatePropertyConverter(); @@ -64,7 +62,7 @@ public class EnkelvoudiginformatieobjectTemplateNode extends BaseContentNode * @param bestandsdelen List of components for the information object. */ public EnkelvoudiginformatieobjectTemplateNode(NodeRef nodeRef, ServiceRegistry services, - TemplateImageResolver resolver, List<Bestandsdelen> bestandsdelen, Map<String, JSONObject> expandFields) { + TemplateImageResolver resolver, List<Bestandsdelen> bestandsdelen) { if (nodeRef == null) { throw new IllegalArgumentException("NodeRef must be supplied."); } @@ -81,8 +79,6 @@ public class EnkelvoudiginformatieobjectTemplateNode extends BaseContentNode this.properties = new QNameMap<String, Serializable>(this); this.bestandsdelen = bestandsdelen; - - this.expandFields = expandFields; } public List<Bestandsdelen> getBestandsdelen() { @@ -182,14 +178,6 @@ public class EnkelvoudiginformatieobjectTemplateNode extends BaseContentNode return locked; } - public Map<String, JSONObject> getExpandFields() { - return expandFields; - } - - public void setExpandFields(Map<String, JSONObject> expandFields) { - this.expandFields = expandFields; - } - /** * Class to convert properties into template accessible objects */ diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java index c7eac66..3dfe5d8 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenGet.java @@ -209,8 +209,7 @@ public class EnkelvoudiginformatieobjectenGet extends AbstractDrcDeclarativeWebS model.put("itemId", itemId); model.put("providedVersion", providedVersion); model.put("item", - new EnkelvoudiginformatieobjectTemplateNode(nodeRef, serviceRegistry, null, bestandsdelen, - null)); + new EnkelvoudiginformatieobjectTemplateNode(nodeRef, serviceRegistry, null, bestandsdelen)); // Generate eTag String curETag = ETag.generate((Date) nodeService.getProperty(nodeRef, ContentModel.PROP_MODIFIED)); @@ -308,7 +307,7 @@ public class EnkelvoudiginformatieobjectenGet extends AbstractDrcDeclarativeWebS NodeRef ref = resultSet.getNodeRef(i); if (isAuthorized(ref, authLevels)) { items.add(new EnkelvoudiginformatieobjectTemplateNode(ref, serviceRegistry, null, - drcBestandsdelenHelper.getBestandsdelen(ref), null)); + drcBestandsdelenHelper.getBestandsdelen(ref))); } i++; diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java index e86bf2e..a38e47b 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPost.java @@ -17,12 +17,10 @@ package nl.contezza.drc.webscript.enkelvoudiginformatieobjecten; import java.io.Serializable; import java.util.ArrayList; -import java.util.Arrays; import java.util.Collection; import java.util.HashMap; import java.util.List; import java.util.Map; -import java.util.stream.Collectors; import org.alfresco.model.ContentModel; import org.alfresco.repo.version.VersionModel; @@ -162,8 +160,6 @@ public class EnkelvoudiginformatieobjectenPost extends AbstractDrcDeclarativeWeb drcValidationHelper.createDrcException(DRCValidationHelper.CODE_PERMISSION_DENIED, 403); } - List<String> expandFields = getExpandList(req); - // Build query String query = buildQuery(req); @@ -209,13 +205,8 @@ public class EnkelvoudiginformatieobjectenPost extends AbstractDrcDeclarativeWeb List<EnkelvoudiginformatieobjectTemplateNode> items = new ArrayList<EnkelvoudiginformatieobjectTemplateNode>(); for (NodeRef ref : resultSet.getNodeRefs()) { if (isAuthorized(ref, authLevels)) { - - Map<String, JSONObject> expandedFields = null; - if (expandFields != null) { - expandedFields = drcExpandHelper.getExpandedFields(ref, expandFields, req); - } items.add(new EnkelvoudiginformatieobjectTemplateNode(ref, serviceRegistry, null, - drcBestandsdelenHelper.getBestandsdelen(ref), expandedFields)); + drcBestandsdelenHelper.getBestandsdelen(ref))); } } @@ -280,8 +271,7 @@ public class EnkelvoudiginformatieobjectenPost extends AbstractDrcDeclarativeWeb model.put("itemId", itemId); model.put("item", - new EnkelvoudiginformatieobjectTemplateNode(nodeRef, serviceRegistry, null, bestandsdelen, - null)); + new EnkelvoudiginformatieobjectTemplateNode(nodeRef, serviceRegistry, null, bestandsdelen)); model.put("url", getUrl(ENDPOINT_EIO)); } return model; @@ -348,16 +338,4 @@ public class EnkelvoudiginformatieobjectenPost extends AbstractDrcDeclarativeWeb return list; } - private List<String> getExpandList(WebScriptRequest req) { - JSONObject jsonRequest = (JSONObject) req.parseContent(); - if (jsonRequest.has("expand")) { - String expand = jsonRequest.getString("expand"); - - return Arrays.stream(expand.split(",")) - .map(String::trim).filter(s -> !s.isEmpty()).collect(Collectors.toList()); - } - - return null; - } - } \ No newline at end of file diff --git a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java index 7344975..76d3fa3 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/enkelvoudiginformatieobjecten/EnkelvoudiginformatieobjectenPut.java @@ -98,7 +98,7 @@ public class EnkelvoudiginformatieobjectenPut extends AbstractDrcDeclarativeWebS // Build model Map<String, Object> model = new HashMap<String, Object>(); model.put("item", new EnkelvoudiginformatieobjectTemplateNode(fileRef, serviceRegistry, null, - drcBestandsdelenHelper.getBestandsdelen(fileRef), null)); + drcBestandsdelenHelper.getBestandsdelen(fileRef))); model.put("url", getUrl(ENDPOINT_EIO)); return model; } diff --git a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java index 1f9c4b5..34069f6 100644 --- a/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java +++ b/platform/src/main/java/nl/contezza/drc/webscript/gebruiksrechten/GebruiksrechtenGet.java @@ -21,13 +21,11 @@ import java.util.Date; import java.util.HashMap; import java.util.List; import java.util.Map; -import java.util.stream.Collectors; import org.alfresco.model.ContentModel; import org.alfresco.service.cmr.repository.NodeRef; import org.alfresco.service.cmr.search.ResultSet; import org.alfresco.service.cmr.search.ResultSetRow; -import org.json.JSONObject; import org.springframework.extensions.webscripts.Cache; import org.springframework.extensions.webscripts.Status; import org.springframework.extensions.webscripts.WebScriptRequest; @@ -52,7 +50,7 @@ public class GebruiksrechtenGet extends AbstractDrcDeclarativeWebScript { validateItemOrOIOAuth(nodeRef, req); Map<String, Object> model = new HashMap<String, Object>(); - model.put("item", buildModel(nodeRef, null)); + model.put("item", buildModel(nodeRef)); model.put("url", getUrl(ENDPOINT_GEBRUIKSRECHTEN)); // Generate eTag @@ -85,18 +83,12 @@ public class GebruiksrechtenGet extends AbstractDrcDeclarativeWebScript { drcValidationHelper.createDrcException(DRCValidationHelper.CODE_PERMISSION_DENIED, 403); } - List<String> expandFields = getExpandList(req); - Map<String, Object> model = new HashMap<String, Object>(); List<Map<String, Object>> items = new ArrayList<Map<String, Object>>(resultSet.length()); for (int i = 0; i < resultSet.length(); i++) { ResultSetRow row = resultSet.getRow(i); if (canAccessItemOrOIO(row.getNodeRef(), authLevels)) { - Map<String, JSONObject> expandedFields = null; - if (expandFields != null) { - expandedFields = drcExpandHelper.getExpandedFields(row.getNodeRef(), expandFields, req); - } - items.add(buildModel(row.getNodeRef(), expandedFields)); + items.add(buildModel(row.getNodeRef())); } } @@ -110,27 +102,13 @@ public class GebruiksrechtenGet extends AbstractDrcDeclarativeWebScript { * @param nodeRef NodeRef gebruiksrecht * @return Map<String, Object> model */ - private Map<String, Object> buildModel(NodeRef nodeRef, Map<String, JSONObject> expandFields) { + private Map<String, Object> buildModel(NodeRef nodeRef) { Map<String, Object> map = new HashMap<String, Object>(); map.put("url", getUrl(ENDPOINT_OIO) + "/" + nodeRef.getId()); map.put("informatieobject", nodeService.getProperty(nodeRef, RGBZModel.PROP_INFORMATIEOBJECT)); map.put("startdatum", nodeService.getProperty(nodeRef, RGBZModel.PROP_STARTDATUM)); map.put("einddatum", nodeService.getProperty(nodeRef, RGBZModel.PROP_EINDDATUM)); map.put("omschrijvingVoorwaarden", nodeService.getProperty(nodeRef, RGBZModel.PROP_OMSCHRIJVING_VOORWAARDEN)); - map.put("expandFields", expandFields); return map; } - - private List<String> getExpandList(WebScriptRequest req) { - String expand = req.getParameter("expand"); - // JSONObject jsonRequest = (JSONObject) req.parseContent(); - if (expand != null && !expand.isEmpty()) { - // String expand = jsonRequest.getString("expand"); - - return Arrays.stream(expand.split(",")) - .map(String::trim).filter(s -> !s.isEmpty()).collect(Collectors.toList()); - } - - return null; - } } \ No newline at end of file diff --git a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/context/service-context.xml b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/context/service-context.xml index dfb234e..60d9e7d 100644 --- a/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/context/service-context.xml +++ b/platform/src/main/resources/alfresco/module/alfresco-documenten-api-platform/context/service-context.xml @@ -20,21 +20,17 @@ <!-- Helper --> <bean id="DRCBestandsdelenHelper" class="nl.contezza.drc.helper.DRCBestandsdelenHelper" /> - <bean id="DRCExpandHelper" class="nl.contezza.drc.helper.DRCExpandHelper" /> <bean id="DRCValidationHelper" class="nl.contezza.drc.helper.DRCValidationHelper" /> - <bean id="WebScriptInternalInvoker" class="nl.contezza.drc.helper.WebScriptInternalInvoker" /> <!-- DRC Audit Script --> - <bean id="scriptDRCAuditService" parent="baseJavaScriptExtension" - class="nl.contezza.drc.script.DRCAuditServiceScript"> + <bean id="scriptDRCAuditService" parent="baseJavaScriptExtension" class="nl.contezza.drc.script.DRCAuditServiceScript"> <property name="extensionName" value="drcAudit" /> </bean> <!-- DRC Script --> - <bean id="scriptDRCService" parent="baseJavaScriptExtension" - class="nl.contezza.drc.script.DRCServiceScript"> + <bean id="scriptDRCService" parent="baseJavaScriptExtension" class="nl.contezza.drc.script.DRCServiceScript"> <property name="extensionName" value="drc" /> </bean> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl index efe874d..d8929ca 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.post.json.ftl @@ -55,14 +55,7 @@ <#if lock??>,"lock" : "${lock}"</#if> </#escape> </#if> - <#if item.getExpandFields()??> - ,"_expand": { - <#list item.getExpandFields()?keys as key> - "${key}": ${item.getExpandFields()[key]?string?trim}<#if key_has_next>,</#if> - </#list> - } - </#if> - } +} </#macro> <#if item??> diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/gebruiksrechten/gebruiksrechten.get.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/gebruiksrechten/gebruiksrechten.get.json.ftl index cddd8bd..3f4a4ef 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/gebruiksrechten/gebruiksrechten.get.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/gebruiksrechten/gebruiksrechten.get.json.ftl @@ -1,22 +1,15 @@ <#macro renderItem item> + <#escape y as jsonUtils.encodeJSONString(y)> { <#if item??> "url": "${item.url}", "informatieobject": "${item.informatieobject!""}", "startdatum": "<#if item.startdatum??>${xmldate(item.startdatum)}</#if>", "einddatum": "<#if item.einddatum??>${xmldate(item.einddatum)}</#if>", - "omschrijvingVoorwaarden": "${item.omschrijvingVoorwaarden!""}" - <#if item.expandFields??> - ,"_expand": { - <#list item.expandFields?keys as key> - "${key}": ${item.expandFields[key]?string?trim}<#if key_has_next>,</#if> - </#list> - } - <#else> - ,"_expand": "empty" - </#if> + "omschrijvingVoorwaarden": "${item.omschrijvingVoorwaarden!""}" </#if> } + </#escape> </#macro> <#if items??> -- GitLab From e3fcdf07ac16edae402f82e0492befa4ec40aace Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Thu, 20 Mar 2025 14:53:06 -0600 Subject: [PATCH 19/22] Fixed inhoudIsVervallen in response PUT enkelvoudiginformatieobjecten --- .../enkelvoudiginformatieobjecten.put.json.ftl | 1 + 1 file changed, 1 insertion(+) diff --git a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.put.json.ftl b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.put.json.ftl index 9fc6f17..3627f52 100644 --- a/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.put.json.ftl +++ b/platform/src/main/resources/alfresco/templates/webscripts/nl/contezza/drc/enkelvoudiginformatieobjecten/enkelvoudiginformatieobjecten.put.json.ftl @@ -40,6 +40,7 @@ <#else> null </#if>, + "inhoudIsVervallen" : <#if item.properties["rgbz:inhoudIsVervallen"]??>${item.properties["rgbz:inhoudIsVervallen"]?c}<#else>null</#if>, "ondertekening": <#if item.properties["rgbz:ondertekeningDatum"]??>{ "soort": "${item.properties["rgbz:ondertekeningSoort"]!""}", "datum": "<@dateFormat item.properties["rgbz:ondertekeningDatum"] />" -- GitLab From 9e5cdb8606cd7d111f80682a0845779d9457881b Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Mon, 24 Mar 2025 10:28:18 -0600 Subject: [PATCH 20/22] Test (partial) update van EIO met status 'definitief' toegevoegd --- ...CustomEnkelvoudigInformatieObjectTest.java | 55 +++++++++++++++++++ 1 file changed, 55 insertions(+) diff --git a/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java b/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java index 497ee54..4a21a61 100644 --- a/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java +++ b/integration-tests/src/test/java/nl/contezza/drc/tests/custom/CustomEnkelvoudigInformatieObjectTest.java @@ -222,4 +222,59 @@ public class CustomEnkelvoudigInformatieObjectTest extends RestTest { Assert.assertEquals(res.getStatusCode(), 200); Assert.assertEquals(json.getBoolean("inhoudIsVervallen"), false); } + + @Test(groups = "CustomEnkelvoudigInformatieObjectTest", enabled = true) + public void test_update_with_definitief_status() { + EIOService eioService = new EIOService(); + + JSONObject createBody = new JSONObject(DRCDataProvider.testCreate(informatieobjecttypeUrl)); + createBody.put("status", "definitief"); + // Validate verschijningsvorm at POST + Response res = eioService.testCreate(createBody); + JsonPath json = new JsonPath(res.asString()); + + JSONObject createdEio = new JSONObject(json.prettify()); + + Assert.assertEquals(res.getStatusCode(), 201); + Assert.assertEquals(json.getString("status"), "definitief"); + + String eioUrl = json.getString("url"); + + res = eioService.lock(eioUrl); + + Assert.assertEquals(res.getStatusCode(), 200); + + String lock = res.body().path("lock"); + + // Validate verschijningsvorm at PATCH + JSONObject body = new JSONObject(); + body.put("beschrijving", "test_beschrijving2"); + body.put("lock", lock); + + res = eioService.partialUpdate(eioUrl, body); + json = new JsonPath(res.asString()); + + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals(json.getString("beschrijving"), "test_beschrijving2"); + + // Validate verschijningsvorm at PUT + body = new JSONObject(); + body.put("beschrijving", "test_beschrijving3"); + body.put("inhoud", Base64.getEncoder().encodeToString("some file content".getBytes())); + body.put("bestandsomvang", "some file content".getBytes().length); + body.put("lock", lock); + + JSONObject mergedJson = mergeJSONObjects(createdEio, body); + mergedJson.remove("ondertekening"); + mergedJson.remove("integriteit"); + + // Update EIO + res = eioService.update(eioUrl, mergedJson); + json = new JsonPath(res.asString()); + Assert.assertEquals(res.getStatusCode(), 200); + Assert.assertEquals(json.getString("beschrijving"), "test_beschrijving3"); + + res = eioService.unlock(eioUrl, lock); + Assert.assertEquals(res.getStatusCode(), 204); + } } -- GitLab From c60da74a538c0b287447335353fd2fa3d3101dd7 Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Mon, 24 Mar 2025 10:31:58 -0600 Subject: [PATCH 21/22] Fix voor search Gebruikersrechten, verkeerde query language --- platform/src/main/java/nl/contezza/drc/service/DRCService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/src/main/java/nl/contezza/drc/service/DRCService.java b/platform/src/main/java/nl/contezza/drc/service/DRCService.java index 40ac3e3..8b6fcac 100644 --- a/platform/src/main/java/nl/contezza/drc/service/DRCService.java +++ b/platform/src/main/java/nl/contezza/drc/service/DRCService.java @@ -991,7 +991,7 @@ public class DRCService { private ResultSet performFTSSearch(String query) { SearchParameters searchParameters = new SearchParameters(); searchParameters.setQuery(query); - searchParameters.setLanguage(SearchService.LANGUAGE_FTS_ALFRESCO); + searchParameters.setLanguage(SearchService.LANGUAGE_LUCENE); searchParameters.addStore(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE); return searchService.query(searchParameters); } -- GitLab From e807a1298e8eb4a1bcbeb5bdbf1fd29b6ccabd31 Mon Sep 17 00:00:00 2001 From: Erik Hoogland <erik.hoogland@contezza.nl> Date: Tue, 25 Mar 2025 09:24:36 -0600 Subject: [PATCH 22/22] Update dependency integration-tests --- integration-tests/pom.xml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/integration-tests/pom.xml b/integration-tests/pom.xml index a60d193..f552e03 100644 --- a/integration-tests/pom.xml +++ b/integration-tests/pom.xml @@ -19,48 +19,48 @@ <dependency> <groupId>org.testng</groupId> <artifactId>testng</artifactId> - <version>7.0.0</version> + <version>7.11.0</version> </dependency> <!--Rest-Assured --> <dependency> <groupId>io.rest-assured</groupId> <artifactId>rest-assured</artifactId> - <version>4.2.0</version> + <version>5.5.1</version> </dependency> <dependency> <groupId>io.rest-assured</groupId> <artifactId>json-schema-validator</artifactId> - <version>4.2.0</version> + <version>5.5.1</version> </dependency> <!-- Lombok --> <dependency> <groupId>org.projectlombok</groupId> <artifactId>lombok</artifactId> - <version>1.18.24</version> + <version>1.18.36</version> </dependency> <!-- JWT --> <dependency> <groupId>com.auth0</groupId> <artifactId>java-jwt</artifactId> - <version>4.4.0</version> + <version>4.5.0</version> </dependency> <!-- JSON --> <dependency> <groupId>org.json</groupId> <artifactId>json</artifactId> - <version>20210307</version> + <version>20250107</version> </dependency> <!-- IOUtils --> <dependency> <groupId>commons-io</groupId> <artifactId>commons-io</artifactId> - <version>2.8.0</version> + <version>2.18.0</version> </dependency> @@ -68,27 +68,27 @@ <dependency> <groupId>org.apache.logging.log4j</groupId> <artifactId>log4j-core</artifactId> - <version>2.13.0</version> + <version>2.24.3</version> </dependency> <!-- Extent Reports --> <dependency> <groupId>com.aventstack</groupId> <artifactId>extentreports</artifactId> - <version>4.1.2</version> + <version>5.1.2</version> </dependency> <dependency> <groupId>com.aventstack</groupId> <artifactId>extentreports-testng-adapter</artifactId> - <version>1.0.5</version> + <version>1.2.2</version> </dependency> <!-- Annotations --> <dependency> <groupId>org.jetbrains</groupId> <artifactId>annotations</artifactId> - <version>18.0.0</version> + <version>26.0.2</version> </dependency> </dependencies> -- GitLab