wijnbergdevelopments
Forum Replies Created
-
Forum: Plugins
In reply to: [Tax Switch for WooCommerce] function calculate_alternate_priceHello Chrisce,
Thank you for your message. That is a great question. The function is used to get the opposite (‘alternate’) product price (including -> excluding OR excluding -> including). We think it’s best to avoid the tax calculation ourselfs. We create a temporary product to handle tax calculations properly. Since WooCommerce’s tax system is quite complex (dealing with different rates, locations, etc.), we let WooCommerce calculate the taxes. WooCommerce doesn’t have simple helper functions we can call/use to get the ‘opposite‘ tax.
The
calculate_alternate_price
function creates this temporary product (object) to tap into WooCommerce’s built-in tax logic. We than setting the opposite store tax settings to get the alternate price. It’s considering things like:- Tax rates and classes
- Store location settings
- Customer location
- Product tax status
Also, this is more ‘future updates WooCommerce proof’ in our opinion.
Don’t worry – the temporary product is just for calculations and is never saved to the database!!! It’s just a programming object in that function. That’s also why we use
unset($calculator)
at the end to clean things up.Does this make things a little more clear? Do you have (another) sugesstion? Maybe we should rename ‘alternate’ to ‘opposite’.
- This reply was modified 2 days, 23 hours ago by wijnbergdevelopments.
- This reply was modified 2 days, 23 hours ago by wijnbergdevelopments.
- This reply was modified 2 days, 22 hours ago by wijnbergdevelopments.
Forum: Reviews
In reply to: [Tax Switch for WooCommerce] Great plugin and good supportThanks Newtab!! ??
Forum: Reviews
In reply to: [Tax Switch for WooCommerce] A Massive 5 Stars for Wijnberg Developments!Thank you very much Lovisakarlsson!??
For other people checking this issue;?it has been resolved by making the plugin also compatible with YITH WooCommerce Product Add-ons & Extra Options Premium
No problem! The free version should be fine!! Please send me an e-mail ??
One quick question, because I do not think you have sent an email already. Do you use the free or pro version of YITH product add ons?
Ah, that’s unfortunate. If you use any caching plugins, please clear the cache and try again. If not, please send me an e-mail so we can fix it.
Hello, would you please try the newest version and give me feedback? Thanks!
Hello,
Coincidentally, we are working on that right now and the fix is almost ready! I will let you know when the update is available.
Forum: Plugins
In reply to: [Tax Switch for WooCommerce] Problems in order emailFor other people checking this issue; we have found the bug and the fix will soon be released. It had to do with some Woocommerce store rendering the orders pages on the backend using:
wp-admin/edit.php?post_type=shop_order
wp-admin/post.php?post=orderId&action=editBut other (newer) stores are using:
wp-admin/admin.php?page=wc-orders
wp-admin/admin.php?page=wc-orders&action=edit&id=orderIdForum: Reviews
In reply to: [Tax Switch for WooCommerce] Amazing supportThank you for your review and helping us testing!
Forum: Plugins
In reply to: [Tax Switch for WooCommerce] Problems in order emailPlease see https://wijnberg.dev/contact/
Forum: Plugins
In reply to: [Tax Switch for WooCommerce] Problems in order emailUnfortunately, I did not receive the email. Not sure why that is?
Forum: Plugins
In reply to: [Tax Switch for WooCommerce] Problems in order emailHello,
Thank you for your message. Could you send me an email please? This way, I can send you the beta that is developed.
Forum: Reviews
In reply to: [Tax Switch for WooCommerce] Works wellThank you very much!