Codeunit 20550 Subc. WhsePurchRelease Ext
src/Apps/W1/Subcontracting/App/src/Warehouse/SubcWhsePurchReleaseExt.Codeunit.al31 lines, Copyright (c) Microsoft Corporation. MIT
// ------------------------------------------------------------------------------------------------// Copyright (c) Microsoft Corporation. All rights reserved.// Licensed under the MIT License. See License.txt in the project root for license information.// ------------------------------------------------------------------------------------------------namespace Microsoft.Manufacturing.Subcontracting;using Microsoft.Purchases.Document;codeunit 20550 "Subc. WhsePurchRelease Ext"{ [EventSubscriber(ObjectType::Codeunit, Codeunit::"Whse.-Purch. Release", OnAfterReleaseSetFilters, '', false, false)] local procedure OnAfterReleaseSetFilters(var PurchaseLine: Record "Purchase Line"; PurchaseHeader: Record "Purchase Header")#if not CLEAN29 var#pragma warning disable AL0432 SubcFeatureFlagHandler: Codeunit "Subc. Feature Flag Handler";#pragma warning restore AL0432#endif begin#if not CLEAN29#pragma warning disable AL0432 if not SubcFeatureFlagHandler.IsSubcontractingEnabled() then#pragma warning restore AL0432 exit;#endif PurchaseHeader.CalcFields("Subc. Order"); if PurchaseHeader."Subc. Order" then PurchaseLine.SetRange("Work Center No."); end;}