-
Notifications
You must be signed in to change notification settings - Fork 692
Closed
Closed
Copy link
Labels
SCMGitHub request for SCM areaGitHub request for SCM areaevent-requestRequest for adding an eventRequest for adding an eventships-in-future-updateFix ships in a future updateFix ships in a future update
Description
Why do you need this change?
Hi,
i ask to add the "SalesHeader" record to the existing event "OnBeforeCheckItemTrackingQuantity" in the procedure "CheckItemTrackingQuantity" in the codeunit 80 "Sales-Post".
I need the "SalesHeader" record to control the "Ship" and "Invoice" fields in our custom.
`
local procedure CheckItemTrackingQuantity(var SalesLine: Record "Sales Line"; var SalesHeader: Record "Sales Header")
var
TrackingSpecification: Record "Tracking Specification";
IsHandled: Boolean;
begin
IsHandled := false;
OnBeforeCheckItemTrackingQuantity(SalesLine, IsHandled); <----------- Add SalesHeader
if IsHandled then
exit;
SyncSurPlusItemTracking(SalesHeader, SalesLine);
case SalesHeader."Document Type" of
SalesHeader."Document Type"::Order, SalesHeader."Document Type"::Invoice:
TrackingSpecification.CheckItemTrackingQuantity(DATABASE::"Sales Line", SalesLine."Document Type".AsInteger(), SalesLine."Document No.", SalesLine."Line No.", SalesLine."Qty. to Ship (Base)", SalesLine."Qty. to Invoice (Base)", SalesHeader.Ship, SalesHeader.Invoice);
SalesHeader."Document Type"::"Credit Memo", SalesHeader."Document Type"::"Return Order":
TrackingSpecification.CheckItemTrackingQuantity(DATABASE::"Sales Line", SalesLine."Document Type".AsInteger(), SalesLine."Document No.", SalesLine."Line No.", SalesLine."Return Qty. to Receive (Base)", SalesLine."Qty. to Invoice (Base)", SalesHeader.Receive, SalesHeader.Invoice);
else
OnCheckItemTrackingQuantityOnDocumentTypeCaseElse(SalesHeader, SalesLine);
end;
end;
`
Describe the request
Add the "SalesHeader" record to the existing event "OnBeforeCheckItemTrackingQuantity" in the codeunit 80 "Sales-Post".
`
[IntegrationEvent(false, false)]
local procedure OnBeforeCheckItemTrackingQuantity(SalesLine: Record "Sales Line"; var IsHandled: Boolean; SalesHeader: Record "Sales Header")
begin
end;
`
Internal work item: AB#625399
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
SCMGitHub request for SCM areaGitHub request for SCM areaevent-requestRequest for adding an eventRequest for adding an eventships-in-future-updateFix ships in a future updateFix ships in a future update