Why do you need this change?
Hi,
Starting from BC 28.1, a change in the Base Application affects the behavior of the OnValidate trigger of the "Description" field in the Sales Order Subform (Page 46).
The current implementation introduces functional regressions, especially for extensions relying on in-memory modifications of Sales Line.
The code modification causes the recalculation of all totals in the document; this is an excessive and not necessarily use of logic, that could be reduced only if relevant line fields are changing.
Current behavior
DeltaUpdateTotals is executed before the following check:
if Rec."No." = xRec."No." then
    exit;
Causes unnecessary executions even when the Item No. is unchanged.
A new procedure CalculateTotals is invoked:
- Triggers a full document recalculation
- Performs record reload from the database
Due to the reload:
- Any in-memory changes on Sales Line are lost, unless explicitly persisted before validating "Description"
Describe the request
Move at least the following procedures:
DeltaUpdateTotals
CalculateTotals
after:
if Rec."No." = xRec."No." then
    exit;
This ensures:
- Execution only when the Item No. changes
- Reduced unnecessary recalculations
- Preservation of in-memory Sales Line modifications
@Andrea-Antolini-EOS
@Thomas-Torggler-EOS
Internal work item: AB#638322
Why do you need this change?
Hi,
Starting from BC 28.1, a change in the Base Application affects the behavior of the OnValidate trigger of the "Description" field in the Sales Order Subform (Page 46).
The current implementation introduces functional regressions, especially for extensions relying on in-memory modifications of Sales Line.
The code modification causes the recalculation of all totals in the document; this is an excessive and not necessarily use of logic, that could be reduced only if relevant line fields are changing.
Current behavior
DeltaUpdateTotals is executed before the following check:
Causes unnecessary executions even when the Item No. is unchanged.
A new procedure CalculateTotals is invoked:
Due to the reload:
Describe the request
Move at least the following procedures:
DeltaUpdateTotals
CalculateTotals
after:
This ensures:
@Andrea-Antolini-EOS
@Thomas-Torggler-EOS
Internal work item: AB#638322