---
id: change/bcapps/11095
type: change
title: "#11095 [main] Bug 649204 Validation missing for Deferral Code field on Released Purchase documents."
summary: Deferral Code field on released purchase line documents now validates that the purchase header status is open, preventing modification of deferrals on non-open purchase records.
tier: official
language: en
tags:
  - fix
  - main
  - bc30
  - table purchase line
system: purchasing
review:
  state: reviewed
  by: opus
  at: "2026-10-08T02:05:53.727Z"
  flags: []
generated:
  at: "2026-10-08T01:26:53.141Z"
  pipeline: 0.2.0
  prompts:
    extract-change: 1
  input_hash: 3044d5156dd596da7360083a30a2c9d10ec5b28a
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/pull/11095
    title: "microsoft/BCApps#11095: [main] Bug 649204 Validation missing for Deferral Code field on Released Purchase documents."
    date: "2026-09-10"
    commit: 3044d5156dd596da7360083a30a2c9d10ec5b28a
    t: null
    quote: Status must be equal to 'Open' in Purchase Header validation missing for Deferral Code field on Released Purchase documents.
links:
  learn: []
  objects:
    - object/table/39
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
  changes: []
number: 11095
repo: microsoft/BCApps
source_id: bcapps-prs
url: https://github.com/microsoft/BCApps/pull/11095
kind: pr
base_branch: main
major: "30"
merged_at: "2026-09-10T06:25:58Z"
author: MSNehaNawal
author_type: User
community_contribution: false
labels:
  - "Team: SCM"
change_class: code
change_kind: fix
behavior_change: true
breaking: false
files:
  count: 18
  additions: 157
  deletions: 0
  al: 14
apps:
  - Base Application
objects_touched:
  - key: table/39
    page: table/39
    type: table
    id: 39
    name: Purchase Line
    app: Base Application
    status: modified
objects_unjoined: []
obsoletions: []
backports: []
fixes_issues: []
work_items:
  - 649204
systems:
  - purchasing
quote: Status must be equal to 'Open' in Purchase Header validation missing for Deferral Code field on Released Purchase documents.
joined_against:
  major: "30"
  commit: ecbc028c25dbe83b61313bc566e6c1d41184bb1c
---

# #11095 [main] Bug 649204 Validation missing for Deferral Code field on Released Purchase documents.

> Deferral Code field on released purchase line documents now validates that the purchase header status is open, preventing modification of deferrals on non-open purchase records.

[Pull request](https://github.com/microsoft/BCApps/pull/11095) · merged into `main` (BC30) on 2026-09-10 by MSNehaNawal · 18 files (+157 -0), 14 AL · fix · tier official · reviewed (checked by Opus)

## What changed

- Added the missing TestStatusOpen check to the Deferral Code field on Purchase Line
- Changing Deferral Code on a released purchase document now fails with 'Status must be equal to Open'
- Applied in W1 and the country-specific Purchase Line tables
- Tests added in W1, IT, NA and RU
- Behaviour changes for users or extensions.

## AL objects touched

- [Table 39 "Purchase Line"](../../objects/table/39.md), Base Application: modified

## Context

- Work items: AB#649204
- Labels: Team: SCM
- Systems: purchasing
- From the description: "Status must be equal to 'Open' in Purchase Header validation missing for Deferral Code field on Released Purchase documents."

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