View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0000368 | OXID eShop (all versions) | 1.02. Price calculations (discounts, coupons, additional costs etc.) | public | 2008-11-01 18:24 | 2012-12-07 15:19 |
Reporter | sven_kliebenstein | Assigned To | |||
Priority | high | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Fixed in Version | 4.0.0.0 revision 14260 | ||||
Summary | 0000368: Vat rates using decimals are not displyed correctly | ||||
Description | The following bug was reported in the forum under: http://www.oxid-esales.com/de/resources/forum/installation-and-configuration/internationalization-or-lack-it Here's an excerpt of the problem: I have set the VAT to 21.5, it is correctly calculated and displayed in the shopping cart on the actual item line, but at the bottom it only comes back with "plus tax21% Amount", which looks like a formating issues as there is no space between tax and the 21 as well. The method $oxcmp_basket->getProductVats() returns an array with vat rates used as the key. The problem is located in the class core/oxpricelist, the key assignment is not correct: $aVatValues[$oPrice->getVat()] += $oPrice->getVATValue(); => should be done by using a new var and then assigning the var as a string, e.g.: $fVatKey = $oPrice->getVat(); $aVatValues["$fVatKey"] += $oPrice->getVATValue(); | ||||
Tags | VAT | ||||
Theme | |||||
Browser | All | ||||
PHP Version | 5.2.6 | ||||
Database Version | 5.0.33 | ||||
|
"... are not displyed correctly ..." unfortunately is only half the truth: The value after the comma is cut away at least at checkout step 4 and the wrong value is taken for calculation. |
|
set severity to 'major' and proirity to 'high' as this issue is appropriate to avoid international spreading of the shop. |
|
formatting problem: Concerning http://de.wikipedia.org/wiki/Umsatzsteuer I found 2 characters after comma max (e.g. IRL, luxury goods at 36,75 %). IMHO in a first step it shall be done this way (19,00%), who wants to change can do it in smarty. Smarter way would be to have it configurable in admin backend. |
|
imo as a general rule, we just can: 1) take decimal separator from active currency and 2) drop all 0 from the end when formating VAT So VAT 18% will always look 18%. 21.5% will be 21,5% when price is 13,45 EUR and 21.5% when price is 8.00 USD in order not to confuse (but never 21.50% or 18.0%) |
|
Tomas' solution is the best. I choose that. |
|
fixed according to comments |