(hook_prefix)stock_quantity
Usage
add_filter( '(hook_prefix)stock_quantity', 'wp_kama_hook_prefixstock_quantity_filter', 10, 2 ); /** * Function for `(hook_prefix)stock_quantity` filter-hook. * * @param $parent_data_stock_quantity * @param $that * * @return */ function wp_kama_hook_prefixstock_quantity_filter( $parent_data_stock_quantity, $that ){ // filter... return $parent_data_stock_quantity; }
- $parent_data_stock_quantity
- -
- $that
- -
Where the hook is called
(hook_prefix)stock_quantity
woocommerce/includes/class-wc-product-variation.php 340
$value = apply_filters( $this->get_hook_prefix() . 'stock_quantity', $this->parent_data['stock_quantity'], $this );