Codeunit 70491905 EOS055.01 HU Status Management
Status management for handling units.
procedure ChangeStatusYesNo(var Hu: Record "EOS055 Handling Unit")
Opens a dialog to allow the user to change the status of a handling unit.
Hu Record "EOS055 Handling Unit"
The handling unit to be changed.
procedure ChangeStatus(var Hu: Record "EOS055 Handling Unit"; NewStatus: Enum "EOS055.01 Handling Unit Status")
Changes the status of a handling unit. This will cause additional validation and checks, depending on the status being set. Also note that, by default, you can not go backwards. This function does not modify the record. If the new status is the same as the current status, nothing will be done.
Hu Record "EOS055 Handling Unit"
The handling unit.
NewStatus Enum "EOS055.01 Handling Unit Status"
The new status to be set on the handling unit.
procedure ChangeStatus(var Hu: Record "EOS055 Handling Unit"; NewStatus: Enum "EOS055.01 Handling Unit Status"; Force: Boolean)
Changes the status of a handling unit. This will cause additional validation and checks, depending on the status being set.
Also note that, by default, you can not go backwards. This function does not modify the record.
If the new status is the same as the current status, nothing will be done, unless Force
is specified.
Hu Record "EOS055 Handling Unit"
The handling unit.
NewStatus Enum "EOS055.01 Handling Unit Status"
The new status to be set on the handling unit.
Force Boolean
Specifies whether status logic will be executed even if the current status is already the same as the new status.
procedure CheckHuConsistency(Hu: Record "EOS055 Handling Unit")
Checks the consistency of a handling unit.
Hu Record "EOS055 Handling Unit"
The handling unit to check.
procedure CheckHandlingUnitIssues(DocVariant: Variant)
Checks all handling units assigned to the given source document for issues. If any errors are found, a runtime error is thrown.
DocVariant Variant
The source document.
procedure CheckHandlingUnitIssues(SourceType: Integer; SourceSubtype: Integer; SourceNo: Code[20])
Checks all handling units assigned to the given source document for issues. If any errors are found, a runtime error is thrown.
SourceType Integer
The source document type.
SourceSubtype Integer
The source document subtype.
SourceNo Code[20]
The source document no.
procedure CheckHandlingUnitIssues(var HandlingUnit: Record "EOS055 Handling Unit")
Checks all given handling units for issues. If any errors are found, a runtime error is thrown.
HandlingUnit Record "EOS055 Handling Unit"
The handling units to check.
local procedure OnBeforeCheckHuConsistency(Hu: Record "EOS055 Handling Unit"; var Handled: Boolean)
Raised before consistency checks on a handling unit are evaluated.
Hu Record "EOS055 Handling Unit"
The handling unit being checked.
Handled Boolean
Indicates whether this event is handled. Use this to bypass consistency checks or implement your own.
local procedure OnAfterCheckHuConsistency(Hu: Record "EOS055 Handling Unit")
Raised after consistency checks on a handling unit have completed. You can add your own checks here.
Hu Record "EOS055 Handling Unit"
The handling unit being checked.
local procedure OnBeforeChangeStatus(var Hu: Record "EOS055 Handling Unit";var NewStatus: Enum "EOS055.01 Handling Unit Status";var StatusChangeAllowed: Boolean;var Force: Boolean)
Raised before the status of a handling unit is changed. You can use this to apply custom conditions or allow a status change that would otherwise not be allowed.
Hu Record "EOS055 Handling Unit"
The handling unit.
NewStatus Enum "EOS055.01 Handling Unit Status"
The new status that is about to be applied to the handling unit.
StatusChangeAllowed Boolean
Set this to true
to allow the status change. Setting this to false
will throw an error and will not change the status.
This will already be pre-set by the default logic and you can change this.
Force Boolean
Gets or sets if the status change was triggered in forced mode. You can change this. A forced status change will trigger all validation logic, even if the status itself does not change. By default this is false, and a status change of the same status will not do anything.
local procedure OnAfterChangeStatus(var Hu: Record "EOS055 Handling Unit"; NewStatus: Enum "EOS055.01 Handling Unit Status"; Force: Boolean)
Raised after the status of a handling unit has been changed.
Hu Record "EOS055 Handling Unit"
The handling unit.
NewStatus Enum "EOS055.01 Handling Unit Status"
The new status that has been applied.
Force Boolean
Specifies if the status change was performed in forced mode.
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.