WC_Order_Item_Shipping::get_tax_status()publicWC 1.0

Get tax status.

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

Хуков нет.

Возвращает

Строку.

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

$WC_Order_Item_Shipping = new WC_Order_Item_Shipping();
$WC_Order_Item_Shipping->get_tax_status( $context );
$context(строка)
What the value is for. Valid values are 'view' and 'edit'.
По умолчанию: 'view'

Код WC_Order_Item_Shipping::get_tax_status() WC 9.8.2

public function get_tax_status( $context = 'view' ) {
	$shipping_method = WC_Shipping_Zones::get_shipping_method( $this->get_instance_id() );
	return $shipping_method ? $shipping_method->get_option( 'tax_status' ) : ProductTaxStatus::TAXABLE;
}