feat(curation): save the documents of a tenant, one commit per save #61
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feat/38-tenant-curation-api"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Refs #38 (step 4a, first part: the server side)
Routes (tenant URL, members read, tenant
adminandcuratorwrite)GET /t/<tenant>/api/tenant/documents/<theme>/<slug>PUT …/documents/<theme>/<slug>title,description,type,tags,thematics,facets,rights,bodyPOST …/documents/<theme>One save, one commit (
TenantDocuments,src/instance/tenant-documents.ts)writeStudioDocument(#52): required keys, rights, themes and facet vocabularies of the tenant. Facet values are made canonical; those set aside come back asrejected.content/index.md(okf_version: "0.2", the only index with a frontmatter).verified; creating one setsgeneratedto the curator. The file name never changes with the title.soacannot save (409).Atomic writes (
TenantWorkspaceInterface.change)discard()(@quatrain/git1.0.3), then the change is applied again on top, once.Also: an undeclared theme takes its label from the
# headingof its index, since a v0.2 index has no frontmatter. Docs: section 9 ofdocs/MULTI-TENANCY.md(EN, FR).Next PR: the curation page (document page from the Library, form with facets and rights, creation of a document and of a theme).
Checks:
yarn test229/229 (12 new, against a real local git remote: concurrent push, refused push, profile refusal leaving a clean working copy).yarn buildpasses.tsc --noEmit: the same 11 errors as ondevelop.🤖 Generated with Claude Code