woocommerce_order_item_needs_processing

The WooCommerce Billogram Integration woocommerce order item needs processing hook.

Description

apply_filters( 'woocommerce_order_item_needs_processing', (unknown) $product_is_downloadable_product_is_virtual, (unknown) $product, (unknown) $order_id ); 

Parameters (3)

0. $product_is_downloadable_product_is_virtual (unknown) => ! ( $_product->is_downloadable() && $_product->is_virtual() )
The product is downloadable product is virtual.
1. $product (unknown)
The product.
2. $order_id (unknown)
The order id.

Usage

To run the hook, copy the example below.
  1. $product_is_downloadable_product_is_virtual = apply_filters( 'woocommerce_order_item_needs_processing', $product_is_downloadable_product_is_virtual, $product, $order_id ); 
  2.  
  3. if ( !empty( $product_is_downloadable_product_is_virtual ) ) { 
  4.  
  5. // everything has led up to this point... 
  6.  
  7.  
The following example is for adding a hook callback.
  1. // define the woocommerce_order_item_needs_processing callback 
  2. function filter_woocommerce_order_item_needs_processing( $product_is_downloadable_product_is_virtual, $product, $order_id ) { 
  3. // make filter magic happen here... 
  4. return $product_is_downloadable_product_is_virtual
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'woocommerce_order_item_needs_processing', 'filter_woocommerce_order_item_needs_processing', 10, 3 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'woocommerce_order_item_needs_processing', 'filter_woocommerce_order_item_needs_processing', 10, 3 ); 

Defined (1)

The filter is defined in the following location(s).

/woocommerce-billogram2-extended.php  
  1. if ( false !== $_product && ! apply_filters( 'woocommerce_order_item_needs_processing', ! ( $_product->is_downloadable() && $_product->is_virtual() ), $_product, $order->id ) ) {