• Resolved westonworkshops

    (@westonworkshops)


    Hi,

    I just noticed that our e-shop has stopped displaying the invoice numbers for many of the invoices that have been issued this year. I looked through the data in the ‘Numbers’ tab in the ‘Advanced’ settings and I can see that the sequential invoice numbers used so far are all correctly linked to the right orders.

    However, those that display an invoice number in the ‘Orders’ list show the word ‘Invoice’ in the ‘Type’ column. Those that do not show an invoice number have only a ‘-‘ in the ‘Type’ column. We only use invoices – packing slips are not enabled.

    Any idea what might have caused this and how to fix it?

    FYI: I looked through the database tables to try to see where the ‘Type’ field is mapped from, but I could not identify any field.

    Screenshots of the ‘Orders’ list and ‘Numbers’ data are attached.

    I look forward to hearing from you.

    Kind regards,

    Tim

    Note: WordPress, Woocommerce and your plugin are all on the most current versions.

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Contributor dwpriv

    (@dwpriv)

    The “Type” column doesn’t seem to be related to our plugin. Our plugin has the option to display a document number column and a document date column, as well as an “Actions” column to create documents on the Order page. Is this column added via code snippet or a third party plugin?

    Thread Starter westonworkshops

    (@westonworkshops)

    Interesting…

    It is not a code snippet, but it might be from another plugin…I’ll have a dig around in the database.

    The other thing I can say is that when I look at an order that has had an invoice issued (but which is not displaying) the ‘PDF Invoice’ button does not have a green tick on it. e.g. for order 28779 shown in the screenshots above. Which piece of data tells your plugin to show that an invoice has been issued or not?

    I will update if I find more information.

    Tim

    Thread Starter westonworkshops

    (@westonworkshops)

    Some more information…

    The table wp_wc_orders_meta gets _wcpdf entries added to it.

    An order that correctly shows an invoice as having been issued has the following meta data entries:

    An order that does not show an invoice as having been issued has only the 5 two following meta data entries:

    The ‘Type’ data (bold below) is contained in the _wcpdf_invoice_number_data entry e.g.:

    a:7:{s:6:”number”;i:614;s:16:”formatted_number”;s:9:”202400614″;s:6:”prefix”;s:14:”[invoice_year]”;s:6:”suffix”;s:0:””;s:13:”document_type”;s:7:”invoice”;s:8:”order_id”;i:29407;s:7:”padding”;s:1:”5″;}

    So the issue seems to be that 5 meta data entries have been lost from the wp_wc_orders_meta table. How has that happened and is it possible to regenerate that data?

    Tim

    Plugin Contributor dwpriv

    (@dwpriv)

    I’m not sure how the invoices were wiped, honestly. It’s possible they could have been accidentally deleted with the Number Tools options. However, you can recreate them by either clicking the “invoice” button on the Order Edit page, or bulk creating them on the Orders page using the “Bulk actions” drop down menu.

    Thread Starter westonworkshops

    (@westonworkshops)

    OK…will the existing assigned invoice number be retained?

    Plugin Contributor dwpriv

    (@dwpriv)

    The numbers that they had before? Unfortunately, no. This is because the data used for that has been deleted somehow. They will be numbered sequentially starting from the “Next invoice number” under PDF Invoices > Documents > Invoice. The new numbers will also take any number formatting available such as padding, prefix, etc.

    Thread Starter westonworkshops

    (@westonworkshops)

    Thanks for confirming that it is not possible. I think we can work around this as all the PDF invoices get exported for sending to our book-keeper, and we have all the ones where data has been lost.

    Tim

    Plugin Contributor dwpriv

    (@dwpriv)

    No problem, Tim. We will mark this topic as resolved. Feel free to create another thread if there’s something else you need help with.

Viewing 8 replies - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.