ALAppExtensions icon indicating copy to clipboard operation
ALAppExtensions copied to clipboard

[Paramenter Request] Codeunit 22 Item Jnl.-Post Line - OnBeforePostInventoryToGL

Open aobsgit opened this issue 6 years ago • 1 comments

Hi, Could you please add "IsHandled" parameter to existing event OnBeforePostInventoryToGL in CU22. We are using our own procedures do post inventory to GL that is why we need to call a different CU. Hooking on events in existing CU5802 is not an option unfortunately.

local procedure PostInventoryToGL(var ValueEntry: Record "Value Entry") begin with ValueEntry do begin if CalledFromAdjustment and not PostToGL then exit;

OLD START OnBeforePostInventoryToGL(ValueEntry); OLD END

NEW START IsHandled := false; OnBeforePostInventoryToGL(ValueEntry,IsHandled); if IsHandled then exit; NEW END

        InventoryPostingToGL.SetRunOnlyCheck(true, not PostToGL, false);
        PostInvtBuffer(ValueEntry);

. . .

old event: [IntegrationEvent(false, false)] local procedure OnBeforePostInventoryToGL(var ValueEntry: Record "Value Entry") begin end;

new event: [IntegrationEvent(false, false)] local procedure OnBeforePostInventoryToGL(var ValueEntry: Record "Value Entry"; var IsHandled: Boolean) begin end;

aobsgit avatar Sep 24 '20 13:09 aobsgit

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. We will update this issue with information about availability.

bc-ghost avatar Oct 02 '20 06:10 bc-ghost