Repository › Forums › Support › WooCommerce Extended Coupon Features PRO › Free product choice in combination with Advanced Dynamic Pricing For Woocommerc › Reply To: Free product choice in combination with Advanced Dynamic Pricing For Woocommerc

#15531
Soft79
Keymaster

I see, it looks like the plugin has a filter for that also:


add_filter( 'wdp_skip_cart_item', function( $skip, $cart_item, $product ) {
	if ( isset( $cart_item['_wjecf_free_product_coupon'] ) ) {
		$skip = true;
	  }
	return $skip;
  }, 10, 3);

This will prevent the advanced pricing plugin from overwriting the price of a free gift.