Last active
October 18, 2021 06:18
-
-
Save Musilda/d38e2f4f1d11f66764d065ba74695700 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'manage_shop_order_posts_columns', 'musilda_custom_order_column', 11 ); | |
function musilda_custom_order_column( $columns ) { | |
$expanded_columns = []; | |
foreach ( $columns as $key => $value ) { | |
$expanded_columns[$key] = $value; | |
if ( $key == 'name' ) { | |
$expanded_columns['order-weight'] = __( 'Weight', 'musilda' ); | |
} | |
} | |
return $expanded_columns; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment