woocommerce_product_visibility_options хук-фильтрWC 3.0.0

Get product visibility options.

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

add_filter( 'woocommerce_product_visibility_options', 'wp_kama_woocommerce_product_visibility_options_filter' );

/**
 * Function for `woocommerce_product_visibility_options` filter-hook.
 * 
 * @param  $array 
 *
 * @return 
 */
function wp_kama_woocommerce_product_visibility_options_filter( $array ){

	// filter...
	return $array;
}
$array
-

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

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

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

wc_get_product_visibility_options()
woocommerce_product_visibility_options
woocommerce/includes/wc-product-functions.php 865-873
return apply_filters(
	'woocommerce_product_visibility_options',
	array(
		'visible' => __( 'Shop and search results', 'woocommerce' ),
		'catalog' => __( 'Shop only', 'woocommerce' ),
		'search'  => __( 'Search results only', 'woocommerce' ),
		'hidden'  => __( 'Hidden', 'woocommerce' ),
	)
);
woocommerce/includes/admin/views/html-quick-edit-product.php 142-150
$options = apply_filters(
	'woocommerce_product_visibility_options',
	array(
		'visible' => __( 'Catalog & search', 'woocommerce' ),
		'catalog' => __( 'Catalog', 'woocommerce' ),
		'search'  => __( 'Search', 'woocommerce' ),
		'hidden'  => __( 'Hidden', 'woocommerce' ),
	)
);

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

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