Skip to content

docs: quotes and projects pages match the code - #92

Merged
futurebuildai merged 4 commits into
refactor/v1from
refactor/docs-drift-quotes-projects
Oct 10, 2026
Merged

futurebuildai merged 4 commits into
refactor/v1from
refactor/docs-drift-quotes-projects

Conversation

@futurebuildai

Copy link
Copy Markdown
Contributor

Summary

Documentation drift fix for docs/modules/quotes.md against the code on origin/refactor/v1 at commit 14e12faa48b25bdee76275107695ef2720d24635. docs/modules/projects.md had no drift; it is unchanged in this PR.

Changes (each with its evidence)

docs/modules/quotes.md

Change Old sentence Evidence
Corrected lifecycle intro "The lifecycle spans draft, sent, accepted, rejected, expired and reopened, every transition writing one outbox event." to "The lifecycle spans draft, sent, accepted, rejected and expired; rejected and expired reopen to draft, every transition writing one outbox event." core/internal/quote/model.go L23-27 declares QuoteStateDraft|Sent|Accepted|Rejected|Expired; core/api/fragments/quote.yaml L693-696 quotes the wire enum as [draft, sent, accepted, rejected, expired]. reopened is an event name (core/internal/quote/service.go L73 EventReopened = "quote.reopened"), not a status.
Corrected QuoteLine.uom description "uppercase enum PCS, EA, LF, ..." to "uppercase pattern, regex ^[A-Z]{1,6}$, a code from the units catalogue (ADR 0006 section 2.1: 23 seeded codes; dealers add their own). On a product line the value must be one of the product's own sale units (ADR 0006 section 3.4)." core/api/fragments/quote.yaml L934-939 declares QuoteUom as pattern: '^[A-Z]{1,6}$', not an enum. core/migrations/099_units_catalogue_and_sets.sql L71-93 inserts 23 seeded codes including DOZ, C, M, CF, CY, CWT, TON that the page omitted. ADR 0006 section 2.1 describes the open-ended catalogue.
Added PUT /api/v1/quotes/{id}/file route added as a new table row: "Attach the AI parse's original file after promotion, on the client's revision; application/octet-stream body, 5 MiB bound; only while the quote is a draft, else 409 with the quote_not_draft blocker." core/api/ROUTES.txt L382 PUT /api/v1/quotes/{id}/file internal/quote h.HandleAttachFile; core/api/fragments/quote.yaml L598-656; core/internal/quote/handler.go L57, L395.
Added drafts route cross reference appended a paragraph below the exposure paragraph noting that the seven /api/v1/drafts/quotes[...*] paths live in internal/quote per the route census but belong to the drafts module (docs/modules/drafts.md). core/api/ROUTES.txt L198-204 lists seven routes under internal/quote. docs/modules/drafts.md L147-153 documents them.
Added QuoteLine.stock_uom, stock_quantity, tally rows three new rows in the QuoteLine table. core/api/fragments/quote.yaml L867 declares them required; L879-897 defines them with references to ADR 0006 sections 3.4 and 4. core/internal/quote/model.go L157-163 declares StockUOM, StockQuantity, Tally on the Go model.

Counts

  • docs/modules/quotes.md: TRUE 38, FALSE 2, UNVERIFIABLE 1, MISSING 8 routes (1 quote + 7 drafts) + 3 fields (QuoteLine stock_uom, stock_quantity, tally).
  • docs/modules/projects.md: TRUE 22, FALSE 0, UNVERIFIABLE 0, MISSING 0 routes + 0 fields. Unchanged.

Suspected defects (for the lead)

None of the drift items are code or fragment defects; each is a page-only claim that contradicts what the fragment, Go model, repository or migration already says. The "reopened" lifecycle claim and the "uppercase enum" claim are page-only mis-statements; the route and field omissions are page-only gaps. No fragment or Go code change is implied.

Checks

  • python3 .github/scripts/reuse_gate.py passes (reuse 6.2.0 already installed).
  • bash scripts/check-shape.sh OK.
  • git diff origin/refactor/v1..HEAD | grep -cP '^\+.*[\x{2013}\x{2014}]' prints 0.
  • git diff origin/refactor/v1..HEAD | grep -c '^+.* -- ' prints 0.
  • git log --format='%ae %ce' origin/refactor/v1..HEAD | sort -u -> colton@futurebuild.ai colton@futurebuild.ai.
  • git log --format=%B origin/refactor/v1..HEAD | grep '^Signed-off-by' | sort -u -> Signed-off-by: colton <colton@futurebuild.ai>.
  • git log -p origin/refactor/v1..HEAD | command grep -nE -e '...' (live credentials check) prints 0.
  • Unsigned-commit scan prints nothing.

🤖 Generated with Claude Code

futurebuildai and others added 4 commits October 10, 2026 15:04
…nits)

Add the PUT /api/v1/quotes/{id}/file entry (HandleAttachFile) and the
drafts route cross reference, both missing from the page. Add the
stock_uom, stock_quantity and tally QuoteLine fields. Correct the
lifecycle intro (reopened is an event, not a status) and the uom
description (regex pattern from the units catalogue, not a 15-code
enum).

Signed-off-by: colton <colton@futurebuild.ai>
…drift-quotes-projects

Signed-off-by: colton <colton@futurebuild.ai>
…ody, list and convert rows

margin_total_cents is what the client sent on create (default 0); the
service copies it through, a PUT refuses it, and nothing sums line
margins. Add the create and update body, the line request, the list
envelope (QuotePage of QuoteSummary), the convert response with its
409 refusals, and the PUT file row with 413, 428, the filename query
parameter, the ETag move, the file_attached audit row, no outbox, and
quotes:write. State that draft routes are gated by quotes:propose and
quotes:commit.

State ProjectItem total_cents is null on a delivery. Add the project
create and update body, the headers and codes, ProjectPage, and the
dashboard project key. Cite ADR 0006 sections 3.2 and 3.3 for the
sale unit rule, drop the unsupported customer currency note, state
freight_cents is cleared for a pickup, and write exposure_cents in
integer cents.

Carry the changes from PR 92 review r1 by Sonnet 5.5.

Signed-off-by: colton <colton@futurebuild.ai>
…d idempotency rules the code applies

Review r2 of PR 92 found five sentences the first fix round added that the
code contradicts. The file route takes no query parameter (noQuery refuses
any) and reads its revision only from If-Match (precondition(r, nil)); the
quote body's lines carry no minimum count; a malformed If-Match is a
bad_request, not validation_failed; and Idempotency-Key is an opt in replay
header, not a required one.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: colton <colton@futurebuild.ai>
@futurebuildai
futurebuildai merged commit 3c178d7 into refactor/v1 Oct 10, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant