Add print view, board info card and document logo upload
- Seitenansicht (/projects/:projectId/print): tabular cover page, board overview with supply structure and power sums, one plan per board with a repeating title block; PDF via the browser print dialog with named @page rules (A4 portrait cover, A4/A3 landscape plans, page x of y). - Distribution-board info card (board number, location, fed-from, remark) in the board edit dialog, persisted through the additively extended distribution-board.update command (migration 0008, snapshot schema 6, legacy subtree commands normalized). - Global document logo upload (PNG/JPEG/SVG, max 2 MB) outside project revisions and snapshots. - fed-from stays free text; the overview hierarchy and cumulated sums are preliminary until the feed link is modeled. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
2e3e85a8e5
commit
4779e4a1a7
40 changed files with 5297 additions and 33 deletions
|
|
@ -230,9 +230,13 @@ returns HTTP `409` with `PROJECT_HISTORY_OPERATION_UNAVAILABLE`.
|
|||
- stale revisions return `409 PROJECT_REVISION_CONFLICT`
|
||||
- `PUT /projects/:projectId/distribution-boards/:distributionBoardId`
|
||||
- body:
|
||||
`{ "floorId": null, "supplyType": "AV", "expectedRevision": 13 }`
|
||||
- executes `distribution-board.update`; floor and supply type are restored
|
||||
together by persistent Undo/Redo
|
||||
`{ "floorId": null, "supplyType": "AV", "simultaneityFactor": 1, "expectedRevision": 13 }`
|
||||
- optional info-card fields: `boardNumber` (max. 50), `location`,
|
||||
`fedFrom` (max. 200 each) and `remark` (max. 2000); strings are trimmed
|
||||
and an empty string is stored as `null`
|
||||
- executes `distribution-board.update`; all submitted values, including the
|
||||
submitted info fields, are restored together by persistent Undo/Redo
|
||||
- `fedFrom` is free text until the logical feed link is modeled
|
||||
- `POST /projects/:projectId/distribution-boards/:distributionBoardId/copy`
|
||||
- body: `{ "name": "UV-02 Kopie", "expectedRevision": 14 }`
|
||||
- duplicates the complete distribution-board subtree with new owning UUIDs
|
||||
|
|
@ -425,3 +429,23 @@ project device never triggers synchronization implicitly.
|
|||
Parser errors expose stable codes such as `header-not-found`,
|
||||
`ambiguous-header`, `invalid-ifc-guid` and `duplicate-ifc-guid`. The confirmed
|
||||
import uploads and parses the file again and verifies its hash.
|
||||
|
||||
## Document Branding (print view)
|
||||
|
||||
Office-wide branding for the print view. These endpoints are mounted at
|
||||
`/api/document-branding`, outside `/api/projects`, because the data is global
|
||||
and intentionally not part of project revisions, snapshots or transfer.
|
||||
|
||||
- `GET /document-branding`
|
||||
- returns `{ "logo": { "mimeType", "fileName", "sizeBytes", "updatedAtIso" } | null }`
|
||||
- `GET /document-branding/logo`
|
||||
- returns the stored image bytes with its media type, or `404` without logo
|
||||
- responses carry `X-Content-Type-Options: nosniff` and a restrictive
|
||||
Content-Security-Policy so an SVG logo cannot execute scripts
|
||||
- `PUT /document-branding/logo`
|
||||
- request: `{ "fileName": "logo.png", "mimeType": "image/png", "contentBase64": "..." }`
|
||||
- accepted types: `image/png`, `image/jpeg`, `image/svg+xml`; at most 2 MB
|
||||
after decoding; the content signature must match the declared type
|
||||
- replaces an existing logo; returns the logo metadata
|
||||
- `DELETE /document-branding/logo`
|
||||
- removes the logo; returns `204`
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue