woocommerce_fulfillments_auto_fulfill_products filter-hookWC 10.1.0

Filter to get the list of the item, or variant ID's that should be auto-fulfilled.

Usage

add_filter( 'woocommerce_fulfillments_auto_fulfill_products', 'wp_kama_woocommerce_fulfillments_auto_fulfill_products_filter', 10, 2 );

/**
 * Function for `woocommerce_fulfillments_auto_fulfill_products` filter-hook.
 * 
 * @param array     $auto_fulfill_items List of product or variant ID's to auto-fulfill.
 * @param \WC_Order $order              The order object.
 *
 * @return array
 */
function wp_kama_woocommerce_fulfillments_auto_fulfill_products_filter( $auto_fulfill_items, $order ){

	// filter...
	return $auto_fulfill_items;
}
$auto_fulfill_items(array)
List of product or variant ID's to auto-fulfill.
$order(\WC_Order)
The order object.

Changelog

Since 10.1.0 Introduced.

Where the hook is called

FulfillmentsSettings::auto_fulfill_items_on_processing()
woocommerce_fulfillments_auto_fulfill_products
woocommerce/src/Internal/Fulfillments/FulfillmentsSettings.php 121
$auto_fulfill_product_ids = apply_filters( 'woocommerce_fulfillments_auto_fulfill_products', array(), $order );

Where the hook is used in WooCommerce

Usage not found.