Announcement:Materials and articles for ProductCart 5 can be found at our brand new support center.

Create an account to edit articles | See Formatting Syntax for Wiki syntax | We look forward to your contribution!

Displaying the "Backorder Message" when the quantity on hand is low

Ordering and Backordering

ProductCart uses the following methods to determine whether a product can be purchased:

  • Current Product Inventory
  • A Product's Backorder Setting
  • A Product's Disregard Stock Setting

When a Product is added to the cart, the following scenarios can occur:

Product is in stock

IF the current stock level is equal to or greater than the quantity the customer has added to the cart OR if the “Disregard Stock” flag is set to YES for the product, THEN:

  1. the product is added to the cart
  2. no “Backorder” flag is set (even if Backorder is enabled)
  3. the current stock level is decreased immediately (to avoid a situation where other customers can buy “out-of-stock” products).

In this scenario, the product would not appear on the Backorder Report, since it was purchased when it was in stock. Also remember that if “Disregard Stock” is active for the product, then all inventory related features are ignored.

Product is out of stock, backorder OK

IF the number of units being purchased exceeds the current stock level for the product AND the “Backorder” flag is turned ON for the product AND the “Disregard Stock” flag is turned OFF (otherwise all inventory features are ignored), THEN:

  1. the Product is added to the cart, but this time the “Backorder” flag is ON
  2. the “Backorder Message” is shown
  3. the fact that the product is in a backorder status is saved into the database with all the other order details: even if the inventory levels change for that same product, the product will still appear on the Backorder Report (because at the time the item was purchased, it was back-ordered).

Product is out of stock, backorder NOT OK

IF the number of units being purchased exceeds the current stock level for the product AND the “Backorder” flag is turned OFF for the product AND the “Disregard Stock” flag is turned OFF (otherwise all inventory features are ignored), THEN: the customer will not be able to add the product to the cart.

Backorder Report: when a product appears there

To recap the above, the Backorder Report will display all orders that contain products that were in a “back-order” status at the time the order was placed… and have not yet shipped. The orders must be in one of the following status:

  • Pending
  • Processed
  • Partially Shipped
  • Shipping
  • Partially Return

Customization: show message on low inventory

You can make a small customization to the code to change the behavior so that the message is displayed when inventory falls below a certain number. For example, let's assume that you would like the message to be shown when inventory falls below 10 units.

  • Download the file viewPrdCode.asp from the pc folder
  • Locate the following code:
    If (scOutofStockPurchase=-1 AND CLng(pStock)<1 AND pserviceSpec=0 AND pNoStock=0 AND pcv_intBackOrder=1) OR (pserviceSpec<>0 AND scOutofStockPurchase=-1 AND iBTOOutofstockpurchase=-1 AND CLng(pStock)<1 AND pNoStock=0 AND pcv_intBackOrder=1) Then

  • Change the two instances of…

    CLng(pStock)<1

  • … with:

    CLng(pStock)<10

    … assuming 10 is the number that you want to use.

  • Save the file and upload it back to the pc folder.


QR Code
QR Code Displaying the &quot;Backorder Message&quot; when the quantity on hand is low (generated for current page)