woocommerce_product_reviews_list_table_item_types хук-фильтрWC 7.0.0

Sets the possible options used in the Product Reviews List Table's filter-by-review-type selector.

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

add_filter( 'woocommerce_product_reviews_list_table_item_types', 'wp_kama_woocommerce_product_reviews_list_table_item_types_filter' );

/**
 * Function for `woocommerce_product_reviews_list_table_item_types` filter-hook.
 * 
 * @param array $array Map of possible review types.
 *
 * @return array
 */
function wp_kama_woocommerce_product_reviews_list_table_item_types_filter( $array ){

	// filter...
	return $array;
}
$array(массив)
Map of possible review types.

Список изменений

С версии 7.0.0 Введена.

Где вызывается хук

ReviewsListTable::review_type_dropdown()
woocommerce_product_reviews_list_table_item_types
woocommerce/src/Internal/Admin/ProductReviews/ReviewsListTable.php 1346-1353
$item_types = apply_filters(
	'woocommerce_product_reviews_list_table_item_types',
	array(
		'all'     => __( 'All types', 'woocommerce' ),
		'comment' => __( 'Replies', 'woocommerce' ),
		'review'  => __( 'Reviews', 'woocommerce' ),
	)
);

Где используется хук в WooCommerce

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