code change · fixFinanceofficial - Microsoftreviewed - checked by Opus

#13467 [29.x[All-e]Payment Discount with Prices Incl. VAT provides unexpected results in the Spanish version

Spanish version payment discount calculation corrected for prices including VAT by accounting for payment discount amount when recalculating VAT base.

Pull request · merged into releases/29.x (BC29) on 2026-11-12 by sanjmaurya · 3 files (+170 -1), 2 AL · fix · tier official · reviewed (checked by Opus)

What changed

  • Payment discounts now correctly reflected in sales and purchase totals when prices include VAT
  • VAT-inclusive branch now subtracts payment discount amount during VAT base recalculation
  • VAT-exclusive calculations left unchanged to preserve existing behavior
  • Addresses issue when VAT base discount percentage and EC amount are zero
  • Comprehensive test coverage added for payment discount scenarios
  • Behaviour changes for users or extensions.

AL objects touched

Context

  • Work items: AB#657334
  • Labels: Team: Finance
  • Systems: finance, purchasing
  • From the description: “Subtract “Pmt. Discount Amount” when recalculating the VAT base in the VAT-inclusive branch.”

No source states these links: they share an object, a model read them, or a person found the same subject.

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).