woocommerce_(order_type)_list_table_columns
Filters the list of columns.
Usage
add_filter( 'woocommerce_(order_type)_list_table_columns', 'wp_kama_woocommerce_order_type_list_table_columns_filter' ); /** * Function for `woocommerce_(order_type)_list_table_columns` filter-hook. * * @param array $columns List of sortable columns. * * @return array */ function wp_kama_woocommerce_order_type_list_table_columns_filter( $columns ){ // filter... return $columns; }
- $columns(array)
- List of sortable columns.
Changelog
Since 7.3.0 | Introduced. |
Where the hook is called
woocommerce_(order_type)_list_table_columns
woocommerce/src/Internal/Admin/Orders/ListTable.php 857-869
return apply_filters( 'woocommerce_' . $this->order_type . '_list_table_columns', array( 'cb' => '<input type="checkbox" />', 'order_number' => esc_html__( 'Order', 'woocommerce' ), 'order_date' => esc_html__( 'Date', 'woocommerce' ), 'order_status' => esc_html__( 'Status', 'woocommerce' ), 'billing_address' => esc_html__( 'Billing', 'woocommerce' ), 'shipping_address' => esc_html__( 'Ship to', 'woocommerce' ), 'order_total' => esc_html__( 'Total', 'woocommerce' ), 'wc_actions' => esc_html__( 'Actions', 'woocommerce' ), ) );