If you are working against a cloud environment or have installed Mobile WMS app only, you may still download and explore the full source code from the PerTenant version.
The Per-Tenant version source code can be downloaded from University.taskletfactory.com
Planning your event subscribers
We know two Request Types are in play for this customization: GetRegistrationConfiguration
and PostAdhocRegistration
.
Both requests are directed to the "MOB WMS Adhoc Registr." codeunit:
This is visible if you inspect the standard "Mobile Document Types" setup.
The types defines which codeunits mobile requests are directed.
Knowing and understanding the source code of Mobile WMS extension
- is fortunately no longer a requirement
You will be able for follow examples from the API documentation and Tutorials with no real knowledge of what is going on behind the scenes.
The API Documentation is also where you in a different scenario would browse the DocumentType/RegistrationType for available events.
However, for the sake of tutorial take a little time to explore the source code for codeunit "MOB WMS Adhoc Regist.al", mainly references to:
MobWMSToolbox."CONST::AdjustQuantity"()
You will learn this constant was referenced from procedures including:
.GetRegistrationConfiguration()
.PostAdhocRegistration()
Both procedures offers Events you can subscribe to, including:
OnGetRegistrationConfiguration_OnAddSteps(_RegistrationType, HeaderFieldValues, _Steps, _RegistrationTypeTracking)
and
OnPostAdhocRegistrationOnCustomRegistrationType(_RegistrationType, _RequestValues, _CurrentRegistrations, _SuccessMessage, _RegistrationTypeTracking, _IsHandled)
We will use these events to implement our Positive AdjustQty in the next sections.
Next:
Unpl Pos Adjust(6/12) - The IntegrationEvent API (.al)