Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Paypal Payments Pro Causing Random Incomplete Orders Rate Topic   - - - - -

 
  • Triplets
  • Senior Member
  • Members
  • Join Date: 23-Sep 08
  • 1176 posts

Posted 08 November 2016 - 12:14 AM #1

Using Paypal Payments Pro, we are randomly getting Incomplete Orders that state:

 

The transaction was refused as a result of a duplicate invoice ID supplied. Attempt with a new invoice ID

 

Any suggestions on what the cause might be and the fix?

 

David

 

CS-Cart 4.3.10

 



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 18680 posts

Posted 08 November 2016 - 07:40 AM #2

app/addons/paypal/payments/paypal_pro.php

 

Try to replace:

$paypal_order_id = $processor_data['processor_params']['order_prefix'] . (($order_info['repaid']) ? ($order_id . '_' . $order_info['repaid']) : $order_id);

with:

$paypal_order_id = $processor_data['processor_params']['order_prefix'] . (($order_info['repaid']) ? ($order_id . '_' . $order_info['repaid']) : $order_id) . '_' . TIME;

GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • Triplets
  • Senior Member
  • Members
  • Join Date: 23-Sep 08
  • 1176 posts

Posted 08 November 2016 - 09:54 PM #3

I made your suggested mod, I believe now we are getting:

 

(10412) Duplicate invoice: Payment has already been made for this InvoiceID.



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 18680 posts

Posted 09 November 2016 - 08:34 AM #4

I made your suggested mod, I believe now we are getting:

 

(10412) Duplicate invoice: Payment has already been made for this InvoiceID.

 

Please contact support team. The mentioned code creates unique Invoice ID for each transaction.


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • mokeshop
  • Senior Member
  • Members
  • Join Date: 27-Jul 12
  • 994 posts

Posted 29 October 2018 - 05:19 PM #5

Please contact support team. The mentioned code creates unique Invoice ID for each transaction.

 

hello, can this be solved in paypal express ?



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 18680 posts

Posted 30 October 2018 - 05:36 AM #6

app/addons/paypal/paypal_express.functions.php

 

Try to replace

$pp_order_id = $processor_data['processor_params']['order_prefix'] . (($order_info['repaid']) ? ($order_info['order_id'] . '_' . $order_info['repaid']) : $order_info['order_id']);

with

$pp_order_id = $processor_data['processor_params']['order_prefix'] . (($order_info['repaid']) ? ($order_info['order_id'] . '_' . $order_info['repaid']) : $order_info['order_id']) ) . '_' . TIME;

(!) Not tested


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • mokeshop
  • Senior Member
  • Members
  • Join Date: 27-Jul 12
  • 994 posts

Posted 01 November 2018 - 09:17 PM #7

the solutions to this problem is simple : the solution is simple... the prefix on paypal setting has to be added..its also in cs cart docs

 

i have also overseen this part where it says to add a prefix to paypal so that the invoices not match



 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 18680 posts

Posted 02 November 2018 - 05:22 AM #8

Prefix will be the same for all orders. Our solution makes order_id for each transaction unique


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.