Automattic\WooCommerce\Internal\DataStores\Orders

OrdersTableDataStore::get_stock_reduced()publicWC 1.0

Gets information about whether stock was reduced.

Метод класса: OrdersTableDataStore{}

No Hooks.

Return

true|false. Whether stock was reduced.

Usage

$OrdersTableDataStore = new OrdersTableDataStore();
$OrdersTableDataStore->get_stock_reduced( $order );
$order(\WC_Order) (required)
Order object.

Код OrdersTableDataStore::get_stock_reduced() WC 7.1.0

public function get_stock_reduced( $order ) {
	$order = is_int( $order ) ? wc_get_order( $order ) : $order;
	return $order->get_order_stock_reduced();
}