Automattic\WooCommerce\Internal\DataStores\Orders

OrdersTableSearchQuery::__construct()publicWC 1.0

Creates the JOIN and WHERE clauses needed to execute a search of orders.

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

Хуков нет.

Возвращает

null. Ничего (null).

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

$OrdersTableSearchQuery = new OrdersTableSearchQuery();
$OrdersTableSearchQuery->__construct( $query );
$query(OrdersTableQuery) (обязательный)
The order query object.

Код OrdersTableSearchQuery::__construct() WC 9.0.2

public function __construct( OrdersTableQuery $query ) {
	$this->query          = $query;
	$this->search_term    = $query->get( 's' );
	$this->search_filters = $this->sanitize_search_filters( $query->get( 'search_filter' ) ?? '' );
}