CRS uses the derived availability status for determining if a SKU is in stock, out of stock, or backorderable. To determine if a SKU is preorderable, however, the StoreInventoryManager
class implements custom logic based on CRS-specific properties of the product
item type. These custom properties are preorderable
, useInventoryForPreorder
, and preorderEndDate
.
The logic works like this:
If
preorderable
isfalse
, the product’s SKUs are not preorderable.If
preorderable
istrue
anduseInventoryForPreorder
isfalse
, the SKUs are preorderable if the product’spreorderEndDate
is in the future or null.If
preorderable
istrue
anduseInventoryForPreorder
istrue
, a SKU is preorderable if the product’spreorderEndDate
is in the future or null, and the properties of the SKU’sinventory
item meet these conditions:stockLevel
is 0.preorderLevel
is greater thanpreorderThreshold
.