Change order of generated documents

[ad_1]

Hi @andrewsumner,

Yes, it is. You can reverse the orders sort, when using the PDF Bulk actions, with this code snippet:

add_filter( 'wpo_wcpdf_bulk_document_sort_order', function() { return 'DESC'; } );

Be aware that if the orders selected does not have a document yet, and the document creation is activated for these orders, the document numbering will be reversed too.

For instance, let’s say that you have selected the orders #100, #101, and #102, your next invoice number will be 1, and they do not have a PDF invoice yet. When you try to generate the PDF invoice in bulk for these orders, this will be the invoice number given for each order:

  • Order #100 » Invoice 3
  • Order #101 » Invoice 2
  • Order #102 » Invoice 1

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer