Repository navigation
Conversation
…n when the deposit is waived (RED) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…on when no deposit notice was issued Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ine deal's remaining invoice Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This was referenced Oct 23, 2026
Owner
Author
This branch was successfully deployed
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.
Draft. P0-4 from the 2026-10-22 release review. A new-engine deal on a deposit-bypass policy (CREDIT_CUSTOMER / WAIVED / NOT_REQUIRED) could never get ใบแจ้งหนี้ส่วนที่เหลือ: the shared resolver knew only an ISSUED deposit notice or a legacy quotation +
ticket_item.approved_price, which the new engine never writes. Pairs with #1173 (0% quotation → NOT_REQUIRED).Change (+47 lines, 2 files)
DepositNoticeRepository:findAcceptedDealQuotationLines(ticketId)— newest ACCEPTED new-engine quotation's lines with the storedamount.DepositNoticeService#resolveRemainingInvoice: one new branch, fires only under a bypass policy with no ISSUED notice, before theapproved_pricefallback. ServesgetRemainingInvoiceOptions,createDraft,issue. Legacy and notice paths unchanged.Test-first
da839dc7tests (RED):DealQuotationOutcomeIntegrationTest, 1 error / 37 pass —remainingInvoice_newEngineAcceptedQuotation_depositWaived_sourcesTheQuotationsLines_andIssues→ ApiException 409ไม่พบใบเสนอราคาที่ลูกค้ายอมรับ…atresolveLegacy:730.c8f479c9fix → 38/0/0. Wider: DepositNoticeServiceTest 48, RemainingInvoiceServiceIT 28, OrderConfirmationIT 13, PaymentTrackIT 14, BillingNoteServiceIT 58, DealQuotationConfirmOrderIT 31, +7 smaller classes, 0 failures.8ad1ae62guard assertion (green before and after, by design).Coverage
…depositWaived_sourcesTheQuotationsLines_andIssues…issuedNotice_linesAndDeductionStillComeFromTheNotice_alsoUnderABypassPolicydepositNoticeIdset; still true once the policy reads as a bypass; REQUIRED + no notice → 409…QuotationOnlyIssued_depositWaived_still409…nonOwnerSales_refused_writesNothingMutations (implementer 8 + reviewer 4), each killed by a named test except
drop ORDER BY…LIMIT 1(equivalent: a deal cannot hold two ACCEPTED quotations).Not covered: mixed legacy + new-engine ticket (legacy wins, as before); DEAL_DIRECT route; revision after acceptance; account-side issue flow; multi-line ordering; EN/USD quotations.
Opus review (2026-10-23): APPROVE WITH NOTES — owner rulings pending
doc_status='ACCEPTED', but a DEAL_DIRECT quotation only ever reaches APPROVED (DealQuotationRepository:1292;recordOutcomerefuses that origin). After fix(sales): a no-deposit quotation puts the deal on the no-deposit payment path #1173 moves 0% direct deals to NOT_REQUIRED they still 409 here. Option:(PRICING_REQUEST AND ACCEPTED) OR (DEAL_DIRECT AND APPROVED)as the deposit autofill already does.computeRemainingInvoiceMoneyapplies flat 7% VAT (DepositNoticeService:394), so this path now ISSUES a THB-labelled invoice with VAT on USD lines where before it 409'd (probe: 91,233.09 → 97,619.41). Suggest blockingdocument_language='EN'in the new branch.blockingReasonlike the legacy "ยังไม่ได้ออกใบแจ้งยอดมัดจำจากใบเสนอราคา X". ~3 lines.Merge order: conflicts with #1170 and #1173 in
DealQuotationOutcomeIntegrationTest.javaonly; a hunk-level keep-both DROPS a closing brace each time (130/129, 132/131). Resolve by taking each side's method block whole and adding the}. Production files merge clean.🤖 Generated with Claude Code