Codeunit 20530 Subc. Prod. Ord. Comp. Res.
src/Apps/W1/Subcontracting/App/src/Manufacturing/SubcProdOrdCompRes.Codeunit.al40 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.Manufacturing.Document;codeunit 20530 "Subc. Prod. Ord. Comp. Res."{ EventSubscriberInstance = Manual; /// <summary> /// When a transfer is created, the storage location in the production component is swapped and thus triggers the verification.\ /// The verification attempts to perform an auto tracking if the order tracking policy of the item is not equal to None, but this is not possible.\ /// Therefore the verification is overwritten and set to false. /// </summary> /// <param name="NewProdOrderComp"></param> /// <param name="OldProdOrderComp"></param> /// <param name="HasError"></param> /// <param name="ShowError"></param> [EventSubscriber(ObjectType::Codeunit, Codeunit::"Prod. Order Comp.-Reserve", OnVerifyChangeOnBeforeHasError, '', false, false)] local procedure "Prod. Order Comp.-Reserve_OnVerifyChangeOnBeforeHasError"(NewProdOrderComp: Record "Prod. Order Component"; OldProdOrderComp: Record "Prod. Order Component"; var HasError: Boolean; var ShowError: Boolean)#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 HasError := false; end;}