How come my VM is showing the discount the costumer can save as a negative amount like "you save -400,00" instead of "you save 400,00"?
Let me rephrase the question then - how do you fix it in the VM default template?
You need to do a template override for the prices
So it's normal to type it "you save -400,00"?
Yep that does sound odd!
that is standard - it changed around 2.0.20 something from a positive to a negative value - I know cos it broke a script we had to update a 3rd party DB..
I wrote a post here somewhere about the way to re-display it but buggered if I can find it - (is it just me or is this forum search bollocks? I rarely find anything I'm looking for.. hmmmm)
is this in the cart with coupon or a discount on a product page?
It's on the product page like this
Old Price 1000,-
New Price 600,-
You save -400,-
That is for me looking strange.
there is no text "you save" in Vm - so you must be using a third party template
normally it would be
Old Price 1000,-
New Price 600,-
Discount -400,-
but just find the generated figure and php abs it...
http://www.w3schools.com/php/func_math_abs.asp
something like
echo abs($this->currency->createPriceDiv ('discountAmount', 'COM_VIRTUEMART_PRODUCT_DISCOUNT_AMOUNT', $this->product->prices));
or what ever is rendering the discount
True it's not "you save" it's show and it's done in the language fil "en-GB.com_virtuemart.ini" - COM_VIRTUEMART_CART_SUBTOTAL_DISCOUNT_AMOUNT="Discount"
"You save" is my version of it :)
But somewhere in the programmering there must be a place where it's set to show negativ discount if used and I want the alternativ to change it to a positiv nummer but can't find that place ;D
it is buried in the helpers/calculationh.php but if you start messing in there your nuts .. ;)
just abs() it in the template
Sure I will do it the easy way - just need to learn and find that.
But thanks for the inputs - great to get enlightened ;)