Jump to content

PayPal Calculation Error


Recommended Posts

Hi guys,

 

I think I may have found a little bug. It seems that when I set the carrier to use a tax rule that it calculates it twice once you try to checkout with paypal. 

 

First it shows you the price tax included in the carrier select section. Then once you get to paypal checkout it uses the Tax included value it computed before and uses it as the TAX EXCL. value on the paypal checkout page. It then goes on to calculate the tax on the total which has the tax included in the shipping already. It basically double taxes the shipping value.

 

Has anyone else seen this?

 

Thanks

 

Jason

Link to comment
Share on other sites

OK after some testing I have found a solution that seems to work, I noticed that the blockcart also showed the shipping cost+tax then the tax amount also included the shipping tax, the total was correct but still seemed confusing so first I wanted to fix that.

(not the cart summery)

 

Here is the solution I found:   change $usetax to $WithoutTaxes

 

modules/blockcat.php at line 68

$base_shipping = $params['cart']->getOrderTotal($useTax, Cart::ONLY_SHIPPING);

to this:

$base_shipping = $params['cart']->getOrderTotal($WithoutTaxes, Cart::ONLY_SHIPPING);

 

 

Now to change the Paypal shipping: change true to false

 

modules/paypalusa/views/templates/hook/standard.tpl at line 48

change this:

{assign var="paypal_usa_total_shipping" value=$cart->getOrderTotal(true, Cart::ONLY_SHIPPING)}

to this:

{assign var="paypal_usa_total_shipping" value=$cart->getOrderTotal(false, Cart::ONLY_SHIPPING)}

 

 

I just finished testing and seems to work please let me know if this works for you and I will report to Prestashop.

Link to comment
Share on other sites

×
×
  • Create New...