Automattic\WooCommerce\StoreApi\Schemas\V1

ProductSchema::get_tax_display_mode()protectedWC 1.0

WooCommerce can return prices including or excluding tax; choose the correct method based on tax display mode.

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

Хуков нет.

Возвращает

Строку. Valid tax display mode.

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

// protected - в коде основоного (родительского) или дочернего класса
$result = $this->get_tax_display_mode( $tax_display_mode );
$tax_display_mode(строка)
Provided tax display mode.
По умолчанию: ''

Код ProductSchema::get_tax_display_mode() WC 8.7.0

protected function get_tax_display_mode( $tax_display_mode = '' ) {
	return in_array( $tax_display_mode, [ 'incl', 'excl' ], true ) ? $tax_display_mode : get_option( 'woocommerce_tax_display_shop' );
}