#13015 Bug/648925 VAT charged in Sales Invoice with Cash Basis (Unrealized VAT) is not paid on Sales Credit Note applied to that Posted Sales Invoice if we use a similar Cash Basis VAT Prod Posting Group in the Mexican version - regression.
Sales credit memos now correctly realize unrealized VAT from invoices when using equivalent but differently coded VAT posting groups in Cash Basis VAT mode, addressing a regression in the Mexican version.
- 5files
- 2AL files
- 2objects
Pull request · merged into main (BC30) on 2026-11-26 by v-mjofre · 5 files (+2133 -51), 2 AL · fix · tier official · reviewed (checked by Opus)
What changed
- Cash Basis VAT realization logic updated to identify equivalent VAT posting setups between invoices and credit memos
- Equivalence determined by matching VAT business posting groups, calculation types, percentages, and account references
- Supports full and partial credit memos with multiple VAT groups while preserving credit memo VAT posting groups in generated entries
- Prevents unnecessary G/L entries and maintains existing public PostUnrealVATEntry interface
- Automated tests added for full/partial credits, multiple VAT groups, and non-equivalent configurations
- Behaviour changes for users or extensions.
AL objects touched
- Codeunit 12 “Gen. Jnl.-Post Line”, Base Application (CA layer): modified
- Table 21 “Cust. Ledger Entry”, Base Application (CA layer): modified
Context
- Work items: AB#654308
- Labels: Team: Finance
- Systems: finance, sales
- From the description: “Updated the Cash Basis VAT realization logic to identify equivalent VAT posting setups between sales invoices and sales credit memos.”
Possibly related
No source states these links: they share an object, a model read them, or a person found the same subject.
- General Journal Post Line Overview — possibly related: touches Codeunit 12 “Gen. Jnl.-Post Line”
- Types of events for extensibility — possibly related: touches Codeunit 12 “Gen. Jnl.-Post Line”
- Set Up Unrealized VAT for Cash-Based Accounting — possibly related: Documents unrealized VAT setup and cash-based accounting configuration for VAT posting. (model-linked)
Source: metadata of a merged pull request in microsoft/BCApps (bcapps): title, labels, changed paths and counts, with a summary in our words. No source text and no description beyond one short quote (D10, D61).