WC_Admin_List_Table_Products::__construct │ public │ WC 1.0

Constructor.

Метод класса: WC_Admin_List_Table_Products{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

$WC_Admin_List_Table_Products = new WC_Admin_List_Table_Products();
$WC_Admin_List_Table_Products->__construct();

Код WC_Admin_List_Table_Products::__construct() WC 11.1.2

public function __construct() {
	parent::__construct();
	add_filter( 'disable_months_dropdown', '__return_true' );
	add_filter( 'query_vars', array( $this, 'add_custom_query_var' ) );
	add_filter( 'views_edit-product', array( $this, 'product_views' ) );
	add_filter( 'get_search_query', array( $this, 'search_label' ) );
	add_filter( 'posts_clauses', array( $this, 'posts_clauses' ), 10, 2 );

	// Use hooks to prime various caches and improve products page performance.
	add_action( 'load-edit.php', array( $this, 'prime_status_counts_cache' ) );
	add_filter( 'the_posts', array( $this, 'prime_thumbnail_caches' ), 10, 2 );

	$cogs_controller              = wc_get_container()->get( CostOfGoodsSoldController::class );
	$this->cogs_is_enabled        = $cogs_controller->feature_is_enabled();
	$this->use_cogs_lookup_column = $this->cogs_is_enabled && $cogs_controller->product_meta_lookup_table_cogs_value_columns_exist();
}