Repository navigation
docs(o2c): a first confirm is checked against Received and Invoiced too (#2839) - #2852
Merged
objectstack-fleet[bot] merged 2 commits intoNov 29, 2026
Merged
Conversation
…oo (#2839) The invoices-and-payments manual (en, zh-Hans, zh-Hant) and the Order to Cash in-app page said a first confirm is never checked. The rule judges every Draft -> Confirmed move, and a payment or an invoice can name an order still in Draft, so a never-confirmed order above its total is refused like a re-confirm. The text now follows the rule; the rule is unchanged. The rule's comment and the test header are corrected, and a test pins the first-confirm refusal (received and invoiced) with a control. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J8VVAk8tegvAi1ECkgCFfc
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
Author
|
repo:hotcrm#1 · huangyiirene · session_01J8VVAk8tegvAi1ECkgCFfc ACCEPT · 2026-11-29T03:09ZHead-sha: 维护者速读
席位核对
|
Contributor
Author
|
repo:hotcrm#1 · huangyiirene · session_01J8VVAk8tegvAi1ECkgCFfc CI · 2026-11-29T03:16Z · Test shard 2 / Build and Test (22.x) red on
|
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J8VVAk8tegvAi1ECkgCFfc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by Irene · project thread
Fixes #2839
Clause-②: no
Metadata-protocol: none
Metadata-impact: reviewer — text only (doc pages, an in-app manual page and a code comment); no rule, field or permission changes
Ruling-ref: maintainer on the project thread's decision card, 2026-11-29T02:32Z: 「改手册,规则不动」 (the text follows the rule; the rule is unchanged)
维护者速读
What changes
src/o2c/extensions/sales-order.extension.ts: the rule's comment no longer equates a first confirm with "nothing invoiced or received". Comment only; the CEL source is byte-identical.test/sales-order-reconfirm-floor.test.ts: header comment corrected; the existing first-confirm case renamed to what it shows ("passes", not "is not judged"); one new case.Tests
New case: a never-confirmed Draft order at 8,000 with a 10,000 payment is refused on its first confirm with 400
VALIDATION_FAILED,fields[0]ontotal_price/rule_violationwith the Received message, and stays Draft; the same with a 5,000 order and a 9,000 invoice (Invoiced message); control: a 12,000 order with a 10,000 payment confirms (200). It pins current behaviour on main's rule: the rule is unchanged, so there is no rule ablation (the test is green before and after this PR by design).Test and verification readings
All on head
264544fe, each throughos-verify-lock.sh:pnpm exec vitest run --maxWorkers=2 test/sales-order-reconfirm-floor.test.ts: Test Files 1 passed (1), Tests 6 passed (6); VERDICT command-exit 0.pnpm validate && pnpm typecheck && pnpm lint: "Validation passed";tsc --noEmitsilent;objectstack lint --strict"54 suggestion(s)", no errors; VERDICT command-exit 0.pnpm test(full suite): Test Files 345 passed (345), Tests 6595 passed, 58 skipped (6653); VERDICT command-exit 0 (29m33s).Acceptance notes
content/docs/(start)/whats-new*.mdx) say "Confirming again is refused when the new total ..." / 「再次确认时…」. That is true of a re-confirm and silent on a first confirm; it describes the 6.7.0 release item, so it is left as written.Verification
Read first:
content/docs/(product)/order-to-cash/invoices-and-payments.mdxline 43 (the wording the other four follow), then the zh-Hant line 45 (field labels kept English per the zh-Hant convention), then the new test case.Two-minute check:
pnpm exec vitest run test/sales-order-reconfirm-floor.test.tsshows 6 tests passed, including "a never-confirmed Draft order is judged on its first confirm, received or invoiced (#2839)".🤖 Generated with Claude Code
https://claude.ai/code/session_01J8VVAk8tegvAi1ECkgCFfc