Automattic\WooCommerce\Internal\Utilities

COTMigrationUtil::get_table_for_orders()publicWC 1.0

Get the name of the database table that's currently in use for orders.

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

Хуков нет.

Возвращает

Строку.

Использование

$COTMigrationUtil = new COTMigrationUtil();
$COTMigrationUtil->get_table_for_orders();

Код COTMigrationUtil::get_table_for_orders() WC 9.3.3

public function get_table_for_orders() {
	if ( $this->custom_orders_table_usage_is_enabled() ) {
		$table_name = OrdersTableDataStore::get_orders_table_name();
	} else {
		global $wpdb;
		$table_name = $wpdb->posts;
	}

	return $table_name;
}