Action to signal that the `stock_status` for a product has changed.
$product, $this->updated_props
Sortie :
@param int $product_id The ID of the product. @param string $stock_status The new stock status of the product. @param WC_Product $product The product object.
// Ajouter une fonction au hook action 'woocommerce_product_object_updated_props'
add_action('woocommerce_product_object_updated_props', 'ma_fonction_personnalisee', 10, 1);
function ma_fonction_personnalisee($product, $this->updated_props) {
// Votre code ici
error_log('Hook woocommerce_product_object_updated_props déclenché');
}
Chargement des actualités...