Codeunit "Calculate Prod. Order"
ID 99000773
Namespace: Microsoft.Manufacturing.Document
Properties
| Name |
Value |
| Permissions |
TableData Item = r,
TableData "Prod. Order Line" = rimd,
TableData "Prod. Order Component" = rimd,
TableData "Manufacturing Setup" = r,
TableData "Production BOM Line" = rimd,
TableData "Production BOM Comment Line" = rimd,
TableData "Production Order" = rimd,
TableData "Prod. Order Comp. Cmt Line" = rimd
|
Methods
InitProdOrderRoutingLine
procedure InitProdOrderRoutingLine(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; RoutingLine: Record "Routing Line")
Parameters
TransferTaskInfo
procedure TransferTaskInfo(var FromProdOrderRoutingLine: Record "Prod. Order Routing Line"; VersionCode: Code[20])
Parameters
TransferBOM
procedure TransferBOM(ProdBOMNo: Code[20]; Level: Integer; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal): Boolean
Parameters
| Name |
Type |
Description |
|
ProdBOMNo
|
Code[20] |
|
|
Level
|
Integer |
|
|
LineQtyPerUOM
|
Decimal |
|
|
ItemQtyPerUOM
|
Decimal |
|
Returns
CalculateComponents
procedure CalculateComponents()
CalculateRoutingFromActual
procedure CalculateRoutingFromActual(ProdOrderRoutingLine: Record "Prod. Order Routing Line"; Direction: Option; CalcStartEndDate: Boolean)
Parameters
CalculateProdOrderDates
procedure CalculateProdOrderDates(var ProdOrderLine: Record "Prod. Order Line"; LetDueDateDecrease: Boolean)
Parameters
Calculate
procedure Calculate(ProdOrderLine2: Record "Prod. Order Line"; Direction: Option; CalcRouting: Boolean; CalcComponents: Boolean; DeleteRelations: Boolean; LetDueDateDecrease: Boolean): Boolean
Parameters
Returns
Recalculate
procedure Recalculate(var ProdOrderLine2: Record "Prod. Order Line"; Direction: Option; LetDueDateDecrease: Boolean)
Parameters
BlockDynamicTracking
procedure BlockDynamicTracking(SetBlock: Boolean)
Parameters
| Name |
Type |
Description |
|
SetBlock
|
Boolean |
|
SetParameter
procedure SetParameter(NewProdOrderModify: Boolean)
Parameters
| Name |
Type |
Description |
|
NewProdOrderModify
|
Boolean |
|
SetProdOrderLineBinCodeFromRoute
procedure SetProdOrderLineBinCodeFromRoute(var ProdOrderLine: Record "Prod. Order Line"; ParentLocationCode: Code[10]; RoutingNo: Code[20])
Parameters
SetProdOrderLineBinCodeFromProdRtngLines
procedure SetProdOrderLineBinCodeFromProdRtngLines(var ProdOrderLine: Record "Prod. Order Line")
Parameters
SetProdOrderLineBinCodeFromPlanningRtngLines
procedure SetProdOrderLineBinCodeFromPlanningRtngLines(var ProdOrderLine: Record "Prod. Order Line"; ReqLine: Record "Requisition Line")
Parameters
FindAndSetProdOrderLineBinCodeFromProdRoutingLines
procedure FindAndSetProdOrderLineBinCodeFromProdRoutingLines(ProdOrderStatus: Enum "Production Order Status"; ProdOrderNo: Code[20]; ProdOrderLineNo: Integer)
Parameters
AssignProdOrderLineBinCodeFromProdRtngLineMachineCenter
procedure AssignProdOrderLineBinCodeFromProdRtngLineMachineCenter(var ProdOrderRoutingLine: Record "Prod. Order Routing Line")
Parameters
Events
OnAfterCalculate
[IntegrationEvent(False,False)]
local procedure OnAfterCalculate(ProdOrderLine: Record "Prod. Order Line"; var ErrorOccured: Boolean)
Parameters
OnAfterInsertProdRoutingLine
[IntegrationEvent(False,False)]
local procedure OnAfterInsertProdRoutingLine(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; ProdOrderLine: Record "Prod. Order Line")
Parameters
OnAfterTransferBOM
[IntegrationEvent(False,False)]
local procedure OnAfterTransferBOM(ProdOrder: Record "Production Order"; ProdOrderLine: Record "Prod. Order Line"; ProdBOMNo: Code[20]; Level: Integer; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal; Blocked: Boolean; var ErrorOccured: Boolean)
Parameters
OnAfterTransferTaskInfo
[IntegrationEvent(False,False)]
local procedure OnAfterTransferTaskInfo(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; VersionCode: Code[20])
Parameters
OnAfterTransferRouting
[IntegrationEvent(False,False)]
local procedure OnAfterTransferRouting(var ProdOrderLine: Record "Prod. Order Line")
Parameters
OnAfterTransferRoutingLine
[IntegrationEvent(False,False)]
local procedure OnAfterTransferRoutingLine(var ProdOrderLine: Record "Prod. Order Line"; var RoutingLine: Record "Routing Line"; var ProdOrderRoutingLine: Record "Prod. Order Routing Line")
Parameters
OnAfterTransferBOMComponent
[IntegrationEvent(False,False)]
local procedure OnAfterTransferBOMComponent(var ProdOrderLine: Record "Prod. Order Line"; var ProductionBOMLine: Record "Production BOM Line"; var ProdOrderComponent: Record "Prod. Order Component"; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal)
Parameters
OnAfterProdOrderCompFilter
[IntegrationEvent(False,False)]
local procedure OnAfterProdOrderCompFilter(var ProdOrderComp: Record "Prod. Order Component"; ProdBOMLine: Record "Production BOM Line")
Parameters
OnAfterProdOrderCompInsert
[IntegrationEvent(False,False)]
local procedure OnAfterProdOrderCompInsert(var ProdOrderComponent: Record "Prod. Order Component"; ProductionBOMLine: Record "Production BOM Line")
Parameters
OnBeforeAssignProdOrderLineBinCodeFromProdRtngLineMachineCenter
[IntegrationEvent(False,False)]
local procedure OnBeforeAssignProdOrderLineBinCodeFromProdRtngLineMachineCenter(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; var MachineCenter: Record "Machine Center"; var IsHandled: Boolean)
Parameters
OnBeforeCalculate
[IntegrationEvent(False,False)]
local procedure OnBeforeCalculate(var ItemLedgerEntry: Record "Item Ledger Entry"; var CapacityLedgerEntry: Record "Capacity Ledger Entry"; Direction: Option; CalcRouting: Boolean; CalcComponents: Boolean; var DeleteRelations: Boolean; LetDueDateDecrease: Boolean; var IsHandled: Boolean; var ProdOrderLine: Record "Prod. Order Line"; var ErrorOccured: Boolean)
Parameters
OnBeforeCalculateRoutingFromActual
[IntegrationEvent(False,False)]
local procedure OnBeforeCalculateRoutingFromActual(ProdOrderRoutingLine: Record "Prod. Order Routing Line"; Direction: Option; CalcStartEndDate: Boolean; var IsHandled: Boolean)
Parameters
OnBeforeCalculateProdOrderDates
[IntegrationEvent(False,False)]
local procedure OnBeforeCalculateProdOrderDates(var ProdOrderLine: Record "Prod. Order Line")
Parameters
OnBeforeCopyProdBOMComments
[IntegrationEvent(False,False)]
local procedure OnBeforeCopyProdBOMComments(var ProductionBOMCommentLine: Record "Production BOM Comment Line"; var ProductionBOMLine: Record "Production BOM Line"; var IsHandled: Boolean)
Parameters
OnBeforeProdOrderCompModify
[IntegrationEvent(False,False)]
local procedure OnBeforeProdOrderCompModify(var ProdOrderComp: Record "Prod. Order Component"; var ProdBOMLine: Record "Production BOM Line"; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal)
Parameters
OnBeforeSetProdOrderLineBinCode
[IntegrationEvent(False,False)]
local procedure OnBeforeSetProdOrderLineBinCode(var ProdOrderLine: Record "Prod. Order Line"; ParentBinCode: Code[20]; ParentLocationCode: Code[10]; var IsHandled: Boolean)
Parameters
OnBeforeTransferBOM
[IntegrationEvent(False,False)]
local procedure OnBeforeTransferBOM(var ProdOrder: Record "Production Order"; var ProdOrderLine: Record "Prod. Order Line"; ProdBOMNo: Code[20]; Level: Integer; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal; Blocked: Boolean; var ErrorOccured: Boolean; var IsHandled: Boolean)
Parameters
OnBeforeTransferBOMComponent
[IntegrationEvent(False,False)]
local procedure OnBeforeTransferBOMComponent(ProdOrder: Record "Production Order"; ProdOrderLine: Record "Prod. Order Line"; var ProdBOMLine: Record "Production BOM Line"; var ErrorOccured: Boolean; var IsHandled: Boolean; Level: Integer)
Parameters
OnBeforeTransferRouting
[IntegrationEvent(False,False)]
local procedure OnBeforeTransferRouting(var ProdOrder: Record "Production Order"; var ProdOrderLine: Record "Prod. Order Line"; var IsHandled: Boolean)
Parameters
OnBeforeUpdateProdOrderDates
[IntegrationEvent(False,False)]
local procedure OnBeforeUpdateProdOrderDates(var ProductionOrder: Record "Production Order"; var ProdOrderLine: Record "Prod. Order Line"; var ProdOrderModify: Boolean)
Parameters
OnCalculateOnAfterGetpLanningParameterAtSKUCalcComponents
[IntegrationEvent(False,False)]
local procedure OnCalculateOnAfterGetpLanningParameterAtSKUCalcComponents(var ProdOrderLine: Record "Prod. Order Line"; var SKU: Record "Stockkeeping Unit")
Parameters
OnCalculateOnAfterCalcShouldCheckIfEntriesExist
[IntegrationEvent(False,False)]
local procedure OnCalculateOnAfterCalcShouldCheckIfEntriesExist(var ProdOrderLine: Record "Prod. Order Line"; var CalcRouting: Boolean; var ShouldCheckIfEntriesExist: Boolean)
Parameters
OnCalculateOnAfterItemLedgEntrySetFilters
[IntegrationEvent(False,False)]
local procedure OnCalculateOnAfterItemLedgEntrySetFilters(ProdOrderLine: Record "Prod. Order Line"; var ItemLedgerEntry: Record "Item Ledger Entry")
Parameters
OnCalculateOnBeforeCheckNextOperation
[IntegrationEvent(False,False)]
local procedure OnCalculateOnBeforeCheckNextOperation(ProdOrder: Record "Production Order"; ProdOrderLine2: Record "Prod. Order Line"; var ProdOrderRoutingLine3: Record "Prod. Order Routing Line"; var IsHandled: Boolean)
Parameters
OnCalculateOnBeforeCheckPrevOperation
[IntegrationEvent(False,False)]
local procedure OnCalculateOnBeforeCheckPrevOperation(ProdOrder: Record "Production Order"; ProdOrderLine2: Record "Prod. Order Line"; var ProdOrderRoutingLine3: Record "Prod. Order Routing Line"; var IsHandled: Boolean)
Parameters
OnCalculateComponentsOnBeforeUpdateRoutingLinkCode
[IntegrationEvent(False,False)]
local procedure OnCalculateComponentsOnBeforeUpdateRoutingLinkCode(var ProdOrderComp: Record "Prod. Order Component"; ProdOrderLine: Record "Prod. Order Line"; var IsHandled: Boolean)
Parameters
OnCalculateProdOrderDatesOnAfterSetFilters
[IntegrationEvent(False,False)]
local procedure OnCalculateProdOrderDatesOnAfterSetFilters(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; ProductionOrder: Record "Production Order"; ProdOrderLine: Record "Prod. Order Line")
Parameters
OnCalculateProdOrderDatesOnSetBeforeDueDate
[IntegrationEvent(False,False)]
local procedure OnCalculateProdOrderDatesOnSetBeforeDueDate(var ProdOrderLine: Record "Prod. Order Line"; var IsHandled: Boolean)
Parameters
OnCalculateProdOrderDatesOnBeforeUpdateDatetime
[IntegrationEvent(False,False)]
local procedure OnCalculateProdOrderDatesOnBeforeUpdateDatetime(var ProdOrderLine: Record "Prod. Order Line"; NewDueDate: Date; LetDueDateDecreate: Boolean)
Parameters
OnCalculateRoutingFromActualOnAfterSetProdOrderRoutingLineFilters
[IntegrationEvent(False,False)]
local procedure OnCalculateRoutingFromActualOnAfterSetProdOrderRoutingLineFilters(var ProdOrderRoutingLine: Record "Prod. Order Routing Line")
Parameters
OnCalculateRoutingFromActualOnBeforeCalcStartEndDate
[IntegrationEvent(False,False)]
local procedure OnCalculateRoutingFromActualOnBeforeCalcStartEndDate(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; var CalcStartEndDate: Boolean)
Parameters
OnCopyRoutingToolsOnAfterRoutingToolSetFilters
[IntegrationEvent(False,False)]
local procedure OnCopyRoutingToolsOnAfterRoutingToolSetFilters(var RoutingTool: Record "Routing Tool"; ProdOrderRoutingLine: Record "Prod. Order Routing Line"; VersionCode: Code[20])
Parameters
OnTransferBOMOnAfterCalcReqQty
[IntegrationEvent(False,False)]
local procedure OnTransferBOMOnAfterCalcReqQty(ProductionBOMLine: Record "Production BOM Line"; ProdOrderRoutingLine: Record "Prod. Order Routing Line"; ProdOrderLine: Record "Prod. Order Line"; var ReqQty: Decimal; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal)
Parameters
OnTransferBOMOnAfterSetFiltersProdBOMLine
[IntegrationEvent(False,False)]
local procedure OnTransferBOMOnAfterSetFiltersProdBOMLine(var ProdBOMLine: Record "Production BOM Line"; ProdOrderLine: Record "Prod. Order Line")
Parameters
OnTransferBOMOnBeforeProcessItem
[IntegrationEvent(False,False)]
local procedure OnTransferBOMOnBeforeProcessItem(ProdBOMLine: Record "Production BOM Line"; ReqQty: Decimal; var SkipTransfer: Boolean)
Parameters
OnTransferBOMOnBeforeProcessProdBOM
[IntegrationEvent(False,False)]
local procedure OnTransferBOMOnBeforeProcessProdBOM(ProdBOMLine: Record "Production BOM Line"; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal; var ReqQty: Decimal; var ProdOrderLine: Record "Prod. Order Line")
Parameters
OnTransferBOMOnAfterProcessProdBOM
[IntegrationEvent(False,False)]
local procedure OnTransferBOMOnAfterProcessProdBOM(var ProductionBOMLine: Record "Production BOM Line"; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal; var ReqQty: Decimal; ProdOrderLine: Record "Prod. Order Line")
Parameters
OnTransferBOMOnBeforeTransferNestedProdBOM
[IntegrationEvent(False,False)]
local procedure OnTransferBOMOnBeforeTransferNestedProdBOM(ProductionBOMLine: Record "Production BOM Line"; LineQtyPerUOM: Decimal; ItemQtyPerUOM: Decimal; var ReqQty: Decimal; var ProdOrderLine: Record "Prod. Order Line"; var IsHandled: Boolean)
Parameters
OnTransferBOMProcessItemOnAfterGetPlanningParameters
[IntegrationEvent(False,False)]
local procedure OnTransferBOMProcessItemOnAfterGetPlanningParameters(var ProdOrderLine: Record "Prod. Order Line"; var ComponentSKU: Record "Stockkeeping Unit")
Parameters
OnTransferBOMProcessItemOnBeforeGetPlanningParameters
[IntegrationEvent(False,False)]
local procedure OnTransferBOMProcessItemOnBeforeGetPlanningParameters(var ProdOrderComponent: Record "Prod. Order Component"; ProductionBOMLine: Record "Production BOM Line"; StockkeepingUnit: Record "Stockkeeping Unit")
Parameters
OnTransferRoutingOnbeforeValidateDirectUnitCost
[IntegrationEvent(False,False)]
local procedure OnTransferRoutingOnbeforeValidateDirectUnitCost(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; ProdOrderLine: Record "Prod. Order Line"; RoutingLine: Record "Routing Line")
Parameters
OnTransferRoutingOnBeforeCalcRoutingCostPerUnit
[IntegrationEvent(False,False)]
procedure OnTransferRoutingOnBeforeCalcRoutingCostPerUnit(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; ProdOrderLine: Record "Prod. Order Line"; RoutingLine: Record "Routing Line")
Parameters
OnCalculateRoutingOnBeforeSetLeadTime
[IntegrationEvent(False,False)]
local procedure OnCalculateRoutingOnBeforeSetLeadTime(var ProdOrderLine: Record "Prod. Order Line")
Parameters
OnAfterCalculateComponents
[IntegrationEvent(False,False)]
local procedure OnAfterCalculateComponents(ProdOrderLine: Record "Prod. Order Line")
Parameters
OnBeforeRecalculate
[IntegrationEvent(False,False)]
local procedure OnBeforeRecalculate(var ProdOrderLine: Record "Prod. Order Line"; CalcRouting: Boolean; CalcComponents: Boolean)
Parameters
OnAfterRecalculate
[IntegrationEvent(False,False)]
local procedure OnAfterRecalculate(var ProdOrderLine: Record "Prod. Order Line"; CalcRouting: Boolean; CalcComponents: Boolean)
Parameters
OnAfterRecalculateProcedure
[IntegrationEvent(False,False)]
local procedure OnAfterRecalculateProcedure(var ProdOrderLine: Record "Prod. Order Line")
Parameters
OnRecalculateOnBeforeCalculateRouting
[IntegrationEvent(False,False)]
procedure OnRecalculateOnBeforeCalculateRouting(var ProdOrderLine: Record "Prod. Order Line"; var IsHandled: Boolean)
Parameters
OnTransferBOMProcessItemOnBeforeSetFlushingMethod
[IntegrationEvent(False,False)]
local procedure OnTransferBOMProcessItemOnBeforeSetFlushingMethod(var ProdOrderLine: Record "Prod. Order Line"; var ComponentSKU: Record "Stockkeeping Unit"; var ProdOrderComp: Record "Prod. Order Component"; ProdBOMLine: Record "Production BOM Line"; var IsHandled: Boolean)
Parameters
OnAfterSetPlanningLevelCode
[IntegrationEvent(False,False)]
local procedure OnAfterSetPlanningLevelCode(var ProdOrderComponent: Record "Prod. Order Component"; var ProductionBOMLine: Record "Production BOM Line"; var SKU: Record "Stockkeeping Unit"; var ComponentSKU: Record "Stockkeeping Unit"; var Result: Boolean)
Parameters
OnBeforeProcessRoutingLine
[IntegrationEvent(False,False)]
local procedure OnBeforeProcessRoutingLine(var RoutingLine: Record "Routing Line"; var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; ProdOrderLine: Record "Prod. Order Line"; ProductionOrder: Record "Production Order"; var IsHandled: Boolean)
Parameters
OnBeforeCopyRoutingComments
[IntegrationEvent(False,False)]
local procedure OnBeforeCopyRoutingComments(var RoutingCommentLine: Record "Routing Comment Line"; ProdOrderRoutingLine: Record "Prod. Order Routing Line"; VersionCode: Code[20]; var IsHandled: Boolean)
Parameters
OnCalculateRoutingOnBeforeUpdateProdOrderRoutingLineDates
[IntegrationEvent(False,False)]
local procedure OnCalculateRoutingOnBeforeUpdateProdOrderRoutingLineDates(var ProdOrderRoutingLine: Record "Prod. Order Routing Line"; var ProdOrderLine: Record "Prod. Order Line"; var IsHandled: Boolean)
Parameters
OnBeforeCheckProdOrderLineQuantity
[IntegrationEvent(False,False)]
local procedure OnBeforeCheckProdOrderLineQuantity(ProdOrderLine: Record "Prod. Order Line"; var IsHandled: Boolean)
Parameters
OnCalculateOnBeforeCalcComponents
[IntegrationEvent(False,False)]
local procedure OnCalculateOnBeforeCalcComponents(ProdOrderLine: Record "Prod. Order Line"; CalcComponents: Boolean; var SkipCalcComponents: Boolean)
Parameters
OnCalculateOnAfterCapLedgEntrySetFilters
[IntegrationEvent(False,False)]
local procedure OnCalculateOnAfterCapLedgEntrySetFilters(var ProdOrderLine: Record "Prod. Order Line"; var CapacityLedgerEntry: Record "Capacity Ledger Entry")
Parameters
OnBeforeGetDefaultBin
[IntegrationEvent(False,False)]
local procedure OnBeforeGetDefaultBin(var ProdOrderComponent: Record "Prod. Order Component"; var Location: Record Location; var Item: Record Item; var ProdOrderWarehouseMgt: Codeunit "Prod. Order Warehouse Mgt."; var BinCode: Code[20]; var IsHandled: Boolean)
Parameters
OnBeforeFindProdOrderRoutingLine
[IntegrationEvent(False,False)]
local procedure OnBeforeFindProdOrderRoutingLine(var ProdOrderLine: Record "Prod. Order Line"; var ProductionBOMLine: Record "Production BOM Line"; var IsHandled: Boolean; var ReqQty: Decimal)
Parameters
OnCalculateRoutingFromActualOnAfterCalculateRoutingLine
[IntegrationEvent(False,False)]
local procedure OnCalculateRoutingFromActualOnAfterCalculateRoutingLine(var ProdOrderRoutingLine: Record "Prod. Order Routing Line")
Parameters
See also