woocommerce_order_list_table_prepare_items_query_args
Provides an opportunity to modify the query arguments used in the (Custom Order Table-powered) order list table.
Usage
add_filter( 'woocommerce_order_list_table_prepare_items_query_args', 'wp_kama_woocommerce_order_list_table_prepare_items_query_args_filter' ); /** * Function for `woocommerce_order_list_table_prepare_items_query_args` filter-hook. * * @param array $query_args Arguments to be passed to `wc_get_orders()`. * * @return array */ function wp_kama_woocommerce_order_list_table_prepare_items_query_args_filter( $query_args ){ // filter... return $query_args; }
- $query_args(array)
- Arguments to be passed to wc_get_orders().
Changelog
Since 6.9.0 | Introduced. |
Where the hook is called
woocommerce_order_list_table_prepare_items_query_args
woocommerce/src/Internal/Admin/Orders/ListTable.php 402
$order_query_args = (array) apply_filters( 'woocommerce_order_list_table_prepare_items_query_args', $this->order_query_args );