Inventory and Backordering
How you manage inventory on your site depends largely on how you want to respond to a situation in which a given item is out of stock. In such a situation you can either place the item on backorder, or you can notify the customer that the item is not currently available.
The FlagInventory and LocalInventory components, which have an affinity with the Inventory stage, coordinate with the Product Info stage to support either response.
Flag Inventory Checking
Quantity-Based Inventory Checking
Flag Inventory Checking
The FlagInventory component is designed to identify items in the items SimpleList object that are out of stock. When this component runs, it iterates through the items in the items SimpleList object to verify that the _product_in_stock
name/value pair for a given item is not zero (0).
If the _product_in_stock
name/value pair evaluates to zero (0), the FlagInventory component can respond in one of two ways. The component supports a Disallow Backorder property, which you set by using the property page for the component. If the Disallow Backorder check box is selected, and _product_in_stock
evaluates to zero (0), the FlagInventory component adds a _pur_out
_of
_stock
message to the _Purchase_Errors
SimpleList object. If the Disallow Backorder check box is not selected, and _product_in
_stock
evaluates to zero (0), then the _inventory_backorder
name/value pair for the affected item is set to zero (0).
Note
- The FlagInventory component requires that each line item specify
_product_in_stock
.
Quantity-Based Inventory Checking
The LocalInventory component compares the number of units in the Quantity
name/value pair to the number in the _product_local
_inventory
name/value pair. The _product_local_inventory
name/value pair should represent the actual number of items in stock. If the Quantity
name/value pair exceeds _product_local_inventory
, the difference between these two numbers is written to the _inventory_backorder
name/value pair, provided that the LocalInventory component is configured to allow backordering. Otherwise, the LocalInventory component, like the FlagInventory component, writes a _pur_out_of_stock
message to the _Purchase_Errors
SimpleList object.
The LocalInventory component should be added to the basket pipeline to check item availability when the product is added to the basket. If you include the LocalInventory component in the pipeline for your site, the script that you use to display the basket to your users should be written to notify them that a requested item is either out of stock or on backorder.
Note
- The LocalInventory component requires that each line item specify
product_local_inventory
.
Copyright © 2005 Microsoft Corporation.
All rights reserved.