Round Number
Permalink Browser Info Environment
Hi,
I'm using the giftcard plug-in for my e-shop but I've a question. When I use a discount with percent. I've got a discount like 27.36.- or 14.19.-, how or in wich file and line can I round those number to have something like 27.35.- or 14.20.- ?
Thank your for your answer and sorry for my terrible english.
I'm using the giftcard plug-in for my e-shop but I've a question. When I use a discount with percent. I've got a discount like 27.36.- or 14.19.-, how or in wich file and line can I round those number to have something like 27.35.- or 14.20.- ?
Thank your for your answer and sorry for my terrible english.
Type: | Discussion |
---|---|
Status: | New |
And thanks for the message. Your English is perfect as I can completely understand you (which is the most important thing).
The file you need to override is:
/packages/core_commerce_gift_cards/models/core_commerce/payment/coupon/transaction/queue.php
So copy that file into your root-level directories, so it will be in:
/models/core_commerce/payment/coupon/transaction/queue.php
Then in that file you can see this comment:
// Check how much to be paid from this coupon
And under that you see the if-clause that checks whether it's a percentage gift card.
So the line you need to change in that file is:
Hopefully this answers your question!
Best,
Antti / Mainio