Closed tasqon closed 5 years ago
what is the intended purpose of setting the price field to empty? as there may be various other ways of achieving the intended purpose.
in wholesale one want show the products and its variations but not the price.
right...
apart from solving this issue, there are several solutions to hiding prices including some plugins ..
apart from any other options also check the filter woocommerce_get_price_html
For example some code like this could be added to hide all prices:
add_filter( 'woocommerce_get_price_html', 'hide_price', 10, 2);
function hide_price($pricehtml, $product){
return '';
}
you could also test some attribute of the $product to hide prices based on a rule
I would say this is not a bug because variation price is a mandatory field, it is not allowed to be set to empty. And for the other fields the blank values are synchronising fine, so they should do for price as well if price is modified to be optional...
A separate matter is how to hide the price if you do not want to show prices on the front end.
I have variable products in 6 languages. Changing the Regular Price by leaving the field empty does change the product in the main language but not the other five language.
Can you reproduce this issue on default Wordpress theme (eg Storefront)?
Yes
Can you reproduce this issue when all other plugins are disabled except WooCommerce, Polylang and Hyyan WooCommerce Polylang Integration?
Yes
What product versions and settings are you using when this issue occurs?
Steps to Reproduce
What I Expected
After clicking on "Update" I expect that for the main language AND all other languages the Variable Product regular price change to "empty".
What Happened Instead
The Variable Product regular price ONLY changes for the main language. The other languages keep unchanged.
WordPress Environment