woocommerce_untrash_order

ACTION woocommerce\src\Internal\DataStores\Orders\OrdersTableDataStore.php (ligne 2697) github
Fires before an order is restored from the trash.

Paramètres

Entrée :
$order->get_id(
Sortie :
@param int    $order_id        Order ID.
@param string $previous_status The status of the order before it was trashed.

Utilisation

// Ajouter une fonction au hook action 'woocommerce_untrash_order'
add_action('woocommerce_untrash_order', 'ma_fonction_personnalisee', 10, 1);

function ma_fonction_personnalisee($order->get_id() {
    // Votre code ici
    error_log('Hook woocommerce_untrash_order déclenché');
}

Actualités

Chargement des actualités...