feat(parser): attach modifier lines to their item #109
No reviewers
Labels
No labels
area:backend
area:frontend
area:infra
area:ocr
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
phase:M1
phase:M2
phase:M3
phase:M4
phase:M5
phase:M6
phase:M7
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
TJC/bill-splitter!109
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feat/97-modifier-attach"
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?
Summary
ModifierMergerpre-pass that folds amount-less modifier lines (+ Bacon,No Onion,Extra Sauce) into the priced line above them, splicing the note ahead of the trailing amount run so the item reads enriched (Burger + Bacon No Onion) with its price unchangedWrappedNameMergerpre-pass (#111): wrapped names assemble first, then modifiers attach to whole priced rows; the wrapped-name pass steps over a leading+/*note so a modifier printed between a name and its price does not lose the item+/*additions or a shortNO/EXTRA/ADD/HOLD/SUB/LESS/W/O/WITHOUTkeyword form attach, and never a form naming a payment/status footer or a bill extra (service,gratuity,tip,tax,discount, ...) - soNo payment receivedandAdd Gratuitystay put instead of flipping the item to a bill lineReceiptPatterns.Money) between the engine and the modifier pass so the splice boundary cannot drift from what the engine reads as a pricedocs/15(a non-indented keyword modifier, an out-of-order note); updatedocs/06,docs/11,docs/15Test plan
dotnet test backend/tests/BillSplitter.Tests/BillSplitter.Tests.csproj- 99 pass; existing corpus byte-for-byte green, including the threeNo payment receivedfixtures and #111's wrapped-name fixturesburger-modifiers,modifier-footnote,modifier-keyword-footer,modifier-nameless-price,modifier-between-wrapped-name,modifier-unit-price-columnCloses #97