woocommerce_analytics_(snake_name)_query_args
Filter query args given for the report.
Usage
add_filter( 'woocommerce_analytics_(snake_name)_query_args', 'wp_kama_woocommerce_analytics_snake_name_query_args_filter' ); /** * Function for `woocommerce_analytics_(snake_name)_query_args` filter-hook. * * @param array $query_args Query args. * * @return array */ function wp_kama_woocommerce_analytics_snake_name_query_args_filter( $query_args ){ // filter... return $query_args; }
- $query_args(array)
- Query args.
Changelog
Since 9.3.0 | Introduced. |
Where the hook is called
woocommerce_analytics_(snake_name)_query_args
woocommerce/src/Admin/API/Reports/GenericQuery.php 77
$args = apply_filters( "woocommerce_analytics_{$snake_name}_query_args", $this->get_query_vars() );