Skip to content

[Event Request] codeunit 905 "Assembly Line Management" procedure ShowAvailability() #30258

@kmistrytnp

Description

@kmistrytnp

Why do you need this change?

In certain circumstances I want to be able to either skip showing the availability page when the QtyAvailToLow is true and/or the ShowPageEvenIfEnoughComponentsAvailable is true. In other circumstances I want to show an error when the QtyAvailToLow is true and/or the ShowPageEvenIfEnoughComponentsAvailable is true.

I've tried using the OnBeforeShowAvailability() event at the start but can't achieve what I want because I would need to call the CopyInventoriableItemAsmLines and AvailToPromise procedures in order to calculate QtyAvailTooLow, but they are currently local. I have also tried replicating them but I can't because AvailToPromise calls other procedures which are local.

Describe the request

Please can you add the following event/code after the QtyAvailTooLow boolean field has been set...

OnAfterQtyAvailTooLowCalculated(TempAssemblyHeader, TempAssemblyLine, ShowPageEvenIfEnoughComponentsAvailable, IsHandled, Rollback, WarningModeOff);
if IsHandled then
    exit(Rollback);

The event publisher would be...

[IntegrationEvent(false, false)]
local procedure OnAfterQtyAvailTooLowCalculated(var TempAssemblyHeader: Record "Assembly Header" temporary; var TempAssemblyLine: Record "Assembly Line" temporary; ShowPageEvenIfEnoughComponentsAvailable: Boolean; var IsHandled: Boolean; var RollBack: Boolean; WarningModeOff: Boolean)
begin
end;

Internal work item: AB#638445

Metadata

Metadata

Assignees

No one assigned

    Labels

    SCMGitHub request for SCM areaevent-requestRequest for adding an event

    Type

    No fields configured for Task.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions