Catalog & Inventory · Module 3.8 Module 3.8

Quantity Rules

Control how products can be ordered — minimum quantities, maximum quantities, step values (case packs), default quantities, and backorder behaviour. Apply globally or per role, per product, or per category.

In plain terms: You sell cases of 12 bottles. The buyer must order at least 12 and the quantity must always be a multiple of 12 (12, 24, 36…). Set the Step to 12 and Min Qty to 12 — the quantity selector enforces it automatically. No more random orders of 7.

Minimum Quantity

Force a minimum units per line item. "You must order at least 6." Shown as a clear message on the product page.

Maximum Quantity

Cap how many units can be ordered in one go — for compliance, stock allocation, or promotional limits.

Quantity Step (Case Packs)

Force ordering in multiples. Step of 12 means the selector only allows 12, 24, 36, 48… Perfect for case-pack wholesale.

Default Quantity

Set the pre-filled quantity on product pages. New visitors see the quantity already set to your standard case size.

Role-Based Rules

Different rules per user role. Wholesale Gold can order a minimum of 24; Wholesale Bronze has a minimum of 12; retail has no minimum.

Custom Error Messages

Write your own message that appears when the buyer tries to checkout with an invalid quantity. Explain the requirement clearly.

Setup

Good Combinations

Quantity Rules + Discount Rules = enforce case packs and reward volume

Min 12, Step 12 for all wholesale buyers. Discount Rule adds 5% off at 24+, 10% at 48+. Buyers must order in cases, and are rewarded for buying more cases.

Quantity RulesDiscount Rules
Customer experience: Quantity selector shows 12 by default. As they increase to 24, a "5% off applied" banner appears. Natural incentive to increase order size.

Quantity Rules + Order Restrictions = full order control

Per-product case pack enforcement (Quantity Rules) combined with a minimum order value for the whole cart (Order Restrictions).

Quantity RulesOrder Restrictions
Result: Each product must be ordered in multiples of 12. The full cart must be at least $250. Both rules must be satisfied before checkout proceeds.

Key Settings Per Rule

FieldDescriptionExample
Min QuantityMinimum units per line item. Checkout is blocked if below this.12
Max QuantityMaximum units per line item. Cart quantity is capped at this value.144
StepQuantity increments. Step of 6 means only 6, 12, 18, 24… are valid.6
Default QuantityPre-fills the product page quantity selector with this value.12
Error MessageCustom message shown when a buyer's quantity violates the rule."Please order in multiples of 12"

Yes. Create two Quantity Rules for the same product: one targeting Wholesale Gold (min 24) and one targeting Wholesale Bronze (min 12). Role-specific rules take precedence over general rules. If both match, the more specific one (by role) wins.

Yes. Quantity validation runs on both the product page (quantity selector is constrained) and at cart/checkout (a rule violation blocks checkout and shows the error message). Even if a buyer somehow adds an invalid quantity, checkout is blocked.

Yes. The woob2b_min_quantity filter hook runs after all rule evaluation. You can return a modified minimum — for example, new accounts (registered less than 90 days ago) must order at least 24 while established accounts have the standard 12. See the Hooks reference for an example.