feat(acl): diploma upload stored in the ZGW Documenten API (S-10b, closes #103) #108

Merged
not merged 15 commits from feat/103-diploma-upload-documenten into main 2026-07-21 12:15:35 +00:00
15 Commits
Author SHA1 Message Date
notandClaude Opus 4.8 af83194e79 fix(acl): use camelCase indicatieGebruiksrecht so OpenZaak honours it (refs #103)
CI / lint (pull_request) Successful in 1m22s
CI / build (pull_request) Successful in 1m4s
CI / unit (pull_request) Successful in 1m31s
CI / frontend (pull_request) Successful in 2m43s
CI / mutation (pull_request) Successful in 5m43s
CI / verify-stack (pull_request) Successful in 8m24s
The ZGW Documenten API property is indicatieGebruiksrecht (camelCase); the
all-lowercase key was silently dropped on write (DRF camel-case mapping),
leaving the field null so the zaak still could not close. Correct the JSON
name on the DTO and both assertions to match the ZGW spec.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-21 13:52:34 +02:00
notandClaude Opus 4.8 756e718ee2 fix(acl): set indicatiegebruiksrecht=false on the diploma document (refs #103)
CI / lint (pull_request) Successful in 1m22s
CI / build (pull_request) Successful in 1m3s
CI / unit (pull_request) Successful in 1m18s
CI / frontend (pull_request) Successful in 2m45s
CI / mutation (pull_request) Successful in 5m42s
CI / verify-stack (pull_request) Failing after 5m44s
Records 'no usage-rights restrictions' explicitly so OpenZaak allows the
related zaak to be closed on behandelaar approval, fixing the verify-stack
e2e regression introduced by S-10b diploma upload.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-21 13:31:44 +02:00
notandClaude Opus 4.8 53e9564f94 test(acl): diploma document sets indicatiegebruiksrecht so the zaak can close (refs #103)
The behandelaar approval closes the zaak via OpenZaak. A related
informatieobject with indicatieGebruiksrecht left null makes OpenZaak
reject the close (400 indicatiegebruiksrecht-unset), surfacing as a 500
and failing the registration e2e flow.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-21 13:31:44 +02:00
notandClaude Opus 4.8 5325a99755 fix(acceptance): CapturingDomainClient matches the new ProvideDocumentsAsync signature (refs #103)
CI / lint (pull_request) Successful in 1m19s
CI / build (pull_request) Successful in 1m0s
CI / unit (pull_request) Successful in 1m11s
CI / frontend (pull_request) Successful in 2m29s
CI / mutation (pull_request) Successful in 5m26s
CI / verify-stack (pull_request) Failing after 12m23s
The BFF IDomainClient.ProvideDocumentsAsync grew (base64 file + name/type); the
acceptance host's fake wasn't updated, breaking the Release build (per-project Debug
builds missed it).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:23:48 +02:00
notandClaude Opus 4.8 036005e486 docs(acl): ADR-0018 + demo/backlog for diploma upload via the ACL Documenten API (refs #103)
CI / lint (pull_request) Successful in 1m19s
CI / build (pull_request) Failing after 56s
CI / unit (pull_request) Failing after 1m6s
CI / frontend (pull_request) Successful in 2m37s
CI / mutation (pull_request) Successful in 5m44s
CI / verify-stack (pull_request) Has been cancelled
Records the ACL-fronted Documenten create+relate, the base64-JSON transport chosen
over proposal #107's multipart, the informatieobjecttype seeding, and the S-10c
(zaak-close) carve-off.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:18:46 +02:00
notandClaude Opus 4.8 ae7fc1b8f0 test(acl,e2e): live diploma-upload coverage (refs #103)
- ACL integration test: stores a real document against a published Diploma
  informatieobjecttype and asserts it is persisted (bestandsnaam, informatieobjecttype,
  bestandsomvang) and related to the zaak.
- e2e: the registration journey now selects a PDF and uploads it (setInputFiles)
  before the behandelaar step.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:17:28 +02:00
notandClaude Opus 4.8 1abd4b6472 feat(portal): real diploma file upload on the self-service page (refs #103)
Replaces the S-10a stub button with a labelled file input (accept application/pdf);
the component base64-encodes the chosen file client-side and posts it (with its name
and type) keyed by the reference, confirming on success and surfacing a retryable
failure. The upload button stays disabled until a file is chosen.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:15:49 +02:00
notandClaude Opus 4.8 d354fe507a test(portal): self-service uploads a chosen diploma file (refs #103)
RED: after submitting, the citizen picks a PDF and uploads it; the component base64-
encodes it client-side and posts { contentBase64, fileName, contentType } keyed by the
reference, then confirms. Replaces the S-10a stub button.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:14:36 +02:00
notandClaude Opus 4.8 4c516cdad3 feat(bff): documents endpoint accepts the base64 file and forwards it to the domain (refs #103)
The self-service documents endpoint takes { contentBase64, fileName, contentType }
as JSON (bsn from the token) and forwards it via IDomainClient.ProvideDocumentsAsync.
Regenerates openapi.json + the Angular client (postSelfServiceRegistrationsIdDocuments
now takes a ProvideDocumentsRequest body).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:13:10 +02:00
notandClaude Opus 4.8 9d327bbd81 test(bff): documents endpoint forwards the base64 file to the domain (refs #103)
RED: the self-service documents endpoint takes the base64 file (+ fileName/contentType)
as JSON — the portal encodes client-side — with the bsn from the token, and forwards
all of it to the domain. IDomainClient.ProvideDocumentsAsync grows accordingly.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:07:42 +02:00
notandClaude Opus 4.8 3c344caa29 feat(domain): ProvideDocuments stores the diploma via the ACL then completes the wait (refs #103)
IAclClient.StoreDiplomaAsync + AclHttpClient (base64 JSON to the ACL /documenten
endpoint). ProvideDocuments stores the uploaded bytes against the zaak (when opened)
before completing WachtOpDocumenten; the domain endpoint accepts the file base64-encoded.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:05:40 +02:00
notandClaude Opus 4.8 ecad42873c test(domain): providing documents stores the diploma via the ACL then completes the wait (refs #103)
RED: ProvideDocuments now carries the file bytes, stores them against the zaak via
IAclClient before completing the WachtOpDocumenten wait; owner-scoped; best-effort
when no zaak/process exists yet.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:02:32 +02:00
notandClaude Opus 4.8 4b4b58b486 feat(infra): seed the Diploma informatieobjecttype + wire the ACL default (refs #103)
seed_catalogus.py (OZ_PUBLISH) creates a "Diploma" informatieobjecttype, relates it
to the zaaktype (zaaktype-informatieobjecttypen, while both concept), publishes both,
and prints INFORMATIEOBJECTTYPE_URL. verify-domain captures it and recreates the ACL
with Acl__Defaults__InformatieobjecttypeUrl (placeholder default in compose otherwise).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 12:00:48 +02:00
notandClaude Opus 4.8 dca9455bb5 feat(acl): store a diploma in the Documenten API and relate it to the zaak (refs #103)
IZaakGateway.StoreDocumentAsync creates an enkelvoudiginformatieobject (base64
inhoud, buffered non-chunked body, no CRS) and relates it via zaakinformatieobjecten;
AclService.StoreDiplomaAsync default-fills the ZGW document fields (informatieobjecttype,
bronorganisatie, taal nld, creatiedatum); POST /documenten exposes it. Adds the
InformatieobjecttypeUrl default (wired in a following infra commit).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 11:57:39 +02:00
notandClaude Opus 4.8 aaa7135fb1 test(acl): gateway stores a diploma as an enkelvoudiginformatieobject + relates it (refs #103)
RED: StoreDocumentAsync creates the informatieobject in the Documenten API (base64
inhoud, bestandsomvang, definitief) with a Bearer token and a buffered (non-chunked)
body and no CRS headers, then relates it to the zaak via zaakinformatieobjecten, and
surfaces an OpenZaak rejection.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-20 11:53:59 +02:00