Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Use this event to

Excerpt

TODO

Description

...

Add steps to be displayed at the mobile device when collecting values for output SetupTime and RunTime.

Description

At the mobile device Output Time may be collected at mobile by either...

  • Double-tap the Output line to collect "all steps" (including Time-steps, but also steps related to Quantity and Scrap).
  • Register only "Time"-steps by using the promoted "Output Time" action at the page.

This same event will add steps to both options mentioned above (on the other hand meaning: Steps cannot conditionally be added to only one of the two options).

Steps are generally sorted by Id. Existing output steps for Time the Mobile WMS is numbered 110 to 120, while subsequent existing Scrap-steps has Step Id 200 to 220.

  • ...If your new step should be displayed as the last Time-step (but prior to Scrap-steps), choose an Id between 130 and 199 for your step. 
  • ...If your new step should be the last step displayed at all, choose a high Id for your step, i.e. 10000


Due to the Production Output being implemented as Lookup-page each single Registration is posted right away (when Steps for the line is collected). For this reason no events exists to add "header" level steps.

Template

    [EventSubscriber(ObjectType::CodeunitCodeunit::"MOB WMS Adhoc Registr.", 'OnGetRegistrationConfigurationOnProdOutput_OnAddStepsToProductionOutputTime''', true, true)]
    local procedure OnGetRegistrationConfigurationOnProdOutput_OnAddStepsToProductionOutputTime(var _LookupResponse: Record "MOB NS WhseInquery Element"; var _Steps: Record "MOB Steps Element")
    begin
    end;

Example

    // [Example]  Add custom "StopCode" step if RunTime step is to be registered
    [EventSubscriber(ObjectType::CodeunitCodeunit::"MOB WMS Adhoc Registr.", 'OnGetRegistrationConfigurationOnProdOutput_OnAddStepsToProductionOutputTime''', true, true)]
    local procedure MyOnGetRegistrationConfigurationOnProdOutput_OnAddStepsToProductionOutputTime(var _LookupResponse: Record "MOB NS WhseInquery Element"; var _Steps: Record "MOB Steps Element")
    var
        RegisterRunTime: Boolean;
        ListValues: Text;
        DefaultValue: Text;
    begin
        Evaluate(RegisterRunTime, _LookupResponse.GetValue('RegisterRunTime', true));
        if RegisterRunTime then begin
            // demo dropdown options - could be built from database table but standard w1 demo data includes no Stop Codes
            ListValues := ';Stuck/Jammed;In repair;Out of materials';
            DefaultValue := 'Out of materials';

            // create new step id 190 = following existing time steps, but prior to scrap steps
            _Steps.Create_ListStepFromListValues(
                190,                        // Id
                'CustomStopCode',           // name
                'Stop Code',                // header
                '',                         // label
                '',                         // helpLabel
                ListValues,
                DefaultValue);
            _Steps.Save();
        end;
    end;



Filter by label (Content by label)
showLabelsfalse
showSpacefalse
sorttitle
titleMore examples
excerptTypesimple
cqllabel = "bc" and label = "production" and label = "example" and label = "onaddsteps"

...