Skip to content

[master] Transfer Order header deletion blocked by reserved quantity — inconsistent with line deletion and all other document types#9705

Draft
neeleshsinghal wants to merge 3 commits into
mainfrom
bugs/Bug-643376-Transfer-Order-header-deletion-blocked-by-reserved-quantity
Draft

[master] Transfer Order header deletion blocked by reserved quantity — inconsistent with line deletion and all other document types#9705
neeleshsinghal wants to merge 3 commits into
mainfrom
bugs/Bug-643376-Transfer-Order-header-deletion-blocked-by-reserved-quantity

Conversation

@neeleshsinghal

@neeleshsinghal neeleshsinghal commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Workitem : Bug 643376: [master] [ALL-E] Transfer Order header deletion blocked by reserved quantity — inconsistent with line deletion and all other document types

Fixes AB#643376

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes a BaseApp deletion inconsistency where deleting a Transfer Order header could be blocked by reserved quantities, even though line deletion (and other document types) clear reservations as part of deletion. The change aligns Transfer Line deletion behavior to always clear reservations first, and adds regression tests covering both header- and line-deletion paths.

Changes:

  • Update Transfer Line table OnDelete logic to delete reservation data first, then validate reserved quantities are zero.
  • Add new SCM reservation regression tests validating Transfer Order header deletion succeeds with reserved outbound lines and clears reservations.
  • Apply the same BaseApp Transfer Line deletion fix across W1/NA/RU/IT layer implementations.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/Layers/W1/Tests/SCM/SCMTransferReservation.Codeunit.al Adds regression tests for deleting reserved transfer headers/lines and reservation cleanup.
src/Layers/W1/BaseApp/Inventory/Transfer/TransferLine.Table.al Moves reserved-quantity validation to after TransferLineReserve.DeleteLine(Rec) in OnDelete.
src/Layers/RU/BaseApp/Inventory/Transfer/TransferLine.Table.al Same OnDelete reservation/validation reordering as W1.
src/Layers/NA/BaseApp/Inventory/Transfer/TransferLine.Table.al Same OnDelete reservation/validation reordering as W1.
src/Layers/IT/BaseApp/Inventory/Transfer/TransferLine.Table.al Same OnDelete reservation/validation reordering as W1 (and remove unintended BOM).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Layers/IT/BaseApp/Inventory/Transfer/TransferLine.Table.al Outdated
Comment thread src/Layers/W1/Tests/SCM/SCMTransferReservation.Codeunit.al
Comment thread src/Layers/W1/Tests/SCM/SCMTransferReservation.Codeunit.al
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

SCM GitHub request for SCM area

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants