woocommerce_webhook_topics
Использование
add_filter( 'woocommerce_webhook_topics', 'wp_kama_woocommerce_webhook_topics_filter' ); /** * Function for `woocommerce_webhook_topics` filter-hook. * * @param $array * * @return */ function wp_kama_woocommerce_webhook_topics_filter( $array ){ // filter... return $array; }
- $array
- -
Где вызывается хук
woocommerce_webhook_topics
woocommerce/includes/admin/settings/views/html-webhooks-edit.php 65-86
$topics = apply_filters( 'woocommerce_webhook_topics', array( '' => __( 'Select an option…', 'woocommerce' ), 'coupon.created' => __( 'Coupon created', 'woocommerce' ), 'coupon.updated' => __( 'Coupon updated', 'woocommerce' ), 'coupon.deleted' => __( 'Coupon deleted', 'woocommerce' ), 'coupon.restored' => __( 'Coupon restored', 'woocommerce' ), 'customer.created' => __( 'Customer created', 'woocommerce' ), 'customer.updated' => __( 'Customer updated', 'woocommerce' ), 'customer.deleted' => __( 'Customer deleted', 'woocommerce' ), 'order.created' => __( 'Order created', 'woocommerce' ), 'order.updated' => __( 'Order updated', 'woocommerce' ), 'order.deleted' => __( 'Order deleted', 'woocommerce' ), 'order.restored' => __( 'Order restored', 'woocommerce' ), 'product.created' => __( 'Product created', 'woocommerce' ), 'product.updated' => __( 'Product updated', 'woocommerce' ), 'product.deleted' => __( 'Product deleted', 'woocommerce' ), 'product.restored' => __( 'Product restored', 'woocommerce' ), 'action' => __( 'Action', 'woocommerce' ), ) );