Codeunit 18122611 EOS060 Maintenance Mgt.

Codeunit 18122611 EOS060 Maintenance Mgt.

Methods

CreateWorkRequestFromMaintenancePoint

procedure CreateWorkRequestFromMaintenancePoint(var MaintenancePoint: Record "EOS060 Maintenance Point")

Parameters / Return Value

  • MaintenancePoint Record "EOS060 Maintenance Point"

CreateWorkRequest

procedure CreateWorkRequest(var MaintenancePoint: Record "EOS060 Maintenance Point"; PlannedStartingDate: Date)

Parameters / Return Value

  • MaintenancePoint Record "EOS060 Maintenance Point"

  • PlannedStartingDate Date


CreateWorkRequest

procedure CreateWorkRequest(var WorkRequest: Record "EOS060 Work Request"; var MaintenancePoint: Record "EOS060 Maintenance Point"; PlannedStartingDate: Date)

Parameters / Return Value

  • WorkRequest Record "EOS060 Work Request"

  • MaintenancePoint Record "EOS060 Maintenance Point"

  • PlannedStartingDate Date


CopySpareParts

procedure CopySpareParts(MaintenancePoint: Record "EOS060 Maintenance Point"; WorkRequest: Record "EOS060 Work Request"; Replace: Boolean)

Parameters / Return Value

  • MaintenancePoint Record "EOS060 Maintenance Point"

  • WorkRequest Record "EOS060 Work Request"

  • Replace Boolean


CreateWorkRequestIfDue

procedure CreateWorkRequestIfDue(var MaintPoint: record "EOS060 Maintenance Point"; ReferenceDate: Date)

Parameters / Return Value

  • MaintPoint record "EOS060 Maintenance Point"

  • ReferenceDate Date


CreateWorkRequestIfPlannedValue

procedure CreateWorkRequestIfPlannedValue(var MaintenancePoint: record "EOS060 Maintenance Point"; ReferenceDate: Date)

Parameters / Return Value

  • MaintenancePoint record "EOS060 Maintenance Point"

  • ReferenceDate Date


AutoCreateWorkRequest

procedure AutoCreateWorkRequest(PrevWorkRequest: Record "EOS060 Work Request")

Parameters / Return Value

  • PrevWorkRequest Record "EOS060 Work Request"

CopySparePartsInPurchaseLine

procedure CopySparePartsInPurchaseLine(var WorkRequest: Record "EOS060 Work Request")

Parameters / Return Value

  • WorkRequest Record "EOS060 Work Request"

MaintenanceDateAllowed

procedure MaintenanceDateAllowed(MaintenancePoint: Record "EOS060 Maintenance Point"; PlanningDate: Date): Boolean

Parameters / Return Value

  • MaintenancePoint Record "EOS060 Maintenance Point"

  • PlanningDate Date

  • Returns Boolean


CreateRequisitionLine

procedure CreateRequisitionLine(var WorkReqPurchLine: Record "EOS060 Work Req Purch. Line")

Parameters / Return Value

  • WorkReqPurchLine Record "EOS060 Work Req Purch. Line"

CreateStartWorkRequestEntry

procedure CreateStartWorkRequestEntry(var WorkRequestCycle: Record "EOS060 Work Request Cycle")

Parameters / Return Value

  • WorkRequestCycle Record "EOS060 Work Request Cycle"

CreateStopWorkRequestEntry

procedure CreateStopWorkRequestEntry(var WorkRequestCycle: Record "EOS060 Work Request Cycle")

Parameters / Return Value

  • WorkRequestCycle Record "EOS060 Work Request Cycle"

CreateStopWorkRequestEntry

procedure CreateStopWorkRequestEntry(var WorkRequestCycle: Record "EOS060 Work Request Cycle"; Duplicate: Boolean)

Parameters / Return Value

  • WorkRequestCycle Record "EOS060 Work Request Cycle"

  • Duplicate Boolean


GetWorkRequestCycleStatus

procedure GetWorkRequestCycleStatus(WorkRequestCycle: Record "EOS060 Work Request Cycle"; Open: Boolean): Enum "EOS060 Work Req. Cycle Status"

Parameters / Return Value

  • WorkRequestCycle Record "EOS060 Work Request Cycle"

  • Open Boolean

  • Returns Enum "EOS060 Work Req. Cycle Status"


GetWorkRequestCycleDuration

procedure GetWorkRequestCycleDuration(WorkRequestCycle: Record "EOS060 Work Request Cycle"; Open: Boolean): Duration

Parameters / Return Value

  • WorkRequestCycle Record "EOS060 Work Request Cycle"

  • Open Boolean

  • Returns Duration


GetWorkJournalLineDuration

procedure GetWorkJournalLineDuration(WorkRequestNo: Code[20]; Resource: Record Resource; Open: Boolean; WorkJnlLine: Record "EOS060 Work Journal Line"): Duration

Parameters / Return Value

  • WorkRequestNo Code[20]

  • Resource Record "Resource"

  • Open Boolean

  • WorkJnlLine Record "EOS060 Work Journal Line"

  • Returns Duration


IsPowerPMMAllowed

procedure IsPowerPMMAllowed(ThrowError: Boolean) Allowed: Boolean

Parameters / Return Value

  • ThrowError Boolean

  • Returns Boolean


Events

OnBeforeCreateWorkRequest

local procedure OnBeforeCreateWorkRequest(var MaintenancePoint: Record "EOS060 Maintenance Point"; var PlannedStartingDate: Date; var IsHandled: Boolean)

Raised before creating a new work request.

Parameters / Return Value

  • MaintenancePoint Record "EOS060 Maintenance Point"

    The maintenance point that generated the work request.

  • PlannedStartingDate Date

    The planned starting date for the work request.

  • IsHandled Boolean

    If true, skips the standard logic.


OnBeforeWorkRequestModify

local procedure OnBeforeWorkRequestModify(var WorkRequest: Record "EOS060 Work Request")

Raised before modifying the work request that was just created by another process.

Parameters / Return Value

  • WorkRequest Record "EOS060 Work Request"

    The current record.


OnAfterWorkRequestModify

local procedure OnAfterWorkRequestModify(var WorkRequest: Record "EOS060 Work Request")

Raised after modifying the work request that was just created by another process.

Parameters / Return Value

  • WorkRequest Record "EOS060 Work Request"

    The record that was just modified.


OnCopySparePartsOnBeforeReplace

local procedure OnCopySparePartsOnBeforeReplace(MaintenancePoint: Record "EOS060 Maintenance Point"; WorkRequest: Record "EOS060 Work Request"; var Replace: Boolean)

Raised at the beginning of the CopySpareParts procedure, before deleting the existing spare parts.

Parameters / Return Value

  • MaintenancePoint Record "EOS060 Maintenance Point"

    The maintenance point that generated the work request.

  • WorkRequest Record "EOS060 Work Request"

    The work request that needs the spare parts.

  • Replace Boolean

    If true, existing spare parts will be deleted from the work request.


OnBeforeSparePartInsert

local procedure OnBeforeSparePartInsert(SparePart: Record "EOS060 Spare Part"; MaintenancePoint: Record "EOS060 Maintenance Point"; WorkRequest: Record "EOS060 Work Request")

Raised before inserting a new spare part linked to the work request.

Parameters / Return Value

  • SparePart Record "EOS060 Spare Part"

    The current spare part record.

  • MaintenancePoint Record "EOS060 Maintenance Point"

    The maintenance point that generated the work request.

  • WorkRequest Record "EOS060 Work Request"

    The current work request.


OnCopyPPEOnBeforeReplace

local procedure OnCopyPPEOnBeforeReplace(MaintenancePoint: Record "EOS060 Maintenance Point"; WorkRequest: Record "EOS060 Work Request"; var Replace: Boolean)

Raised before replacing the existing PPE linked to the work request.

Parameters / Return Value

  • MaintenancePoint Record "EOS060 Maintenance Point"

    The related maintenance point.

  • WorkRequest Record "EOS060 Work Request"

    The related work request.

  • Replace Boolean

    Specifies whether to replace PPE.


OnBeforePPEInsert

local procedure OnBeforePPEInsert(var Rec: Record "EOS060 PPE"; MaintenancePoint: Record "EOS060 Maintenance Point"; WorkRequest: Record "EOS060 Work Request")

Raised before inserting a new PPE linked to the work request.

Parameters / Return Value

  • Rec Record "EOS060 PPE"

    The PPE record to insert.

  • MaintenancePoint Record "EOS060 Maintenance Point"

    The related maintenance point.

  • WorkRequest Record "EOS060 Work Request"

    The related work request.


OnBeforeWorkPurchaseLineInsert

local procedure OnBeforeWorkPurchaseLineInsert(var WorkPurchaseLine: record "EOS060 Work Req Purch. Line"; FromSpareParts: Record "EOS060 Spare Part")

Raised before inserting a new work request purchase line.

Parameters / Return Value

  • WorkPurchaseLine record "EOS060 Work Req Purch. Line"

    The work request purchase line to insert.

  • FromSpareParts Record "EOS060 Spare Part"

    The related spare part.


OnBeforeCreateRequisitionLine

local procedure OnBeforeCreateRequisitionLine(WorkReqPurchLine: Record "EOS060 Work Req Purch. Line")

Raised before creating a Requisition Line.

Parameters / Return Value

  • WorkReqPurchLine Record "EOS060 Work Req Purch. Line"

    The Purchase Line on the Work Request.


OnBeforeRequisitionLineInsert

local procedure OnBeforeRequisitionLineInsert(var RequisitionLine: Record "Requisition Line"; WorkReqPurchLine: Record "EOS060 Work Req Purch. Line")

Raised before inserting a new requisition line.

Parameters / Return Value

  • RequisitionLine Record "Requisition Line"

    The requisition line to insert.

  • WorkReqPurchLine Record "EOS060 Work Req Purch. Line"

    The related work request purchase line.


OnReachedValueUpdate

local procedure OnReachedValueUpdate(var MaintenancePoint: Record "EOS060 Maintenance Point")

Raised after creating a work request when the planned criteria has reached its value, after updating the maintenance point with the new reached value, before saving the update to the database.

Parameters / Return Value

  • MaintenancePoint Record "EOS060 Maintenance Point"

    The Maintenance Point record


OnBeforeCreateWorkRequestIfPlannedValue

local procedure OnBeforeCreateWorkRequestIfPlannedValue(var MaintenancePoint: record "EOS060 Maintenance Point"; ReferenceDate: Date; var IsHandled: Boolean)

This event is raised at the beginning of the procedure CreateWorkRequestIfPlannedValue().

Parameters / Return Value

  • MaintenancePoint record "EOS060 Maintenance Point"

    record “EOS060 Maintenance Point”

  • ReferenceDate Date

    Date

  • IsHandled Boolean

    if true, no following app code will be executed


OnBeforeInsertJnlLine

internal procedure OnBeforeInsertJnlLine(var Rec: Record "EOS060 Work Journal Line"; WorkRequest: Record "EOS060 Work Request"; SourceRecordId: RecordId; IsHandled: Boolean)

Raised before inserting a the journal line.

Parameters / Return Value

  • Rec Record "EOS060 Work Journal Line"

    The work journal line to insert.

  • WorkRequest Record "EOS060 Work Request"

    The related work request.

  • SourceRecordId RecordId

    The source of the journal line.

  • IsHandled Boolean

    Specifies if the procedure is handled by the subscriber.


OnBeforeExecuteMaintenanceCycleResolutionFollowUpAction

internal procedure OnBeforeExecuteMaintenanceCycleResolutionFollowUpAction(var Rec: Record "EOS060 Work Request Cycle"; WorkRequest: Record "EOS060 Work Request"; MaintCycleResolution: Record "EOS060 Maint. Cycle Resolution"; var IsHandled: Boolean)

Raised before excuting the follow up action for a maintenance cycle resolution.

Parameters / Return Value

  • Rec Record "EOS060 Work Request Cycle"

    The related work request cycle.

  • WorkRequest Record "EOS060 Work Request"

    The related work request.

  • MaintCycleResolution Record "EOS060 Maint. Cycle Resolution"

    The related maintenance cycle resolution.

  • IsHandled Boolean

    Specifies if the procedure is handled by the subscriber.


OnBeforeSetStatusFinishedOnAfterPostFastWorkRequest

local procedure OnBeforeSetStatusFinishedOnAfterPostFastWorkRequest(var WorkRequest: Record "EOS060 Work Request"; var IsHandled: Boolean)

Raised before status change to Finished after fast work request post.

Parameters / Return Value

  • WorkRequest Record "EOS060 Work Request"

  • IsHandled Boolean

    Specifies if the procedure is handled by the subscriber.


OnBeforePostFastWorkRequest

local procedure OnBeforePostFastWorkRequest(var WorkRequest: Record "EOS060 Work Request"; var ActivityDescription: Text; var CloseRequest: Boolean)

Raised before fast work request post.

Parameters / Return Value

  • WorkRequest Record "EOS060 Work Request"

  • ActivityDescription Text

    The description of the activity associated to the work request.

  • CloseRequest Boolean

    Specifies whether to set status Finished after fast work request post.


OnAfterPostFastWorkRequest

local procedure OnAfterPostFastWorkRequest(var WorkRequest: Record "EOS060 Work Request")

Raised after fast work request post.

Parameters / Return Value

  • WorkRequest Record "EOS060 Work Request"


EOS Labs -