-
Notifications
You must be signed in to change notification settings - Fork 248
Shipment and Order Management
DEVELOP User Guide - This guide provides MSI Develop Branch/Active Development merchant information on Magento Multi Source Inventory (MSI) features and project.
MSI supports order management through Magento to update inventory for invoices, shipments, refunds, and cancellations. The following information details how to use the Source Selection Algorithm(SSA) for shipment recommendations and processes for managing and shipping your orders.
- MSI supported orders
- Order and Credit Memo Status and Reservations
- SSA at Shipment
- Rerun SSA and ship
- Override SSA recommendations and ship
- Refund orders and update inventory
- Cancel unshipped orders
For additional information on order management including processing orders, invoices, and shipments, see the Magento User Guide.
MSI supports single orders and multiaddress orders without additional configurations, out-of-the-box. As customers or your staff enter orders, MSI tracks inventory using reservations against the salable quantity, deducting from inventory quantity when invoicing and shipping the products.
For multiaddress orders, a series of single orders are generated in Magento grouped according to the multiple destination addresses. During checkout, customers select each set of products associated per address during checkout generates as single orders according to the destination address. Each order includes the products associated per address.
Multi Address Shipping - MultiShipping |
MSI manages inventory for these multiaddress orders exactly like single orders, allowing for SSA or overrides during shipment, partial shipments, canceling orders, and refunding with stock updates. See the following sections for details.
Inventory Management supports partial and full invoicing, payments, shipping, and cancellations per order. As you manage an order through processing, invoicing, shipment, and potentially refunds, Magento automatically enters or changes reservations to update the salable quantity for a stock (or sales channel) and the on-hand inventory quantity per source. You do not have to actively access or enter reservations. Completing actions to fulfill or refund an order does it for you.
These reservations always add to your salable quantity, with positive or negative amounts to increase or decrease quantities. These reservations are compensations, updating your on-hand inventory and salable quantities for up-to-date amounts for your store.
- Shipments: After invoicing orders, send partial or full shipments until you fulfill the entire order. Each shipment converts reservation, deducting the amount from the product quantity per source. Reservation compensations enter to clear the reservations. The salable quantity (available) updates for your stock from the current aggregated source quantities. If you send partial shipments, each shipment deducts that amount from your product quantity and updates reservations. Any unshipped product reservations remain in place until they are also shipped at a later time. This keeps your salable amount current, gives you control over product inventory, and supports multiple source shipments and backorders.
- Canceled Orders: If a customer cancels their order prior to shipment (partial or in full), a new reservation is entered to return the inventory amount to the salable quantity. The reservations effectively cancel each other out, not deducting the quantity from any sources. Other customers can actively purchase those product quantities through the associated stocks and sales channels.
- Refunded Orders: If a customer requests a refund, issue the credit memo for the partial or full product amounts. When you receive the returned products, enter a credit memo to provide the funds and update product amounts. When selecting the return to stock option, Magento adds quantities back to the products and sources that shipped the orders and reservation compensations to update salable quantities for the associated stock.
Simple orders begin with a shopping cart, continue to payment, and end with a satisfied delivery. In these orders, Inventory Management easily processes reservations against the availability (or salable quantity) in the cart and checkout, and deducts fro the on-hand inventory at shipment.
Process for a Simple Order |
A more complicated order may have partial cancellations, partial shipments, and refunds. In these situations, reservations affect the available inventory to add quantities for cancellations and refunds and decrease quantities when ordered and shipped.
Process for a Complicated Order |
The following table details order and credit memo status with reservation changes entered by Magento to manage your inventory.
Order Status | Description | Reservation for Salable Quantity |
---|---|---|
Open | New and just submitted, no processing | Reservation saved when order is submitted for the stock |
Canceled | Canceled in partial or full prior to payment | Reservation compensation entered to return partial or full quantity back to the stock salable quantity |
On Hold | Payment and shipping not processed or invoiced | Reservation stays in place |
Suspected Fraud | Not processed due to fraud | If approved or in review, reservation stays in place. If declined, reservation stays in place until merchant makes a decision. If canceled, reservation compensation entered to return full quantity back to the stock salable quantity. |
Pending | Waiting for payment | Reservation stays in place |
Processing | Payment processing, not received | Reservation stays in place |
Pending Payment | Payment not received | Reservation stays in place |
Payment Review | Payment being reviewed for processing and completion | Reservation stays in place |
Complete | Paid and shipped in full | Reservation amount deducts from product quantity for the selected source when invoiced partial or in full. Reservation compensation entered to update the total salable quantity. |
Closed | Refunded or archived | If archived, no change in quantities. If refunded in partial or full, reservation compensation entered and converted to add back product quantities per source and salable quantity per stock. |
Credit Memo Status | Description | Reservation for Salable Quantity |
---|---|---|
Open | The refund is due, not completed | No change in reservations |
Refunded | Completed, funds returned | If refunded in partial or full, reservation compensation entered and converted to add back product quantities per source and salable quantity per stock |
Jenny Sanders orders bikes and clothing for her family vacation and fun. She sees some great sales on your Biking Adventures store with stock and sources spanning the United States, Canada, and Europe. Time to put in an order!
She buys two great park bikes for her daughters, a BMX bike for her son, a nice mountain bike for herself, and a modern German cross-country bike for her husband. The store had a sale on cute shirts, so she bought some for the whole family to match. See the list of vacation purchases below, the matching SKUs, and the reservations entered against the stock salable quantities.
Example order from Biking Adventures |
She shows her family the great finds, but makes some changes. Before payment completes, she cancels two of the 33-BikeFun SKUs (her daughters did not like them). This is a partial cancellation due to payment pending, so no credit memo needed. To update, Magento adds back to the salable quantity stock for Canada. The order is paid and all products ship, arriving in time for vacation! Magento updates the salable quantity and source quantities for the shipping warehouses for the shipped products.
But her husband didn't quite fit in the shirt. Jenny requests a refund and sends back his shirt. When creating the credit memo, this adds one 54-BikeLife shirt back to the Canada stock and shipping warehouse.
- Shipped products: With products purchased and shipped, Magento updates the inventory. Reservation "convert" to on-hand inventory Quantity deductions from the shipped source. Those reservations are cleared with reservation compensations. The Salable Inventory updates for the stock.
- Canceled products: By canceling stock, Magento removes the reservation for that product. Reservation compensation entered to the stock Salable Quantity to add back quantities for the partial cancellation of two shirts. This does not affect the inventory quantity at the source level.
- Credit Memo/Refunded product: By returning stock, we need to add back to our quantities. When issuing the credit memo, we select to return to stock. Magento adds back inventory quantity to the shipped source for the product. Reservation compensations enter to the stock Salable quantity to increase available stock.
Example Reservation and Inventory updates |
The Source Selection Algorithm provides recommendations for partial and full shipments. You can access the SSA when creating shipment invoices for an order. Use these recommendations when shipping, or override with your own selections. You can run the algorithms every time you submit a shipment.
Through the Ship page, run the Priority algorithm to determine the best options for matching ordered quantities and available sources. The system supports shipping a complete order from one source and breaking the order into multiple partial shipments across multiple sources. You can access these options for immediate fulfillment and staggered shipments to send smaller amounts over a period of time.
To complete and ship an order, it must have completed payment and be invoiced. After payment, you can rerun the SSA for recommendations and ship from one or more sources, or override the SSA recommendations with manually set sources and quantities to fulfill shipment.
- We recommend rerunning the SSA to review recommendations for every shipment.
- If you want to change the selections, you can override with manual source deductions.
Before proceeding to shipment, you should rerun the SSA. You can run the algorithm and complete shipping for entire orders or partially for sending smaller amounts over many shipments. If you manually change the deductions and rerun SSA, it clears your changes and presents the latest best matches according to the algorithm.
When you rerun SSA, it checks the current quantities per source, weighing the best deductions in inventory quantities based on the selected algorithm. The initial SSA algorithm determines shipments based on source priority configured on the stock. Additional algorithms will be available in later releases, or through custom code and extensions.
Note: Ensure the order has completed payment and is invoiced prior to shipping.
-
On the Admin sidebar, tap Sales. Then, choose Orders.
-
Tap the View link for an active order.
-
Tap Ship on the upper menu bar. The ordered products, quantities, sources, and SSA options display.
Source Selection Shipment in an Order -
Tap Source Selection Algorithm to rerun and review recommendations:
-
Source Priority: Recommends shipments from sources according to the orders of sources assigned to the stock.
-
Distance Priority: Recommends shipments from sources closest to the shipping address based on physical distance or shortest time to deliver.
Important Distance Priority: If routes and data does not return for the selected Computation mode (driving, bicycling, or walking) for a shipment, the SSA defaults to using the Source Priority.
Source Selection Algorithm list -
-
The Items Ordered table updates with recommended amounts to deduct.
-
For the Select a Source to Ship from, select a Source from the drop-down menu matching the recommendation.
-
Tap Proceed to Shipment. Review and complete shipment. The Inventory section displays the source, products shipping, total ordered quantity, and quantity to ship.
MSI Shipping Inventory information -
Tap Submit Shipment to complete.
If not enough products are available from one source, you will need to repeat this process to ship additional products per source. As you enter additional shipments, the information includes the current total shipped.
MSI Shipping Inventory information for multiple shipments |
You can manually override and set each source and quantity of products in an order directly through the Ship option. This option is helpful when you want to control every product deduction or when fulfilling partial shipments.
When selected, the Source Selection page displays options for selecting a source to ship from, the ordered quantity of product(s), and the currently available sources and salable quantities. Customers are not charged additional amounts when you override and modify quantities per source.
Note: Ensure the order has completed payment and is invoiced prior to shipping.
-
On the Admin sidebar, tap Sales. Then, choose Orders.
-
Tap the View link for an active order (or your test order).
-
Tap Ship on the upper menu bar. The ordered products, quantities, sources, and SSA options display.
Source Selection Shipment in an Order -
For the Select a Source to Ship from, select a Source from the drop-down menu. The Qty to Deduct field is enabled to enter the amount to ship.
For this example, the Texas Warehouse is selected with 20 entered. To keep an on-hand quantity, this could be changed to 10 and another warehouse selected to fulfill the order.
Quantities Selected per Source -
Tap Proceed to Shipment to initiate shipping. This overrides the SSA recommendations. The inventory reservations convert to quantity deductions against the selected sources.
-
Review and complete shipment. The Inventory section displays the source, products shipping, total ordered quantity, and quantity to ship.
MSI Shipping Inventory information -
Tap Submit Shipment to complete.
If not enough products are available from one source, you will need to repeat this process to ship additional products per source. As you enter additional shipments, the information includes the current total shipped.
MSI Shipping Inventory information for multiple shipments |
You can refund orders (via a credit memo), either in full or in part. For more information on refund credit memos, see the Magento User Guide.
After the order is refunded, enter another credit memo to return the product quantity to the originating source:
-
On the Admin sidebar tap Sales. Then, choose Orders.
-
Find the completed order in the grid. Then in the Action column, click the View link to open the order.
-
In the button bar at the top of the page, tap Credit Memo. The button appears only after an order is invoiced.
-
Complete any additions and changes needed for handling refunds in your business.
-
Tap the Return to Stock checkbox. The product quantity will return to the specific source. For example, if the product came from a warehouse in New York, the quantity adds back to that source.
-
Complete the credit memo. You can verify the update in stock through the product page.
If an order has not been shipped and is cancelled, MSI automatically returns the product stock to the salable quantity. Until invoice and shipping, purchased products are reserved against the salable quantity, not deducted from the actual quantity. Invoicing and shipping converts the reservation to an inventory deduction.
Behind the scenes, MSI automatically enters a compensation reservation removing the hold on the product quantity. The quantity returns to the aggregated virtual salable quantity.
Multi-Source Inventory developed by Magento 2 Community
- Technical Vision. Catalog Inventory
- Installation Guide
- List of Inventory APIs and their legacy analogs
- MSI Roadmap
- Known Issues in Order Lifecycle
- MSI User Guide
- 2.3 LIVE User Guide
- MSI Release Notes and Installation
- Overview
- Get Started with MSI
- MSI features and processes
- Global and Product Settings
- Configure Source Selection Algorithm
- Create Sources
- Create Stock
- Assign Inventory and Product Notifications
- Configure MSI backorders
- MSI Import and Export Product Data
- Mass Action Tool
- Shipment and Order Management
- CLI reference
- Reports and MSI
- MSI FAQs
- DevDocs Documentation
- Manage Inventory Management Modules (install/upgrade info)
- Inventory Management
- Reservations
- Inventory CLI reference
- Inventory API reference
- Inventory In-Store Pickup API reference
- Order Processing with Inventory Management
- Managing sources
- Managing stocks
- Link and unlink stocks and sources
- Manage source items
- Perform bulk actions
- Manage Low-Quantity Notifications
- Check salable quantities
- Manage source selection algorithms
- User Stories
- Support of Store Pickup for MSI
- Product list assignment per Source
- Source assignment per Product
- Stocks to Sales Channel Mapping
- Adapt Product Import/Export to support multi Sourcing
- Introduce SourceCode attribute for Source and SourceItem entities
- Assign Source Selector for Processing of Returns Credit Memo
- User Scenarios:
- Technical Designs:
- Module Structure in MSI
- When should an interface go into the Model directory and when should it go in the Api directory?
- Source and Stock Item configuration Design and DB structure
- Stock and Source Configuration design
- Open Technical Questions
- Inconsistent saving of Stock Data
- Source API
- Source WebAPI
- Sources to Sales Channels mapping
- Service Contracts MSI
- Salable Quantity Calculation and Mechanism of Reservations
- StockItem indexation
- Web API and How To cover them with Functional Testing
- Source Selection Algorithms
- Validation of Domain Entities
- PHP 7 Syntax usage for Magento contribution
- The first step towards pre generated IDs. And how this will improve your Integration tests
- The Concept of Default Source and Domain Driven Design
- Extension Point of Product Import/Export
- Source Selection Algorithm
- SourceItem Entity Extension
- Design Document for changing SerializerInterface
- Stock Management for Order Cancelation
- Admin UI
- MFTF Extension Tests
- Weekly MSI Demos
- Tutorials