code change · fixService Managementofficial - Microsoftreviewed - checked by Opus

#11026 Service Line CalcVATAmountLines: count VAT Difference once and clear filters before OnAfterCalcVATAmountLines

Service Line CalcVATAmountLines now counts VAT differences correctly and clears filters before firing the OnAfterCalcVATAmountLines event, matching the behavior of Sales and Purchase lines.

Pull request · merged into main (BC30) on 2026-11-18 by Franco111000 (community contribution) · 6 files (+656 -6), 2 AL · fix · tier official · reviewed (checked by Opus)

What changed

  • Fixed VAT difference being counted twice in the accumulation by removing redundant term
  • Added VATAmountLine.Reset() before OnAfterCalcVATAmountLines event to ensure unfiltered records
  • Aligns Service Line implementation with Sales Line and Purchase Line behavior
  • Applied fix to both W1 and NA table layers
  • Added two regression tests covering VAT difference counting and filter clearing scenarios
  • Behaviour changes for users or extensions.

AL objects touched

Context

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