• Hi,

    I noticed that the invoice number skipped for one of the orders and upon further investigation by looking at the _wcpdf_invoice_number field in the database, I noticed that two invoice numbers were set for an order but only one invoice was generated. Would you know why this would’ve happened?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Contributor Darren Peyou

    (@dpeyou)

    Hello @nikhilt88,

    For the number that was not skipped,how did you generate that invoice? Manually? Reference: When are Invoice Numbers assigned?

    Invoice numbers are assigned at the moment a PDF invoice is created, either manually (by pressing the buttons or executing the bulk action), or automatically (by means of email attachment). This depends completely on the plugin settings. If you attach the invoice to the Admin New Order email, this means the invoice (and invoice number!) will be created immediately after the order is placed – for most setups, this is not recommended! The ‘safest’ way is to attach the PDF invoice only to the Customer Completed Order email and the Customer Invoice email. This will make sure an invoice number will not be created automatically before the order is completed. Additionally, if you want to prevent invoices of ever being created for specific order statuses, you can add these to the “disable for:” setting.`

    Plugin Contributor Darren Peyou

    (@dpeyou)

    @nikhilt88,

    On 2nd revision, is there any chance you are using PayPal as your payment gateway? We know of a long-standing issue in WooCommerce. Duplication happens because PayPal sends two notifications to WooCommerce, one for PDT and another for IPN. They serve the exact same purpose so you only need one of the two:

    – EITHER disable PDT: clear the “PayPal identity token” in the PayPal gateway settings in WooCommerce,
    – OR To disable IPN: go to your PayPal merchant backend (where you can also disable PDT).

    Thread Starter nikhilt88

    (@nikhilt88)

    Hi Darren,

    Sorry for the late reply but I thought I had already posted it 2 days back.

    We don’t use PayPal but we think a similar bug might’ve occurred with the Payment Gateway we’ve been using. When we checked the logs we found they sent two successful transaction messages at almost the same second which might’ve caused two invoice numbers to be generated.

    We are in touch with our payment gateway to find out what really happened. Will update the thread once we hear back from them.
    Thanks.

    Plugin Contributor Ewout

    (@pomegranate)

    Thanks for reporting back! Could you tell us which payment gateway/provider you are using?

    Thread Starter nikhilt88

    (@nikhilt88)

    We use Razorpay as our payment gateway. We’ve been using them for quite some time and this issue has never happened before so it must’ve been just a bug.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Invoice number skipped’ is closed to new replies.