Re: Edit Orders v4.0 Support Thread
@Dave224, thanks for the update. I've replicated the issue with Quantity Discounts v1.12.1 (the current version available), EO 4.3.1 and zc1.5.5f.
I'll continue looking for a solution to the combination (Quantity Discounts/EO) but based on the specialized tax-handling that's present in Quantity Discounts, I'm not particularly hopeful that I'll find one.
Re: Edit Orders v4.0 Support Thread
Thank you for your continued efforts to find a solution. I will also continue to look.
Also, I made a mistake in the quantity discount version I am using. I am using v1.12.1 (the current version), not 1.11 (which is what I was using with zc v1.5.1). Sorry for any confusion.
Re: Edit Orders v4.0 Support Thread
While trying to find the solution to the incorrect order total in Edit Orders, I found that function eo_update_database_order_totals in admin/includes/functions/extra_functions/edit_orders_functions.php calls function eoGetOrderTotalTax in admin/includes/classes/editOrders.php. For Quantity Discounts, MODULE_ORDER_TOTAL_QUANTITY_DISCOUNT_TAX_CLASS does not exist, so the routine returns zero. This value is subsequently subtracted from $order->info['tax'] and a little later from $order->info['total']. As a test to see if the lack of this ...TAX_CLASS was the source of my problem, I fudged the return from the routine with the tax on the quantity discount. Now when I reran my test case, the order total was correct, but the now the tax was too high by the tax on the discount. I am so confused now I must be missing the obvious. Any help would be gratefully appreciated. I really need to make this work for our store.
Re: Edit Orders v4.0 Support Thread
I could repro this issue with a Quantity Discount giving 5% off quantities of 5. Start with an order with quantity 4 of an item.
Sub-total: $400
Tax (7%): $28
Total: $428
Run EO and change quantity to 5.
The line items other than the total are correct.
Sub-total: $400
Quantity Discount: $25
Tax (7%): $33.25
Total: $506.50 // should be 508.25
Re: Edit Orders v4.0 Support Thread
Quote:
Originally Posted by
swguy
I could repro this issue with a Quantity Discount giving 5% off quantities of 5. Start with an order with quantity 4 of an item.
Sub-total: $400
Tax (7%): $28
Total: $428
Run EO and change quantity to 5.
The line items other than the total are correct.
Sub-total: $400
Quantity Discount: $25
Tax (7%): $33.25
Total: $506.50 // should be 508.25
Yep, that's pretty much what I did to replicate the issue. As mentioned above, I've not finding a way for EO to deal with the tax-calculation method that Quantity Discounts applies and there's no method defined to determine the amount of tax an order-total contributed (either via addition or subtraction) to the order.
Whether or not I ticked the "reset totals" box, EO's results were the same.
Re: Edit Orders v4.0 Support Thread
Does EO work with a built in module like Group Pricing? If so, what's different?
Re: Edit Orders v4.0 Support Thread
Quote:
Originally Posted by
swguy
Does EO work with a built in module like Group Pricing? If so, what's different?
Yes, it does. The difference is that Group Pricing makes changes to the products' prices and the base tax processing does its thing. For Quantity Discounts, the products' prices are left as-is and the deduction (both in product-cost and tax) is calculated after-the-fact.
Re: Edit Orders v4.0 Support Thread
One thing that's different is that group discount has a tax_class, MODULE_ORDER_TOTAL_GROUP_PRICING_TAX_CLASS, while quantity discount does not. EO logic appears to return 0 for a quantity discount, instead of the tax on the quantity discount of the unedited order (I think). See my last post in this thread.
Re: Edit Orders v4.0 Support Thread
Quote:
Originally Posted by
lat9
Yes, it does. The difference is that Group Pricing makes changes to the products' prices and the base tax processing does its thing. For Quantity Discounts, the products' prices are left as-is and the deduction (both in product-cost and tax) is calculated after-the-fact.
Are you thinking about something else maybe? The built-in Group Pricing module is an order total module just like the Quantity Discounts order total module. It doesn't change prices. It gives you a single line item discount.
Re: Edit Orders v4.0 Support Thread
Quote:
Originally Posted by
Dave224
One thing that's different is that group discount has a tax_class, MODULE_ORDER_TOTAL_GROUP_PRICING_TAX_CLASS, while quantity discount does not.
Dave, that setting only applies to Credit Note, which is not a supported setting in my mods.