Sort after pick
A store associate should be able to pick products in batches and later sort them into shipments appropriately.
Solution
The following section describes APIs, user exits, services, and other components.
When the Batches screen loads, the new and in-progress batches are displayed. Only the in-progress batches are retrieved from the database. However, the newly formed batches are only displayed, but batch records are not created in the database. The status of these batches is 1000, which indicates a draft batch.
From the Batches screen, a store associate can choose to Pick a new batch or Continue to pick an in-progress batch.
- Pick new batch
- On the Batches screen, when the store associate clicks Pick to pick products in a new batch, the
createStoreBatchAPI is called to create a batch record, the batch status changes to 1100, which indicatesopen batch
and the batch is assigned to the current store associate. All the shipment lines that were returned by thegetStoreBatchListAPI for that batch are passed to thecreateStoreBatchAPI, which returns theBatchNoandStoreBatchKeyattributes. If a shipment line is already being picked as part of another batch or being picked via single order picking, an appropriate error message is displayed.
- Pick in-progress batch
- On the Batches screen, a store associate can click Continue to pick products for an in-progress batch. If the store associate is not the person who began picking the batch, the application prompts the store associate to confirm whether to continue picking or not. If the store associate chooses to continue, then the
manageStoreBatchAPI is called, which updates theAssignedToUserIDof the batch to the current store associate.For more information about the APIs and validations, see Javadoc.
- Products in the batch
- The
getStoreBatchDetailsAPI is called to fetch the batch and products in the batch. The batch is fetched by using either the mandatoryStoreBatchKeyorBatchNoandOrganizationCodeattributes. If these attributes are not passed, the API throws an error. If there is no record corresponding to theStoreBatchKey, the API throws an error.- The
getStoreBatchDetailsAPI internally calls thegetShipmentLineListAPI to retrieve the shipment lines forStoreBatchKeyattribute that is passed in the input. Therefore, the bundle parents are not fetched to form the batch line. - Once the shipment lines are fetched, the batch lines are formed for every unique product. If the
ItemIDandUnitOfMeasureare common for two shipment lines, then a single batch line is formed for the product. - If the
PickLocationSeqattribute is set at theShipmentLinelevel, then thegetShipmentLineListAPI displays the products in the order in which they must be picked up. The sequence in which the products are displayed can be customized by implementing theYCDGetBatchPickPriorityUEuser exit. - The store associate can refine the batch lines to display all the products in the batch or only the products to be picked. The
BackroomPickComplete=Nattribute is used to filter and display only the unpicked batch lines. - The product details, such as product image, product ID, pick location, department, and the quantity to be picked are returned by the API in the output. The - and + buttons along with the Record Shortage link are displayed for each product.
The store associate can either scan a product bar code to pick a product or manually pick the product.
- The
- Pick products in the
SCANmode - When the store associate scans a product, the picked quantity is incremented by the scanned quantity. The
registerBatchPickAPI is called with theModeattribute set toSCANand the API uses theStoreBatchKeyattribute to determine theBatchTypeattribute, which isSORT_AFTER_PICK. The following logic is executed internally:- The
translatebar codeAPI is called with thebar codeDataandbar codeTypeattribute set toItemto fetch the product information. - Shipment lines with the same
ItemIDandUnitOfMeasureand having the sameBatchKeyas that passed in the input are retrieved. - Only those shipment lines with the attributes
BackroomPickComplete=NandIsPickable=Yare considered and the shipment line with the leastBatchPickPriorityis updated with the picked quantity.
- The
- Pick products in the
MANUALmode - If a scanner is not integrated with the system, the store associate can use the manual pick options to pick products. When the store associate clicks either the + or - button to increment or decrement the picked quantity, the
registerBatchPickAPI is called with theModeattribute set toMANUALPICKand the API uses theStoreBatchKeyattribute to determine theBatchTypeattribute, which isSORT_AFTER_PICK. The following logic is executed internally:- The
registerBatchPickAPI reads theActionattribute in the mandatoryItemelement from the input. If the store associate clicks the + button, theActionattribute isPICKand if the store associate clicks the - button, theActionattribute isUNDOPICK. If theActionattribute is not sent from the UI, then the value is defaulted toPICK- If the
Actionattribute isPICKin the input to the API, the following logic is executed:- Shipment lines with the same
ItemIDandUnitOfMeasureand having the sameBatchKeyas that passed in the input are retrieved. - Only those shipment lines with the attributes
BackroomPickComplete=NandIsPickable=Yare considered and the shipment line with the lowest value forBatchPickPriorityis updated with the pick quantity. - The
changeShipmentAPI is called to update theAssignedToUserIdattribute and theBackroomPickedQuantityattribute for the shipment line.
- Shipment lines with the same
- If the
Actionattribute isUNDOPICKin the input to the API, the following logic is executed:- The
getShipmentLineListAPI is called to retrieve the shipment lines that have the sameItemIDandUnitOfMeasurein the batch, by using theStoreBatchKeyattribute. - The picked quantity is first reduced for a shipment line with the highest
BatchPickPriorityandBackroomPickedQtygreater than 0. Once the quantity of the shipment line with the least SLA becomes 0, then the quantity is reduced from the shipment line of the next lowest SLA . - The
changeShipmentAPI is called to reduce theBackroomPickedQtyattribute for the shipment line.
- The
- If the
- The
- Record Shortage
- During the picking process, the store associate can select a product and click Record Shortage if there are insufficient quantities to fulfill the batch. The quantity of the product that the store associate marks short is displayed.
When a store associate clicks Record Shortage, the
getCommonCodeListAPI is called with theCodeTypeasYCD_PICK_SHORT_RESOLto fetch shortage reasons. By default, the only shortage reason isInventory Shortage
. When a store associate appliesInventory Shortage
as the shortage reason, products are back ordered based on default implementation. However, if you want to implement a custom logic and handle custom shortage reasons, you can use thehandleShortageForBatchLineUEuser exit.TherecordShortageForBatchPickAPI is called to determine the shipment and shipment line that need to be marked as short. The store associate picks the available products, and the remaining value is marked as short. The default shortage reason,Inventory Shortage
, is marked.- When the store associate chooses to save the shortage, the shorted quantity is updated on the shipment line.
- The API cancels the batch if all of the products in a batch are marked as short. In addition to canceling the batch, the shipment is also canceled if all of the products in the shipment are marked short.
The following validations are performed by therecordShortageForBatchPickAPI:- The
StoreBatchKeyandShortageReasonattributes, along with theItemelement are mandatory inputs to the API. If the mandatory inputs are not passed, then the appropriate error messages are displayed. - If the shortage reason is not valid, the appropriate error message is displayed. Once the store associate clicks OK, the shortage is applied and the user is taken to the original screen.
The
getStoreBatchDetailsAPI is called to refresh the screen and display all the products or only the products to be picked based on the filter selected.After a shipment is updated, the
registerBatchPickAPI determines whether the picking process is complete and updates the status of the batch to either 2000 or 3000 where 2000 indicates 'picking is complete and not staged' whereas 3000 indicates 'batch picking is complete'.Once a batch is completely picked, then thechangeShipmentStatusAPI is called. Multiple validations are performed to change the status of shipments, some of them are as follows:- If the shipment corresponding to a given shipment line is not already in
Backroom Pick in Progress
status, thechangeShipmentStatusAPI is called to change the shipment status fromReady for Backroom Pick
toBackroom Pick in Progress
. - If the shipment in completely picked, then the
changeShipmentStatusAPI is additionally called to update the status toReady for Customer Pickup
in case ofPickup in Store
orders andReady for Packing
in case ofShip from Store
orders.
- Assigning a staging location
- Once all the products are completely picked, an appropriate confirmation message is displayed and the store associate can choose to either assign a staging location or finish the batch pick process.
If the store associate clicks Assign Staging Location, the products are displayed with the Assign option for each product. Depending upon the option chosen in the Refine menu, either all the products or only the products that are yet to be staged are displayed.Note: Assigning a staging location to the products in a batch is driven by the
Staging location requiredrule. If the rule is enabled, only then the store associate can perform this task.The store associate can either scan the product to assign a staging location or click Assign against the product. The Selected Item screen is displayed along with an the Existing Staging Location, if any. On the Selected Item screen, the store associate can either scan the staging location bar code or manually enter the staging location ID and click Save to assign the staging location and return to the earlier screen.- When the store associate scans the product, the
translatebar codeAPI is called to translate the bar code to product information. If the store associate clicks Assign, the product information is retrieved from the UI. TheItemIDandUnitOfMeasureattributes are passed to thegetStoreBatchDetailsAPI to retrieve shipment lines corresponding to the batch line. - When the store associate either scans or manually enters a staging location, the following logic is executed:
- If the staging location is scanned, the
translatebar codeAPI is called with thebar codeTypeattribute set toHoldLocationto fetch the staging location ID. However, if theStaging location translation required
rule is disabled, thetranslatebar codeAPI call is skipped and the value in the Place in Staging Location field is directly updated in the database without any translation. TheYCD_Translate_Bar_Code_HoldLocationservice is used to implement bar code translations for staging locations and the service can be overridden. - When a staging location is manually entered and the store associate clicks Save, the
changeShipmentAPI is called to update theHoldLocationandStagedQuantityfor the shipment line. - After the products are staged, the
getStoreBatchDetailsAPI is called to display the updated information.
- If the staging location is scanned, the
User exits:- Custom logic can be implemented by using the
com.yantra.pca.ycd.japi.ue.YCDSortBatchLinesUEuser exit for thegetStoreBatchDetailsAPI to sort the products with a custom implementation. - Custom logic can be implemented by using the
yantra.pca.ycd.jap.ue.YCDGetBatchPickPriorityUEuser exit for thecreateStoreBatchAPI to calculate the batch pick priority. - Custom logic can be implemented to update the inventory by using the
com.yantra.pca.ycd.japi.ue.YCDInvokeUpdateInventoryUEuser exit, which is called by theregisterBatchPickAPI after each update of theBackroomPickedQuantityattribute on the shipment line. - The application behavior on selecting a custom shortage reason can be implemented by using the
YCDhandleShortageForBatchLineUEuser exit, which is invoked by therecordShortageForBatchPickAPI.
For more information about the APIs, see Javadoc.
- When the store associate scans the product, the
Device Specific Details
None.
Implementation
The following information describes the rules that must be configured for the feature:
- A store associate must have the following resource permissions to perform batch picking:
- Batch Pick Orders
- Manually update quantity while picking
- Configure the
Backroom Pick Shortage Resolutions
appropriately. By default, a shortage resolution namedAll Inventory Shortage
is available for the default organization. If you want to use the same shortage resolution for a new enterprise, you must either inherit the default organization's properties or use the following values to create the shortage resolution by using the Sterling Business Center.- Shortage Resolution: AllInventoryShortage
- Shortage Resolution Name: Inventory Shortage
For more information, see Manage backroom pick shortage resolutions. To inherit default organization's properties, see Defining an enterprise's primary information. If you create custom shortage resolutions, then you must have corresponding implementation as well. For more information, see Implementing custom shortage reasons.
- The Assign Staging Location button is visible only if the
Staging location requiredrule is enabled at the store level in the Sterling Business Center. - To enable a store associate scan the bar code of a staging location, you must enable the
Staging location translation requiredrule at the store level in the Sterling Business Center. If this rule is enabled, the store associate can see the bar code icon on the staging location text field, which indicates the support for bar code translation.For more information, see Configuring backroom pick rules.
- You must configure bar code types for your enterprise and set up the required services. The following bar code types are used in the application:
Itemfor product translationsHold Locationfor staging location translations
- To enable bar code translations for Staging Locations, you must configure the bar code translation preferences appropriately. For more information, see Setting up bar code translation preferences.