Is there a method to use the Woocommerce filter woocommerce_product_variation_get_regular_price or something similar?
Thank you.
Thanks.
To your first question; I’m not familiar with any method of running the bulk edit functions via an API or some such so that you can run it during import. That may be a question for the WooCommerce forums.
I can tell you that Markup-by-Attribute uses the price that is entered via the JScript dialog box when you run ‘Set regular|sale price’ — which adds another layer of complexity to your question. Additionally, if you are importing the attributes as well, you’d have to find some method of adding the markup during the import of the attributes but before the products are imported.
I’m going to assume it’s not possible.
Regarding your second question, I’m not entirely sure what you mean. You may be suggesting applying the markup on the get_regular_price function. Instead, I opted to apply the markup during the woocommerce_bulk_edit_variations hook so the price will be correct on the database.
I can see where in your situation if the markup value changes you will not want to run through hundreds of products to reset the prices and reapply the markup. But, at least, you won’t have to run through every variation individually.
Sorry I couldn’t be more help.
Thanks Mark.
I appreciate the info. We’ll poke around some and see if we can customize what we need.
No need to apologize. Markup-by-Attribute is, in itself, a huge time saver and I believe your notes will help us.
Thank you.
Thanks again. I’m going to mark this resolved.