OrderInternalStatus
in package
Enum class for all the internal order statuses.
These statuses are used internally by WooCommerce to query database directly.
Table of Contents
- CANCELLED = 'wc-cancelled'
- The order is cancelled.
- COMPLETED = 'wc-completed'
- The order is completed.
- FAILED = 'wc-failed'
- The order is failed.
- ON_HOLD = 'wc-on-hold'
- The order is on hold.
- PENDING = 'wc-pending'
- The order is pending payment.
- PROCESSING = 'wc-processing'
- The order is processing.
- REFUNDED = 'wc-refunded'
- The order is refunded.
- get_all() : array<string|int, string>
- Returns every internal order status value defined by this enum, as a flat list of `wc-` prefixed slugs.
Constants
CANCELLED
The order is cancelled.
public
string
CANCELLED
= 'wc-cancelled'
COMPLETED
The order is completed.
public
string
COMPLETED
= 'wc-completed'
FAILED
The order is failed.
public
string
FAILED
= 'wc-failed'
ON_HOLD
The order is on hold.
public
string
ON_HOLD
= 'wc-on-hold'
PENDING
The order is pending payment.
public
string
PENDING
= 'wc-pending'
PROCESSING
The order is processing.
public
string
PROCESSING
= 'wc-processing'
REFUNDED
The order is refunded.
public
string
REFUNDED
= 'wc-refunded'
Methods
get_all()
Returns every internal order status value defined by this enum, as a flat list of `wc-` prefixed slugs.
public
static get_all() : array<string|int, string>
These are the seven core statuses, which is narrower than the set an order can hold. The enum
has no wc-checkout-draft, a status WooCommerce registers through the wc_order_statuses
filter and the Store API assigns to live orders during checkout. It cannot carry statuses an
extension registers either.
For the registered statuses, use wc_get_order_statuses(), which returns a value => label map on these same prefixed keys. OrderStatus lists a wider set of unprefixed slugs, including WordPress post statuses such as trash and auto-draft.
