Automattic\WooCommerce\Internal\Admin\Orders

ListTable::setup()publicWC 1.0

Performs setup work required before rendering the table.

Method of the class: ListTable{}

No Hooks.

Return

null. Nothing.

Usage

$ListTable = new ListTable();
$ListTable->setup(): void;

ListTable::setup() code WC 7.1.1

public function setup(): void {
	add_action( 'admin_notices', array( $this, 'bulk_action_notices' ) );
	add_filter( 'manage_woocommerce_page_wc-orders_columns', array( $this, 'get_columns' ), 0 );
	add_filter( 'set_screen_option_edit_orders_per_page', array( $this, 'set_items_per_page' ), 10, 3 );
	add_filter( 'default_hidden_columns', array( $this, 'default_hidden_columns' ), 10, 2 );
	add_action( 'admin_footer', array( $this, 'enqueue_scripts' ) );

	$this->items_per_page();
	set_screen_options();
	add_action( 'manage_' . wc_get_page_screen_id( 'shop-order' ) . '_custom_column', array( $this, 'render_column' ), 10, 2 );
}