docs(dn): report split review model fix

This commit is contained in:
DEls 2026-09-19 17:57:24 +02:00
parent 1d74905a91
commit 26143e5ac3

View file

@ -87,3 +87,35 @@ passed
### Accessibility/touch decisions
Open-page actions remain explicit, large existing Button targets; unresolved-page save is visibly disabled with a plain-language resolution message. Proxy authorization never exposes PocketBase admin credentials to the browser.
## Fix Round 2
### Code commit
`1d74905a91e432a38d3a3fd9fe9d40d0560a8ca8` — `fix(dn): isolate split review model and orphan pages`
### GREEN evidence
```text
npx vitest run src/app/dashboard/financial/delivery-notes/inbox/inbox-board.test.ts src/app/dashboard/financial/delivery-notes/inbox/split-review.test.ts src/app/api/dn-batches/[id]/pages/[n]/route.test.ts src/app/api/dn-batches/[id]/assembly/route.test.ts
4 files passed; 42 tests passed
npm run typecheck
passed
npm run build
passed; Next 16 production build completed and included /dashboard/financial/delivery-notes/inbox/[id]
git diff --check
passed
```
### Fixes
- Added server-safe `split-review-model.ts` for payload cleanup, note-group rehydration, dismissed-page rehydration, and orphan-page derivation. The Server Component and Client Component now import this module directly; no Server Component imports the `use client` module.
- `deriveOpenPages` preserves and deduplicates persisted `open_pages`, then adds every uncovered page as an actionable `not assigned` entry, including the no-existing-open-pages case.
- Added focused coverage for the pure module boundary, missing page 4 derivation, persisted-entry deduplication, and dismissed preservation.
### Build note
`npm run build` emitted the repository's existing metadataBase warning but completed successfully; generated icon/OG assets were unchanged in git.