need a quick help with an order total module
madmac <[email protected]>
| Newsgroups | gmane.comp.web.oscommerce.devel |
|---|---|
| Message-ID | <0b8f0dae82fac008b7660c08c7025f87@osCommerce-Forums> |
This message was sent from: Development http://forums.oscommerce.com/viewtopic.php?p=162073#162073 ---------------------------------------------------------------- I realized today with my site wide qty discounts, that tax is not being shown correct... it is being calculated into the total correctly, but not being shown... here is an example: Sub-Total: $659.00 Quantity Discount (10%): -$65.90 UPS Ground (Best Way): $7.00 VA TAX 4.5%: $29.65 Total: $626.78 the total of $626.78 is correct. but the tax shown is not ($29.65). it is the tax on the old subtotal... the module is set up to re-calculate tax on the new subttotal (659 - 65.90). but the total is correct: 659.00 - 65.90 = 593.10 x (4.5%) = 26.6895 593.10 + 7 + 26.6895 = [b]$626.7895[/b] I thought this would do it: $order->info['tax'] = $order->info['tax'] - $tod_amount; but its not ($tod_amount is the discount applied to the tax; which is the difference between the tax on the old subtotal and the new one)... how can I subtract the tax discount amount from the current tax to get it to show the new tax amount?