Commit Graph
100 Commits
Author SHA1 Message Date
logaritmiskandClaude Sonnet 4.6 30d851182e feat(web): new-object full-width page + create flow + /objects/new
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-04 00:46:49 +02:00
logaritmiskandClaude Sonnet 4.6 616c232a22 feat(web): ObjectForm (core + dynamic flexible fields, RHF, validation)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-04 00:40:19 +02:00
logaritmiskandClaude Sonnet 4.6 cf0b34b254 refactor(web): FieldInput form type unknown (drop any); wire localized_text required; a11y/comment nits
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-04 00:36:04 +02:00
logaritmiskandClaude Sonnet 4.6 cb191225cc feat(web): dynamic FieldInput (text/integer/date/boolean/localized_text/term/authority)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-04 00:31:05 +02:00
logaritmiskandClaude Sonnet 4.6 b23a48c310 feat(web): authoring query/mutation hooks + MSW handlers + shadcn select/checkbox/alert-dialog
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-04 00:22:59 +02:00
logaritmiskandClaude Opus 4.8 f3bab3336c docs(plan): frontend SPA milestone 2 — task-by-task implementation plan
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-04 00:16:22 +02:00
logaritmiskandClaude Opus 4.8 9f43793c4a docs(spec): frontend SPA milestone 2 (object authoring) design
Create (full-width /objects/new) + edit (in-pane /objects/:id/edit) +
delete; dynamic flexible-field form (all 7 field types incl. term/authority
Selects + sv/en localized text) via react-hook-form; replace-semantics
field save; client validation + partial-create recovery; Vitest+RTL+MSW.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-04 00:09:15 +02:00
logaritmiskandClaude Opus 4.8 0a2398f507 fix(web): localize flexible-field labels to the active locale (sv/en)
CI / web (push) Has been cancelled
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 23:37:26 +02:00
logaritmiskandClaude Opus 4.8 397e606793 ci(web): fail bundle check when no JS chunks found (avoid false green)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 23:31:08 +02:00
logaritmiskandClaude Sonnet 4.6 89132f6745 ci(web): typecheck/lint/test/build + bundle-size budget
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 23:28:36 +02:00
logaritmiskandClaude Sonnet 4.6 7170be016d feat(server): embed SPA via memory-serve behind embed-web feature
Adds `memory-serve` 2.1 as an optional workspace dependency, a `build.rs`
that runs `load_directory` only when `CARGO_FEATURE_EMBED_WEB` is set, a
`web_assets` module serving `web/dist` at `/` with SPA fallback (200 OK)
for unknown client-side routes, and a feature-gated integration test.

The default build (no feature) compiles and tests cleanly without `web/dist`.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 23:22:26 +02:00
logaritmiskandClaude Opus 4.8 1d1be5fbe9 fix(web): hide null flexible-field values instead of rendering 'null'
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 23:17:14 +02:00
logaritmiskandClaude Sonnet 4.6 859f41dcb9 feat(web): object detail + two-pane page + app routing
Implements the navigable SPA shell: object detail pane showing
inventory-minimum fields, flexible fields (via Record<string,unknown>
cast) and visibility badge; ObjectsPage two-pane layout; BrowserRouter
wired through RequireAuth+AppShell; QueryClient provided in main.tsx.
Consolidates ObjectList NavLink to use isActive function form, removing
manual useParams highlight.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 23:13:52 +02:00
logaritmiskandClaude Sonnet 4.6 d6fe0b0597 feat(web): paginated object list with visibility badges and states
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 23:06:42 +02:00
logaritmiskandClaude Sonnet 4.6 684469273f feat(web): app shell with sidebar nav, language switch, sign out
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 23:01:42 +02:00
logaritmiskandClaude Sonnet 4.6 057a00c413 feat(web): login page with inline error handling
Add shadcn input/label/card primitives and implement the login page:
email/password form using useLogin, navigates to /objects on success,
shows inline i18n error on 401 (auth.invalid) or network failure.
2 new tests, 9 total green.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 22:56:17 +02:00
logaritmiskandClaude Opus 4.8 01f43e1f67 fix(web): disable retry on useObject (404 resolves to null)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 22:53:32 +02:00
logaritmiskandClaude Sonnet 4.6 cf02eeb991 feat(web): TanStack Query hooks + session-guarded routes
Installs @tanstack/react-query and react-router-dom; adds typed query
hooks (useMe, useObjectsPage, useObject, useFieldDefinitions, useLogin,
useLogout), a QueryClient+MemoryRouter test render helper, and
RequireAuth — a layout route that blocks unauthenticated access and
redirects to /login. All 7 tests pass, typecheck/lint/build clean.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 22:49:55 +02:00
logaritmiskandClaude Opus 4.8 2e4187c850 test(web): reset i18n to English after the language-switch test
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 22:47:27 +02:00
logaritmiskandClaude Sonnet 4.6 478b4ce44e feat(web): i18n with react-i18next (sv/en)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 22:42:47 +02:00
logaritmiskandClaude Sonnet 4.6 66d0624279 test(web): MSW harness with typed handlers, fixtures, and client tests
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 22:35:55 +02:00
logaritmiskandClaude Sonnet 4.6 dcfddc88c7 feat(web): generated OpenAPI types + typed openapi-fetch client with 401 redirect
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 22:25:10 +02:00
logaritmiskandClaude Sonnet 4.6 5267f05089 fix(web): restore shadcn theme tokens in index.css; tidy deps + eslint rule
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 22:21:58 +02:00
logaritmiskandClaude Sonnet 4.6 b7ec4b1041 feat(web): Tailwind 4 + shadcn/ui + ESLint
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 22:14:12 +02:00
logaritmiskandClaude Opus 4.8 8466ed4d08 chore(web): drop dangling favicon link (runtime 404)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 22:10:29 +02:00
logaritmiskandClaude Sonnet 4.6 f64688a16f feat(web): scaffold Vite + React + TS SPA with Vitest
Bootstraps the web/ SPA: Vite 6 + React 19 + TypeScript 5.8, Vitest
with jsdom, @testing-library/react, and a green smoke test asserting
the App renders its Collection heading.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-03 22:06:03 +02:00
logaritmiskandClaude Opus 4.8 a177b02145 docs(plan): frontend SPA milestone 1 — task-by-task implementation plan
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 21:56:54 +02:00
logaritmiskandClaude Opus 4.8 31e2a3f30a docs(spec): frontend SPA milestone 1 (foundation slice) design
Decomposes the admin SPA into milestones; specs M1 — web/ scaffold,
Vite+React+TS+pnpm+shadcn/ui, openapi-typescript+openapi-fetch typed
client, TanStack Query, react-i18next (sv/en), two-pane master-detail
layout, login/session guard, read-only Objects browse, Vitest+RTL+MSW
tests, memory-serve embed behind a feature gate, 150KB bundle budget.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-03 21:50:30 +02:00
logaritmiskandClaude Opus 4.8 8cfcf07387 fix(db): publish gate fires only on transition into public, not re-set
Preserves the documented set-to-current idempotent no-op: re-setting an
already-public object's visibility no longer rejects when a required field
was introduced after publish. Adds a regression test.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 23:40:10 +02:00
logaritmiskandClaude Opus 4.8 e96f74f47a feat(db): enforce required-field completeness on publish (#16)
set_visibility now gates the transition to Public: every field definition
with required=true must have a value on the object (typed inventory-minimum
columns are already NOT NULL, so only flexible required fields are checked).
Missing values yield VisibilityError::MissingRequiredFields(keys); the admin
publish endpoint maps it to 422. The gate runs in db so every caller is
protected and the check is atomic with the transition.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 23:36:24 +02:00
logaritmiskandClaude Opus 4.8 4921c73fa7 style(api): import reindex into scope rather than crate::-qualify
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 23:29:50 +02:00
logaritmiskandClaude Opus 4.8 d15afda9b2 feat(api): on-write search reindex after catalogue writes (#17)
Wire best-effort Meilisearch index sync into the admin write paths
(create/update/delete/set_fields/set_visibility). Adds
SearchClient::sync_object (reindex if the object exists, remove if gone —
one uniform path), an optional AppState.search client, and a reindex
helper that logs failures via tracing without failing the committed
write. Server gains MEILI_URL/MEILI_MASTER_KEY/MEILI_INDEX config;
search stays disabled (no-op) when unset. reindex_all remains the
recovery path.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 23:25:43 +02:00
logaritmiskandClaude Opus 4.8 c4e0c4c834 style(api): merge use decl; assert status + breathing room in authority test
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 22:39:36 +02:00
logaritmiskandClaude Sonnet 4.6 01abd5cbbc feat(api): admin authority management (create + list by kind)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 22:33:44 +02:00
logaritmiskandClaude Opus 4.8 d81b069b8f style(api): merge use decl; breathing-room blank in vocab test
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 22:29:51 +02:00
logaritmiskandClaude Sonnet 4.6 7a18e0e9bf feat(api): admin vocabulary + term management
GET/POST /api/admin/vocabularies and GET/POST /api/admin/vocabularies/{id}/terms;
reads gated on ViewInternal, writes on EditCatalogue; labels round-trip verified.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 22:20:47 +02:00
logaritmiskandClaude Sonnet 4.6 8b929c7180 refactor(api): descriptive closure params; exhaustive FieldError match; field-endpoint auth tests
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 22:16:50 +02:00
logaritmiskandClaude Sonnet 4.6 b6a30c3995 feat(api): admin set flexible fields + field-definition listing
- GET /api/admin/field-definitions (ViewInternal) — lists all registered
  field definitions with key, data_type, vocabulary_id, authority_kind,
  required, group, and localized labels
- PUT /api/admin/objects/{id}/fields (EditCatalogue) — replaces an
  object's flexible-field values with replace semantics; validates every
  key against the registry (UnknownField → 422, TypeMismatch → 422,
  Unresolved → 422, ObjectNotFound → 404, Db → 500)
- FieldDefinitionView DTO added; both handlers registered in OpenAPI

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 22:09:43 +02:00
logaritmiskandClaude Sonnet 4.6 34e5754815 refactor(api): read object visibility inside update tx; breathing-room nits
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 22:05:54 +02:00
logaritmiskandClaude Sonnet 4.6 3f4da46b78 feat(api): admin object create/update/delete (EditCatalogue, audited as user)
POST /api/admin/objects (draft|internal only; public rejected 422),
PUT /api/admin/objects/{id} (preserves visibility; 204/404),
DELETE /api/admin/objects/{id} (204/404). Every write records
AuditActor::User(<session-user-uuid>). Tests: lifecycle, public-rejection,
unauthenticated-rejection.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 21:59:14 +02:00
logaritmiskandClaude Sonnet 4.6 1888e185f7 refactor(api): share Pagination across admin/public; cover get-by-id auth
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 21:53:21 +02:00
logaritmiskandClaude Sonnet 4.6 0055616099 feat(api): admin object read surface (paginated list + get, ViewInternal)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 21:45:53 +02:00
logaritmisk 3dc621b6dd docs(plans): admin CRUD — object lifecycle + vocab/authority management 2026-06-02 19:02:47 +02:00
logaritmisk 807ac1a9f8 chore: sync Cargo.lock with auth dependencies 2026-06-02 15:21:03 +02:00
logaritmisk 5cfee93037 merge: authentication (email/password) — sessions, extractors, admin surface, CLI bootstrap 2026-06-02 15:20:36 +02:00
logaritmisk 369eee4098 fix(server): --session-cookie-secure flag; scope+char-count password; invalid-email test 2026-06-02 15:16:46 +02:00
logaritmiskandClaude Sonnet 4.6 dbff95c2a9 feat(server): create-user CLI + session-store migration on startup
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 15:07:58 +02:00
logaritmisk 642f709bbe fix(api): drop redundant dev-deps; fix server AppState for cookie_secure; add logout + illegal-transition tests 2026-06-02 15:04:07 +02:00
logaritmiskandClaude Sonnet 4.6 5135aeee6c feat(api): admin auth surface (login/logout/me/users/publish) on tower-sessions
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 14:54:03 +02:00
logaritmisk 4e7288731a harden(auth): distinguish session-store failure (500) from absent session (401); exhaustive marker + verify_dummy tests 2026-06-02 14:48:40 +02:00
logaritmiskandClaude Sonnet 4.6 992526ef77 feat(auth): argon2id hashing + AuthUser/Authorized<Cap> session extractors
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 14:45:13 +02:00
logaritmisk bea9b6b39a harden(db): case-insensitive email unique index + dup-email test; list_users pagination TODO; from_db note 2026-06-02 14:42:04 +02:00
logaritmiskandClaude Sonnet 4.6 f8ec2d7cf1 feat(db): users table + repository (create/by_id/by_email/list), audited
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 14:37:43 +02:00
logaritmisk 9597a42eeb fix(domain): make Editor capability policy fail-closed (exhaustive match) 2026-06-02 14:32:13 +02:00
logaritmiskandClaude Sonnet 4.6 74b2cf65ed feat(domain): user identity (UserId, Email), Role/Capability policy
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 14:29:04 +02:00
logaritmisk 1ed9798a1f docs(plans): authentication (email/password) — sessions, extractors, CLI bootstrap 2026-06-02 14:26:19 +02:00
logaritmisk 6cd01f9b97 merge: publishing — visibility transitions, PublicView & public read API 2026-06-02 14:04:32 +02:00
logaritmisk 1b48f082ee chore: sync Cargo.lock after dropping api's uuid dep 2026-06-02 14:04:32 +02:00
logaritmisk 720c7ddbbf chore(api): drop unused uuid dep + redundant domain dev-dep; test internal exclusion + note list/count race 2026-06-02 13:55:01 +02:00
logaritmisk 3c4ada202f feat(api): public read API (PublicView projection, paginated list + get, OpenAPI) 2026-06-02 13:48:17 +02:00
logaritmiskandClaude Sonnet 4.6 b948cae269 refactor(db): share update path so set_visibility avoids a redundant fetch; tie public-visibility const to the enum; test internal exclusion
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 13:35:36 +02:00
logaritmiskandClaude Sonnet 4.6 14cdd2a04a feat(db): audited stepwise set_visibility + public-only object readers
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 13:24:29 +02:00
logaritmisk 5e2ebbc8d9 test(domain): assert IllegalTransition Display message 2026-06-02 13:14:37 +02:00
logaritmiskandClaude Sonnet 4.6 59400062ae feat(domain): stepwise Visibility state machine (transition_to + IllegalTransition)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 13:11:01 +02:00
logaritmisk 5ea1febb91 docs(plans): publishing — visibility transitions, PublicView, public read API 2026-06-02 12:50:31 +02:00
logaritmisk f0e00fba40 merge: search (Meilisearch full-text over catalogue objects) 2026-06-02 12:35:37 +02:00
logaritmisk fac4b703ff docs(search): document eventual-consistency model; drop stale Task 2 note 2026-06-02 12:15:18 +02:00
logaritmisk 4bafac397a docs(search): note why reindex test references db crate migrations 2026-06-02 12:12:12 +02:00
logaritmiskandClaude Sonnet 4.6 7b91989411 feat(search): build documents resolving term/authority labels; reindex_all
Implements build_document in the search crate: resolves Term and Authority
flexible-field values to their human-readable labels so reindex_all produces
documents that Meilisearch can match on label text, not raw UUIDs.
Adds integration test covering the full reindex→search round-trip.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 12:08:07 +02:00
logaritmiskandClaude Sonnet 4.6 b8d198f150 fix(search): surface failed Meilisearch tasks; make ensure_index idempotent
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 11:50:58 +02:00
logaritmiskandClaude Sonnet 4.6 dc903989f7 feat(search): add Meilisearch-backed SearchClient (index, search, remove)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 11:43:53 +02:00
logaritmiskandClaude Opus 4.8 851181d91d docs: add Plan 6 (Meilisearch search) implementation plan
search crate (SearchClient adapter) indexing core + flexible fields with
term/authority resolved to labels; reindex_all; on-write sync deferred to API.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 11:39:55 +02:00
logaritmisk 5ee9fd88f1 polish(db): clearer maker label; assert group_key and vocabularies in seed tests 2026-06-02 11:25:10 +02:00
logaritmiskandClaude Sonnet 4.6 adc7c61ee2 feat(db): seed a representative Spectrum cataloguing field set (idempotent)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 11:20:35 +02:00
logaritmiskandClaude Opus 4.8 91a9eb2964 docs: add Spectrum cataloguing seed plan
Idempotent seed of a representative subset: 3 vocabularies + 12 descriptive field
definitions with term/authority bindings. Empty vocabularies; wiring deferred.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 11:17:56 +02:00
logaritmisk f30ce9d9dc docs(db): note deferred date-format validation (#11) at the Date field arm 2026-06-02 11:12:00 +02:00
logaritmiskandClaude Sonnet 4.6 45c1d1b123 test(db): cover authority-kind, cross-vocabulary, localized text, replace/remove, no-op, missing object
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 11:07:43 +02:00
logaritmiskandClaude Sonnet 4.6 c94fd1638c docs(db): document set_object_fields replace semantics and required-field deferral
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 11:04:45 +02:00
logaritmiskandClaude Sonnet 4.6 2b0056c038 feat(db): set_object_fields with registry validation and audited diffs
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 10:59:23 +02:00
logaritmiskandClaude Opus 4.8 2aaf98794f feat(db): add object.fields jsonb column, read it into CatalogueObject
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 10:54:49 +02:00
logaritmiskandClaude Opus 4.8 7b0f804461 docs: add Plan 5 (Object flexible-field values) implementation plan
object.fields jsonb + set_object_fields with registry validation (type +
term/authority resolution) + audited per-field diffs; typed FieldError.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 10:52:38 +02:00
logaritmisk f4152b2102 test(db): cover any-kind authority, scalar, zero-label, and list ordering for field definitions 2026-06-02 10:27:06 +02:00
logaritmiskandClaude Sonnet 4.6 66ad67ca77 feat(db): add field-definition registry repository
Implements create_field_definition, field_definition_by_key, and
list_field_definitions in db::fields, with TDD integration tests
covering text, term, and authority field type round-trips.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 10:21:39 +02:00
logaritmiskandClaude Sonnet 4.6 cbed662c18 feat(db): add field_definition tables
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 10:16:30 +02:00
logaritmisk 6e27288f43 fix(domain): make FieldType::from_parts a strict inverse; reject stray bindings 2026-06-02 10:15:07 +02:00
logaritmiskandClaude Sonnet 4.6 2242ff5ef1 feat(domain): add field definition types (FieldType, FieldDefinition)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 10:11:28 +02:00
logaritmiskandClaude Opus 4.8 da2db11a30 docs: add Plan 4 (Field-definition registry) implementation plan
Type-driven FieldType enum carrying binding; field_definition + labels tables with
a CHECK enforcing term<->vocabulary; create/read/list repository.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 10:09:46 +02:00
logaritmiskandClaude Sonnet 4.6 2938649d62 fix(db): skip UPDATE and audit on no-op object update (keep updated_at consistent)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 09:40:27 +02:00
logaritmisk a690c60ec6 refactor(db): delete_object via rows_affected; test update/delete-missing and field clearing 2026-06-02 09:36:44 +02:00
logaritmiskandClaude Sonnet 4.6 9e1c88b294 feat(db): add catalogue object update/delete with audited field diffs
update_object records only changed fields as audit diffs and skips the
audit entry for no-op updates; delete_object records a Deleted entry.
Both operations are atomic on the caller's connection.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 09:32:16 +02:00
logaritmiskandClaude Sonnet 4.6 616a6f05c6 refactor(db): DRY object SELECT columns, consistent date json; test date + all-none round-trip
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 09:29:40 +02:00
logaritmiskandClaude Sonnet 4.6 e0c0187f29 feat(db): add catalogue object create/read/list with audit on create
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 09:24:03 +02:00
logaritmisk 95357f01dd feat(db): non-empty CHECK constraints on object text columns 2026-06-02 09:21:08 +02:00
logaritmiskandClaude Sonnet 4.6 c1dda280e2 feat(db): add object table
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 09:18:03 +02:00
logaritmisk bf332ac0ae test(domain): pin Visibility serde output to as_str 2026-06-02 09:16:53 +02:00
logaritmisk 266f914b88 feat(domain): add catalogue object types (Visibility, ObjectInput, CatalogueObject) 2026-06-02 09:13:54 +02:00
logaritmiskandClaude Opus 4.8 ed608c6e37 docs: add Plan 3 (Catalogue core) implementation plan
Typed inventory-minimum object record + CRUD; first consumer of the audit spine
(create/update/delete record audit entries with field-level diffs in the write tx).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-02 09:12:41 +02:00
logaritmisk 7782bd764a test(db): zero-label authority round-trip; doc the labels-json constant
Also fix pre-existing clippy::explicit_auto_deref in all db test files
(&mut *tx → &mut tx across authority.rs and vocab.rs).
2026-06-02 09:01:06 +02:00
logaritmiskandClaude Sonnet 4.6 6e45baa8d4 feat(db): add authority repository with multilingual labels
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-02 08:55:50 +02:00
logaritmisk 345073b130 test(db): cover zero-label term and duplicate vocabulary key; use try_get in vocabulary_by_key 2026-06-02 08:52:58 +02:00