woocommerce_fulfillment_updated_notification
Trigger the fulfillment updated notification on updating a fulfillment.
Использование
add_action( 'woocommerce_fulfillment_updated_notification', 'wp_kama_woocommerce_fulfillment_updated_notification_action', 10, 4 );
/**
* Function for `woocommerce_fulfillment_updated_notification` action-hook.
*
* @param int $order_id The order ID.
* @param Fulfillment $fulfillment The fulfillment object.
* @param \WC_Order|\WC_Order_Refund|false $order The order object.
* @param string $customer_note Optional customer note from the merchant.
*
* @return void
*/
function wp_kama_woocommerce_fulfillment_updated_notification_action( $order_id, $fulfillment, $order, $customer_note ){
// action...
}
- $order_id(int)
- The order ID.
- $fulfillment(Fulfillment)
- The fulfillment object.
- $order(\WC_Order|\WC_Order_Refund|false)
- The order object.
- $customer_note(строка)
- Optional customer note from the merchant.
Список изменений
| С версии 10.1.0 | Введена. |
| С версии 10.8.0 | Added $customer_note parameter. |
Где вызывается хук
woocommerce_fulfillment_updated_notification
woocommerce/src/Admin/Features/Fulfillments/OrderFulfillmentsRestController.php 501
do_action( 'woocommerce_fulfillment_updated_notification', $order_id, $fulfillment, $order, $customer_note );
Где используется хук в WooCommerce
woocommerce/includes/emails/class-wc-email-customer-fulfillment-updated.php 57
add_action( 'woocommerce_fulfillment_updated_notification', array( $this, 'trigger' ), 10, 4 );