woocommerce_after_product_ordering │ хук-событие │ WC 3.1.0

When products ordering update completed.

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

add_action( 'woocommerce_after_product_ordering', 'wp_kama_woocommerce_after_product_ordering_action', 10, 2 );

/**
 * Function for `woocommerce_after_product_ordering` action-hook.
 * 
 * @param int            $product_id    The product ID that was repositioned.
 * @param array $all_positions All product sort positions (product ID → actual menu_order
 *                                    value).
 *
 * @return void
 */
function wp_kama_woocommerce_after_product_ordering_action( $product_id, $all_positions ){
	// action...
}
$product_id(int)
The product ID that was repositioned.
$all_positions(array<int,int>)
All product sort positions (product ID → actual menu_order value).

Список изменений

С версии 3.1.0 Введена.

Где вызывается хук

WC_AJAX::product_ordering()
woocommerce_after_product_ordering
woocommerce/includes/class-wc-ajax.php 2803
do_action( 'woocommerce_after_product_ordering', $product_id, $menu_orders );

Где используется хук в WooCommerce

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