Skip to content

Instantly share code, notes, and snippets.

@renatofrota
Forked from fernandoacosta/functions.php
Created July 11, 2020 01:27
Show Gist options
  • Save renatofrota/c11bdf15f404f41a3345705c70085e46 to your computer and use it in GitHub Desktop.
Save renatofrota/c11bdf15f404f41a3345705c70085e46 to your computer and use it in GitHub Desktop.
Adicionar campo personalizado na busca de pedidos WooCommerce
<?php
/**
* @woo_custom_search
* @param string $search_fields
*/
function woo_custom_search( $search_fields ) {
$search_fields[] = 'Método de pagamento';
return $search_fields;
}
add_filter( 'woocommerce_shop_order_search_fields', 'woo_custom_search' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment