Automattic\WooCommerce\Internal\Utilities
COTMigrationUtil::get_order_type()
Returns type pf passed id, post or order object.
Метод класса: COTMigrationUtil{}
Хуков нет.
Возвращает
Строку|null
. Type of the order.
Использование
$COTMigrationUtil = new COTMigrationUtil(); $COTMigrationUtil->get_order_type( $order_id );
Код COTMigrationUtil::get_order_type() COTMigrationUtil::get order type WC 9.2.3
public function get_order_type( $order_id ) { $order_id = $this->get_post_or_order_id( $order_id ); $order_data_store = \WC_Data_Store::load( 'order' ); return $order_data_store->get_order_type( $order_id ); }