Hi folk,
I have a problem on the OpenCart discount feature.
The shop was configured with 2 currency. USD (Primary Currency) and NZD. And I also configured a 10% off discount coupon code for some customers.
Here is the problem: when they check-out in NZD. OpenCart was calculated the total amount correctly. But when the data passed to PayPal. The discount amount was wrong and the total amount was calculated incorrectly.
Is there any fix for this? Or is it a possible a bug?
I also attached some images to illustrated the problem.
Thanks!
I am experiencing the same issue.
Running 1.4.9.2
When you add items to cart, then checkout the totals are correct.
When you add a coupon, the discount is applied
when you confirm order and it flips you out to paypal, the items appear and the prices are there, but the disount is nowhere to be seen and the order total is as it was in opencart but without the discount applied.
opencart store is http://www.wozwaste.com/store
Running 1.4.9.2
When you add items to cart, then checkout the totals are correct.
When you add a coupon, the discount is applied
when you confirm order and it flips you out to paypal, the items appear and the prices are there, but the disount is nowhere to be seen and the order total is as it was in opencart but without the discount applied.
opencart store is http://www.wozwaste.com/store
Is there any fix or update on this issue? Because the problem still exist and affecting customers......
And PayPal support team already reply me it is a problem on the variable "discount_amount_cart", here is the extract from the email.
And PayPal support team already reply me it is a problem on the variable "discount_amount_cart", here is the extract from the email.
Anyone can help? And inputs are welcome! Thanks.The discount amount that displayed on the PayPal payment pages is passed to PayPal in variable "discount_amount_cart". You will need to contact your shopping cart provider if the amount passed to PayPal is incorrect. PayPal only process the amounts that are passed to it from the shopping cart.
Not sure if this helps in tracking this down, but I found something interesting on my cart. For testing I set up a $12 coupon on a $12 item and then went into paypal. It was fine in the cart and had my total as just the shipping charge but it did not take the discount off on the paypal screen.
Then I tested with more than 1 item in the cart and a higher priced item and the discount carried through correctly.
I understand that my situation would be weird in giving a full value discount, but maybe it can help you discover something.
I am on version 1.4.9.1
I am running US Dollars only
Then I tested with more than 1 item in the cart and a higher priced item and the discount carried through correctly.
I understand that my situation would be weird in giving a full value discount, but maybe it can help you discover something.
I am on version 1.4.9.1
I am running US Dollars only
Ok there are actually a lot of factors in play here.....
1. Paypal has a "limitation" noted by me here yesterday and confirmed by the paypal forum mod:
https://www.x.com/thread/47330
Basically it means that if you have a discount greater than the product total (subtotal), the discount just doesn't show up. This means if you have something like:
The discount won't work right in paypal since they don't consider the shipping or tax to be discounted fields and 10.00 is greater than the product subtotal of 6.00
It is not likely that paypal will fix this. TBH when using the _cart and upload options, they should just accept passthru values instead of ignoring them, but this is no surprise from paypal. So the only fix I see is that when the discount is greater than subtotal, I will have to make shipping and tax appear as line items, thus adding it to the paypal subtotal and fooling paypal into discounting properly
1. Paypal has a "limitation" noted by me here yesterday and confirmed by the paypal forum mod:
https://www.x.com/thread/47330
Basically it means that if you have a discount greater than the product total (subtotal), the discount just doesn't show up. This means if you have something like:
Code: Select all
Item 1 = 5.00
Item 2 = 1.00
Tax = 4.00
Shipping = 10.00
Discount = -10.00 <---- more than the $6.00 item total
Total = 10.00
It is not likely that paypal will fix this. TBH when using the _cart and upload options, they should just accept passthru values instead of ignoring them, but this is no surprise from paypal. So the only fix I see is that when the discount is greater than subtotal, I will have to make shipping and tax appear as line items, thus adding it to the paypal subtotal and fooling paypal into discounting properly
You can read more and get the new version here
http://forum.opencart.com/viewtopic.php ... 20#p111190
http://forum.opencart.com/viewtopic.php ... 20#p111190
Hi All,
I'm facing same issue and found the problem with code.
Actually existing code is using currency conversion twice on $total which is causing this issue
and
in /catalog/controller/payment/pp_standard.php
Fix for this issue:
Just replace
with
Thanks and Regards,
Mahesh Salaria
I'm facing same issue and found the problem with code.
Actually existing code is using currency conversion twice on $total which is causing this issue
Code: Select all
$total = $this->currency->format($order_info['total'] - $this->cart->getSubTotal(), $currency, false, false);
Code: Select all
$this->data['discount_amount_cart'] -= $this->currency->format($total, $currency, FALSE, FALSE);
Fix for this issue:
Just replace
Code: Select all
$this->data['discount_amount_cart'] -= $this->currency->format($total, $currency, FALSE, FALSE);
Code: Select all
$this->data['discount_amount_cart'] -= $total;
Mahesh Salaria
Who is online
Users browsing this forum: No registered users and 47 guests