woocommerce_orders_table_datastore_get_orders_query
Filter the query args before executing the query.
Использование
add_filter( 'woocommerce_orders_table_datastore_get_orders_query', 'wp_kama_woocommerce_orders_table_datastore_get_query_filter', 10, 2 );
/**
* Function for `woocommerce_orders_table_datastore_get_orders_query` filter-hook.
*
* @param array $query_vars The query vars.
* @param $that
*
* @return array
*/
function wp_kama_woocommerce_orders_table_datastore_get_query_filter( $query_vars, $that ){
// filter...
return $query_vars;
}
- $query_vars(массив)
- The query vars.
- $that
- -
Список изменений
| С версии 10.4.0 | Введена. |
Где вызывается хук
woocommerce_orders_table_datastore_get_orders_query
woocommerce/src/Internal/DataStores/Orders/OrdersTableDataStore.php 3421
$query_vars = apply_filters( 'woocommerce_orders_table_datastore_get_orders_query', $query_vars, $this );