Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save webdados/7b6bf23a075223f1b2748fa008c4ca04 to your computer and use it in GitHub Desktop.

Select an option

Save webdados/7b6bf23a075223f1b2748fa008c4ca04 to your computer and use it in GitHub Desktop.
Add custom order status to the possible automatic issuing status on Invoicing with InvoiceXpress for WooCommerce Pro
<?php
add_filter( 'invoicexpress_woocommerce_automatic_invoice_possible_status', function( $possible_status ) {
$new_possible_status = array();
foreach ( $possible_status as $status ) {
if ( $status == 'wc-completed' ) {
// Add Picking before Completed
$new_possible_status[] = 'wc-picking';
}
$new_possible_status[] = $status;
}
return $new_possible_status;
} );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment