mikethome
Forum Replies Created
-
SELECT
CONCAT('site_', sites.site_id) AS site_domain,
o.ID AS order_number,
DATE_FORMAT(o.post_date, '%m/%d/%Y') AS order_date,
pm_sku.meta_value AS SKU,
p.post_title AS product_name,
oim_quantity.meta_value AS quantity,
pm_cost.meta_value AS item_cost_of_goods,
oim_price.meta_value AS item_price,
oim_shipping.meta_value AS item_shipping,
oim_tax.meta_value AS item_tax,
o.post_type AS order_type,
pm_vendorshipcost.meta_value AS lu_freight_cost
FROM (
SELECT 24 AS site_id UNION ALL
SELECT 25 UNION ALL
SELECT 35 UNION ALL
SELECT 37 UNION ALL
SELECT 39 UNION ALL
SELECT 40 UNION ALL
SELECT 41
) sites
JOIN wp_posts AS o ON o.post_type = 'shop_order' AND o.post_status = 'wc-completed'
LEFT JOIN CONCAT('wp_', sites.site_id, 'woocommerce_order_items') AS oi ON o.ID = oi.order_id LEFT JOIN CONCAT('wp', sites.site_id, 'woocommerce_order_itemmeta') AS oim_quantity ON oi.order_item_id = oim_quantity.order_item_id AND oim_quantity.meta_key = '_qty' LEFT JOIN CONCAT('wp', sites.site_id, 'woocommerce_order_itemmeta') AS oim_price ON oi.order_item_id = oim_price.order_item_id AND oim_price.meta_key = '_line_total' LEFT JOIN CONCAT('wp', sites.site_id, 'woocommerce_order_itemmeta') AS oim_shipping ON oi.order_item_id = oim_shipping.order_item_id AND oim_shipping.meta_key = '_line_shipping' LEFT JOIN CONCAT('wp', sites.site_id, 'woocommerce_order_itemmeta') AS oim_tax ON oi.order_item_id = oim_tax.order_item_id AND oim_tax.meta_key = '_line_tax' LEFT JOIN CONCAT('wp', sites.site_id, 'postmeta') AS pm_sku ON oi.order_item_id = pm_sku.post_id AND pm_sku.meta_key = '_sku' LEFT JOIN CONCAT('wp', sites.site_id, 'postmeta') AS pm_cost ON oi.order_item_id = pm_cost.post_id AND pm_cost.meta_key = '_cost_of_goods' LEFT JOIN CONCAT('wp', sites.site_id, '_postmeta') AS pm_vendorshipcost ON oi.order_item_id = pm_vendorshipcost.post_id AND pm_vendorshipcost.meta_key = 'vendorshipcost'Couldn’t code be written to loop through each site? Typically the data tables have a ‘wp_XX’ prefix where the ‘XX’ represents the subdomain #. Run the query on one subdomain, concatenate the results, repeat.
Forum: Plugins
In reply to: [WooCommerce Stripe Payment Gateway] Hardcode ‘usd’ as currencySaif,
Thanks for the reply. Literally found our fix 5 minutes before you posted.
Inside woocommerce /wp-content/plugins/woocommerce/includes is the class-wc-checkout.php file. Line 433 we changed to:
$order->set_currency( strtolower(get_woocommerce_currency()) == ‘points’ ? ‘USD’ : get_woocommerce_currency() );
It appears to be working! If anyone sees an issue with making this modification (aside from having to modify every time there is an update), please let me know.
Forum: Plugins
In reply to: [Wallet for WooCommerce] About multisite cross site balancea feature request that might be needed by some would be to have the ability to keep separate balances for each site. i.e. a user is a user on more than one site with different balances in each
Forum: Plugins
In reply to: [Wallet for WooCommerce] Currency is ‘points’ being sent to payment gatewayalready had the code below on our functions.php file.
add_filter(‘wc_stripe_payment_intent_args’, function($args){ $args[‘currency’] = ‘USD’; return $args; }, 10);
Still not working. Stripe is receiving the payment intent with ‘points’ as currency.
- This reply was modified 2 years, 7 months ago by mikethome.
Forum: Plugins
In reply to: [Wallet for WooCommerce] Woowallet to woocommerce Tax communication errorbtw…we’ve updated TeraWallet to the latest version just this morning and continue to have an error. FYI this scenario appears to only occur when the order subtotal + shipping are below wallet balance and taxes push it over the top.
Scenarios:
- When subtotal + shipping is greater than wallet balance, the calculations are all correct. The wallet is fully utilized and the user is prompted to use a credit card for the balance
- When subtotal + shipping + taxes is less than wallet balance, the calculations are correct and the wallet covers the transaction
- When subtotal + shipping is just less than wallet balance AND taxes pushes over wallet balance. The wallet is charged just the subtotal + shipping. Taxes are added after and the user is prompted to pay an incorrect amount while points still remain in the wallet.
Forum: Plugins
In reply to: [Wallet for WooCommerce] Use Wallet Balance FirstI’ve posted a similar issue on another thread but it might apply here also. Does Woo-Wallet calculate cart total including taxes? I’m finding that taxes are not included when comparing cart total to wallet balance. Therefore only product and shipping is being deducted from wallet balance even if taxes push the cart total over the wallet balance.
Forum: Plugins
In reply to: [Wallet for WooCommerce] Partial Payment error – not including taxesHave tested and retested and am convinced that this plugin does not include taxes when determining total to be deducted from wallet. I feel like this is an order of operations issue. The order total is only including subtotal + shipping if this evaluates as a positive number then the subtotal amount is multiplied by -1 and added to the cart as a negative item.
Trying to work out the logic in my head since I don’t know when the plugin actually executes all of the calls in between woocommerce’s actions.
#1 – subtotal + shipping + tax < point balance
total is added to cart as negative number and subtracted from point balance
#2 – subtotal + shipping > point balance
full point balance is depleted and subtracted from total (including taxes)
taxes + remaining subtotal is multiplied by .03 and re-totaled
re-total is sent to payment gateway and charged to CC
#3 – subtotal + shipping + taxes > point balance
only subtotal + shipping is added to cart as negative number
only subtotal + shipping is subtracted from point balance
taxes + cc fee are calculated and sent to payment gateway
#3 is incorrect and we are desperately needing some help here. The entire wallet balance should be added as a negative number and depleted from the wallet.
Thanks in advance!
Forum: Plugins
In reply to: [Wallet for WooCommerce] Partial Payment error – not including taxesSorry about the bump, but am really in the need for some help here. Anyone else have similar issues?
I think we’ve found our own solution. It’s taking some custom code and we’ll probably have issues in the future when updates are released but we are very excited. Would be happy to share with you directly when we are done, if you are interested.
Forum: Plugins
In reply to: [Advanced Order Export For WooCommerce] Custom Total – sum of 3 fieldsThanks! Works great! Thank you for the speedy response!
Any suggestions on connecting this plugin to a charting plugin or thoughts on creating those features?
Forum: Plugins
In reply to: [Import and export users and customers] Plugin update – Import Export UsersThat appears to have worked. Thanks for your quick replies!
Forum: Plugins
In reply to: [WooCommerce] Multistore Product SyncBefore I can start really troubleshooting this, I noticed that I’m needing to update but unable to delete the bulk sync add-on. Any help on how to perform the delete before updating? Here is the message in the network plug-in admin page:
There is a new version of WooMultistore available. View version 4.7.4 details. Automatic update is unavailable for this plugin.
You need to delete the WooMultistore bulk sync addon if you are using it, bulk sync is integrated into the WooMultistore since version 4.5.0Forum: Plugins
In reply to: [WooCommerce] Multistore Product SyncTrying again manually syncing products across sites and it’s not working. Am I the only one with this issue?