KVSFCYEDMonitoringLib#
Procedures#
CheckEDOrderLineManPolicy(Record Prod. Order Line) :#
Summary: Validates whether manufacturing policy changes are allowed for a production order line by checking ledger entries, reservations, and component dependencies. This procedure performs comprehensive validation to ensure that engineering design manufacturing policy modifications can be safely applied to production order lines without violating data integrity or operational constraints. It checks for existing item ledger entries and capacity ledger entries that would prevent policy changes, validates all production order components associated with the line, and verifies external reservation entries to ensure demand exclusivity within the same production order. The procedure supports engineering design change management by preventing manufacturing policy modifications that could cause inconsistencies in production execution, inventory tracking, or capacity planning workflows.
procedure CheckEDOrderLineManPolicy(prodOrderLinePar: Record "Prod. Order Line"):
Parameters:
prodOrderLinePar: The production order line record to validate for manufacturing policy changes, containing status, production order number, line number, and component references for comprehensive validation checks.
CheckEDOrderStructure(Integer, Code[20], Integer, Boolean) :#
Summary: Validates and recalculates the engineering design order structure for a specific production order line including multi-level verification and routing replanning. This procedure performs comprehensive structural validation of engineering design orders by checking production order line integrity, validating multi-level BOM and routing structures, and ensuring that all engineering design components and operations are properly configured and accessible. It utilizes the CreateEDOrderLine codeunit to clear existing planning data, set the target production order line for analysis, and execute multi-level structure checks that validate component availability, routing operation sequences, and capacity requirements. The procedure also performs routing recalculation based on engineering design setup parameters and initializes part type references throughout the production order structure to maintain data consistency and operational accuracy.
procedure CheckEDOrderStructure(StatusPar: Integer; ProdOrderNoPar: Code[20]; ProdOrderLineNoPar: Integer; MultiLevelPar: Boolean):
Parameters:
StatusPar: The production order status as integer value (0=Simulated, 1=Planned, 2=Firm Planned, 3=Released, 4=Finished) identifying the production order to validate.ProdOrderNoPar: The production order number identifying the specific production order containing the line to validate and recalculate.ProdOrderLineNoPar: The production order line number identifying the specific line within the production order to validate for structural integrity and engineering design compliance.MultiLevelPar: When true, enables multi-level structure validation that recursively checks all sub-levels of the BOM and routing structures; when false, validates only the immediate level of the specified production order line.
FindRecordsForEDOrder(Record KVSFCYEDMonitoringLineBuffer, Record KVSFCYEDMonitoringLineBuffer, Record Production Order, Enum KVSFCYCalcRoutingType, Enum KVSFCYEDView, Enum KVSFCYDurationPrecision) :#
Summary: Generates comprehensive engineering design monitoring data by analyzing production order structures and creating detailed monitoring line buffers for different viewing perspectives. This procedure performs complete analysis of engineering design orders by clearing existing temporary data, retrieving engineering design setup parameters, and generating detailed monitoring line buffers that represent production order structures from various analytical perspectives. It supports multiple viewing filters including Constructional (component-focused analysis), For Planning Purposal (planning-oriented view with routing details), and Logistic (supply chain and material flow analysis). The procedure creates records from production order lines, applies appropriate sorting and filtering based on the viewing perspective, calculates routing information when required, and populates both primary and secondary monitoring buffers for comparative analysis and reporting purposes. Progress dialogs are displayed during processing to provide user feedback for complex calculations.
procedure FindRecordsForEDOrder(var tempEDMonitoringLineBufferVar: Record "KVSFCYEDMonitoringLineBuffer"; var tempEDMonitoringLineBuffer2Var: Record "KVSFCYEDMonitoringLineBuffer"; var prodOrderFilterVar: Record "Production Order"; calcRoutingPar: Enum "KVSFCYCalcRoutingType"; viewingFilterPar: Enum "KVSFCYEDView"; durationPrecisionPar: Enum "KVSFCYDurationPrecision"):
Parameters:
tempEDMonitoringLineBufferVar: Primary temporary monitoring line buffer that receives the generated engineering design monitoring data with complete structural and analytical information for display and processing.tempEDMonitoringLineBuffer2Var: Secondary temporary monitoring line buffer used for comparative analysis and maintaining selected record context during data refresh operations and view switching.prodOrderFilterVar: The production order record that defines the scope and context for monitoring data generation, containing status, order number, and other filtering criteria for analysis.calcRoutingPar: Enumeration value specifying the routing calculation method to apply during monitoring data generation, affecting how routing times and sequences are calculated and displayed.viewingFilterPar: Enumeration value defining the viewing perspective for data generation (Constructional, For Planning Purposal, Logistic) which determines the structure, sorting, and content of the generated monitoring data.durationPrecisionPar: Enumeration value specifying the precision level for duration and time calculations in the monitoring data, affecting how time-related fields are calculated and displayed in the analysis.
UpdatePositionProdOrder(Record Production Order) :#
Summary: Updates engineering design position information for all top-level production order lines within a specified production order. This procedure systematically processes all production order lines at planning level zero (top-level items) within the specified production order and updates their engineering design position information to ensure consistency with current engineering design master data and structural requirements. It filters production order lines by status, production order number, and planning level code to identify only the primary production items that serve as entry points for engineering design structure analysis. For each qualifying production order line, the procedure calls UpdateEDPositionLine to recalculate and update position-related fields based on current BOM structure, engineering design setup parameters, and positional hierarchy within the production order context. This supports engineering design change management by maintaining accurate positional references throughout production execution.
procedure UpdatePositionProdOrder(prodOrderPar: Record "Production Order"):
Parameters:
prodOrderPar: The production order record containing status and order number information used to identify and update all top-level production order lines within the specified production order scope.
GetItemVersionCode(Code[20], Code[10], Date, Record KVSFCYItemVersion) : Boolean#
Summary: Retrieves the active item version for a specified item, variant, and date by interfacing with the engineering design library. This procedure serves as a wrapper function for the KVSFCYEngineeringDesignLib.GetActualItemVersion method, providing a simplified interface for obtaining valid item version information within engineering design monitoring workflows. It determines the appropriate item version based on effective date ranges, variant specifications, and engineering design version management rules. The procedure supports version-controlled engineering design processes by ensuring that monitoring and analysis functions operate with the correct item version data corresponding to the specified date context. This is essential for accurate BOM and routing resolution, engineering change tracking, and production planning scenarios where different item versions may be active during different time periods.
procedure GetItemVersionCode(itemNoPar: Code[20]; variantCodePar: Code[10]; datePar: Date; var itemVersionVar: Record "KVSFCYItemVersion"): Boolean
Parameters:
itemNoPar: The item number for which to retrieve the active item version information, serving as the primary identifier for version lookup operations.variantCodePar: The variant code specifying the item variant for version lookup; can be blank for standard item versions without variant-specific versioning requirements.datePar: The date used to determine which item version is active or effective for the specified time period, supporting time-based version control and engineering change management.itemVersionVar: Output parameter that receives the complete item version record containing version code, BOM information, routing details, and other version-specific engineering design data when a valid version is found.
Returns: True when a valid item version is found and retrieved for the specified parameters; false when no applicable item version exists for the given item, variant, and date combination.
Events#
OnAfterTransAddProdBOMFieldsToPOComp(Record Prod. Order Component, Record Production BOM Line) :#
Summary: Event triggered after transferring production BOM fields to production order component during Engineering Design monitoring operations.
[IntegrationEvent(false, false)]
local procedure OnAfterTransAddProdBOMFieldsToPOComp(var ProdOrderComponent: Record "Prod. Order Component"; ProdBOMLine: Record "Production BOM Line"):
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSFCYEDMonitoringLib", 'OnAfterTransAddProdBOMFieldsToPOComp', '', false, false)]
local procedure DoSomethingOnAfterTransAddProdBOMFieldsToPOComp(var ProdOrderComponent: Record "Prod. Order Component"; ProdBOMLine: Record "Production BOM Line")
begin
end;
Parameters:
ProdOrderComponent: The production order component record that has received the transferred BOM field data and can be further modified.ProdBOMLine: The production BOM line record that was used as the source for the field transfer operation.
OnCreateRecordsFromProdOrderRtngLineBeforeInsertTempEDMonitoringLineBuffer(Record KVSFCYEDMonitoringLineBuffer, Record Prod. Order Routing Line) :#
Summary: This event is triggered before a EDMonitoringLine is inserted from a prod. order routing line.
[IntegrationEvent(false, false)]
local procedure OnCreateRecordsFromProdOrderRtngLineBeforeInsertTempEDMonitoringLineBuffer(var TempEDMonitoringLineBuffer: Record "KVSFCYEDMonitoringLineBuffer" temporary; ProdOrderRoutingLine: Record "Prod. Order Routing Line"):
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSFCYEDMonitoringLib", 'OnCreateRecordsFromProdOrderRtngLineBeforeInsertTempEDMonitoringLineBuffer', '', false, false)]
local procedure DoSomethingOnCreateRecordsFromProdOrderRtngLineBeforeInsertTempEDMonitoringLineBuffer(var TempEDMonitoringLineBuffer: Record "KVSFCYEDMonitoringLineBuffer" temporary; ProdOrderRoutingLine: Record "Prod. Order Routing Line")
begin
end;
Parameters:
TempEDMonitoringLineBuffer: The EDMonitoringLine which is createdProdOrderRoutingLine: The prod. order routing line from which the EDMonitoringLine is inserted
OnCreateRecordsFromProdOrderComponentBeforeInsertTempEDMonitoringLineBuffer(Record KVSFCYEDMonitoringLineBuffer, Record Prod. Order Component) :#
Summary: Event triggered before inserting an Engineering Design monitoring line buffer record created from a production order component.
[IntegrationEvent(false, false)]
local procedure OnCreateRecordsFromProdOrderComponentBeforeInsertTempEDMonitoringLineBuffer(var tempEDMonitoringLineBufferVar: Record "KVSFCYEDMonitoringLineBuffer"; var prodComponentPar: Record "Prod. Order Component"):
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSFCYEDMonitoringLib", 'OnCreateRecordsFromProdOrderComponentBeforeInsertTempEDMonitoringLineBuffer', '', false, false)]
local procedure DoSomethingOnCreateRecordsFromProdOrderComponentBeforeInsertTempEDMonitoringLineBuffer(var tempEDMonitoringLineBufferVar: Record "KVSFCYEDMonitoringLineBuffer"; var prodComponentPar: Record "Prod. Order Component")
begin
end;
Parameters:
tempEDMonitoringLineBufferVar: The temporary Engineering Design monitoring line buffer record that will be inserted and can be modified.prodComponentPar: The production order component record that is being used as the source for creating the monitoring line buffer record.
OnCreateRecordsFromProdOrderLineBeforeInsertTempEDMonitoringLineBuffer(Record KVSFCYEDMonitoringLineBuffer, Record Prod. Order Line) :#
Summary: Event triggered before inserting an Engineering Design monitoring line buffer record created from a production order line.
[IntegrationEvent(false, false)]
local procedure OnCreateRecordsFromProdOrderLineBeforeInsertTempEDMonitoringLineBuffer(var KVSFCYEDMonitoringLineBuffer: Record "KVSFCYEDMonitoringLineBuffer"; var ProdOrderLine: Record "Prod. Order Line"):
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSFCYEDMonitoringLib", 'OnCreateRecordsFromProdOrderLineBeforeInsertTempEDMonitoringLineBuffer', '', false, false)]
local procedure DoSomethingOnCreateRecordsFromProdOrderLineBeforeInsertTempEDMonitoringLineBuffer(var KVSFCYEDMonitoringLineBuffer: Record "KVSFCYEDMonitoringLineBuffer"; var ProdOrderLine: Record "Prod. Order Line")
begin
end;
Parameters:
KVSFCYEDMonitoringLineBuffer: The Engineering Design monitoring line buffer record that will be inserted and can be modified.ProdOrderLine: The production order line record that is being used as the source for creating the monitoring line buffer record.
OnInsertEDMonitorLineBOMNewBeforeInsertTempEDMonitoringLineBuffer(Record KVSFCYEDMonitoringLineBuffer, Record Production BOM Line) :#
Summary: Event triggered before inserting a new Engineering Design monitoring line buffer record created from a production BOM line.
[IntegrationEvent(false, false)]
local procedure OnInsertEDMonitorLineBOMNewBeforeInsertTempEDMonitoringLineBuffer(var tempEDMonitoringLineBufferVar: Record "KVSFCYEDMonitoringLineBuffer"; bOMComponentPar: Record "Production BOM Line"):
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSFCYEDMonitoringLib", 'OnInsertEDMonitorLineBOMNewBeforeInsertTempEDMonitoringLineBuffer', '', false, false)]
local procedure DoSomethingOnInsertEDMonitorLineBOMNewBeforeInsertTempEDMonitoringLineBuffer(var tempEDMonitoringLineBufferVar: Record "KVSFCYEDMonitoringLineBuffer"; bOMComponentPar: Record "Production BOM Line")
begin
end;
Parameters:
tempEDMonitoringLineBufferVar: The temporary Engineering Design monitoring line buffer record that will be inserted and can be modified.bOMComponentPar: The production BOM line record that is being used as the source for creating the new monitoring line buffer record.
OnInsertEDPlanningCompBeforeAssignLocationCode(Record Planning Component, Record Prod. Order Component, Record Requisition Line, Boolean) :#
Summary: Event triggered before assigning location code during Engineering Design planning component insertion operations.
[IntegrationEvent(false, false)]
local procedure OnInsertEDPlanningCompBeforeAssignLocationCode(var planningComponent: Record "Planning Component"; var prodOrderComp: Record "Prod. Order Component"; var requisitionLine: Record "Requisition Line"; var isHandled: Boolean):
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSFCYEDMonitoringLib", 'OnInsertEDPlanningCompBeforeAssignLocationCode', '', false, false)]
local procedure DoSomethingOnInsertEDPlanningCompBeforeAssignLocationCode(var planningComponent: Record "Planning Component"; var prodOrderComp: Record "Prod. Order Component"; var requisitionLine: Record "Requisition Line"; var isHandled: Boolean)
begin
end;
Parameters:
planningComponent: The planning component record that will receive the location code assignment and can be modified.prodOrderComp: The production order component record that provides the source location information for the assignment.requisitionLine: The requisition line record that provides additional context for the location code assignment operation.isHandled: Boolean flag to indicate if the location code assignment has been handled by custom logic, preventing default processing.
OnShowProdOrderComponentsBeforeTempEDMonitoringLineBuffer2Modify(Record KVSFCYEDMonitoringLineBuffer, Record Prod. Order Component) :#
Summary: Event triggered before modifying a temporary Engineering Design monitoring line buffer record during production order component display operations.
[IntegrationEvent(false, false)]
local procedure OnShowProdOrderComponentsBeforeTempEDMonitoringLineBuffer2Modify(var tempEDMonitoringLineBuffer2Var: Record "KVSFCYEDMonitoringLineBuffer"; ProdOrderComponent: Record "Prod. Order Component"):
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSFCYEDMonitoringLib", 'OnShowProdOrderComponentsBeforeTempEDMonitoringLineBuffer2Modify', '', false, false)]
local procedure DoSomethingOnShowProdOrderComponentsBeforeTempEDMonitoringLineBuffer2Modify(var tempEDMonitoringLineBuffer2Var: Record "KVSFCYEDMonitoringLineBuffer"; ProdOrderComponent: Record "Prod. Order Component")
begin
end;
Parameters:
tempEDMonitoringLineBuffer2Var: The temporary Engineering Design monitoring line buffer record that will be modified and can be customized before the modification.ProdOrderComponent: The production order component record that provides the context and data for the monitoring line buffer modification operation.