Jump to content

Paypal 2.4 Module not showing product name, unit price, shipping & VAT (PS v1.3)


Recommended Posts

Hi,

I'm using Prestashop 1.3.2.3.

I had a bug where i was getting "Warning: Paid £9.98 instead of £9.99" when payments were made by PayPal.

The PayPal module i was using was version 1.7.1, i upgraded it to the new 2.4 version.

This upgrade seems to have solved the incorrect rounding of prices but now has another fault.

Before when a customer got redirected to PayPal for payment they had a drop down box at the top of the page which showed them a price breakdown of products, shipping, vat etc and a description for the product.

This new module does not include this information, only a total price???

This is also the case on MY PayPal payment received emails, it only shows total price not detailed information for each product and shipping?

Does anybody else have this problem when using the new 2.4 PayPal module with PS 1.3.2.3?

Any help on this matter would be gratefully appreciated!

Regards

Link to comment
Share on other sites

I had a bug where i was getting “Warning: Paid £9.98 instead of £9.99” when payments were made by PayPal.

this issue is caused by the price calculation and rounding up/down when submit multiple items.
I heard that the latest version of Paypal 2.4 has addressed this issue, fix the this issue.

But I am not sure it is fixed just by passing the total amount.
You can download the latest version of Paypal 2.4 and try it out.
Link to comment
Share on other sites

I have already installed the 2.4 as stated in my original post, this is how i have come across this error.

It seems that you are correct that the 2.4 update has corrected the rounding problems, they have achieved this by not sending individual product information and prices but just sending the total cost of invoice.

I did manage to get the product information send to paypal by using some of tomerg3 code fix but it was originally designed for PS 1.4.

The code i added to paypal.php and paypalpayment.php was:

$products = $cart->getProducts();
           $amt = 0;
           for ($i = 0 ; $i < sizeof($products) ; $i++)
           {
               $request .= '&L;_NAME'.$i.'='.substr(urlencode($products[$i]['name'].(isset($products[$i]['attributes'])?' - '.$products[$i]['attributes']:'') ),0,127);
               $request .= '&L;_AMT'.$i.'='.urlencode(number_format($products[$i]['price'],2));
               $request .= '&L;_QTY'.$i.'='.urlencode($products[$i]['cart_quantity']);
               $amt += number_format($products[$i]['price'],2);
           }
           $shipping = number_format($cart->getOrderShippingCost($cart->id_carrier,false),2);
           $request .= '&ITEMAMT;='.urlencode($amt);
           $request .= '&SHIPPINGAMT;='.urlencode($shipping);
           $request .= '&TAXAMT;='.urlencode((float)max($total-$amt-$shipping,0));



This did solve the product info but then the rounding error returned?

I guess the current set up of no product information on paypal payment page a receipt will have to do.

Cheers


I had a bug where i was getting “Warning: Paid £9.98 instead of £9.99” when payments were made by PayPal.

this issue is caused by the price calculation and rounding up/down when submit multiple items.
I heard that the latest version of Paypal 2.4 has addressed this issue, fix the this issue.

But I am not sure it is fixed just by passing the total amount.
You can download the latest version of Paypal 2.4 and try it out.
Link to comment
Share on other sites

×
×
  • Create New...