Stock Statuses & Orderability¶
This page documents the stock statuses, webshop article statuses, and the conditions under which a product variant can or cannot be ordered. It reflects the current (legacy) platform behaviour and serves as a reference for the new platform.
K3 Article Item Statuses¶
K3 (Microsoft Dynamics / Navision) assigns a status to each article item. These statuses control whether a variant is considered active and orderable.
Source: application/models/K3_article_item_status_link.php
| Constant | Value | Meaning |
|---|---|---|
ACTIEF |
'ACTIEF' |
Normally orderable |
UITLOPEND |
'UITLOPEND' |
Being phased out |
VERVALLEN |
'VERVALLEN' |
Expired / no longer deliverable |
OPAANVRAAG |
'OPAANVRAAG' |
Available via supplier on request |
GEBLOKKEERD |
'GEBLOKKEER' |
Blocked |
getNotActive()
Returns true when the status is GEBLOKKEERD, UITLOPEND, or VERVALLEN. A variant's default falls back to UITLOPEND when not active.
Webshop Article Statuses¶
The Zwerfkei webshop maintains its own publication status for each article, independent of the K3 status.
Source: application/models/Article.php
| Constant | Value | Meaning |
|---|---|---|
offline |
0 |
Not published, invisible to customers |
online |
1 |
Published and active |
discontinued |
2 |
Being phased out (still visible to customers) |
Note
Customers only see articles with status online (1) or discontinued (2).
Orderable Flag¶
An article can be explicitly marked as non-orderable via a product option.
Source: application/models/Article.php — getIsOrderable()
Option type ID: 200 (application/models/Article_option_type.php)
- Values:
'Ja'(yes) or'Nee'(no) - Checked when adding to the shopping cart in
Shoppingcart.phpandArticles.php
Stock Status Display for Customers¶
The getStockStatus() method on Article translates raw stock data into a customer-facing label.
Source: application/models/Article.php — getStockStatus()
| Condition | Displayed text | Stock Color state |
|---|---|---|
stockTotal > 1 |
"op voorraad" | state-green-default |
0 < stockTotal < 2 |
"beperkt op voorraad - wees er snel bij!" | state-orange-default |
Out of stock, binnenkort_leverbaar date in the future |
"medio [month]" | state-orange-default |
Out of stock, available via supplier (OPAANVRAAG) |
"4-10 dagen" | state-orange-default |
| Out of stock | "niet op voorraad" | state-red-default |
| No Elasticsearch data available | "voorraad onbekend" | state-red-default |
Stock Fields & Flags¶
K3 Article (application/models/K3_article.php)¶
| Field | Description |
|---|---|
Blocked |
Article is blocked |
NoStockPosting |
Article always counts as in stock — returns 1000 as a dummy value |
StockQuantity / StockQuantity2 |
Actual stock quantities |
StockThreshold |
Low-stock threshold value |
K3 Article Variant (application/models/K3_article_variant.php)¶
| Method | Description |
|---|---|
getFreeStock() |
Free stock (after subtracting reservations) |
getRealStock() |
Actual stock (from K3_article_availability or WEBONLY) |
getStockLutje() |
Stock reserved for wholesale |
When Ordering Is Blocked¶
A product variant cannot be added to the cart when any of the following conditions applies:
- The
bestelbaaroption (type ID 200) is set to'Nee' - K3 status is
VERVALLENorGEBLOKKEERD - Webshop status is
offline(0) - Requested quantity exceeds free stock and the article is not available via supplier
- The
Blockedflag on the K3 article istrue - The variant has status
UITLOPENDorVERVALLENandstock_free + stock_lutje <= 0
Future Availability¶
Option: binnenkort_leverbaar (date field)
Migration: 20170119112029_binnenkort_leverbaar.php
When the binnenkort_leverbaar date is in the future, the stock status display shows "medio [month] leverbaar" instead of an out-of-stock message.
Click & Collect¶
Source: application/models/ClickAndCollect.php
| Status | Description |
|---|---|
no_stock_found |
Reserved items are not present in physical store stock |
Info
The no_stock_found status was added via migration 20250710111129_add_not_in_stock_status_to_click_and_collect.php.