WC_Abstract_Order::get_cogs_total_value()publicWC 1.0

Get the value of the Cost of Goods Sold for this order.

WARNING! If the Cost of Goods Sold feature is disabled this method will always return zero.

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

Хуков нет.

Возвращает

float. The current value for this order.

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

$WC_Abstract_Order = new WC_Abstract_Order();
$WC_Abstract_Order->get_cogs_total_value(): float;

Код WC_Abstract_Order::get_cogs_total_value() WC 9.7.1

public function get_cogs_total_value(): float {
	return (float) ( $this->has_cogs() && $this->cogs_is_enabled( __METHOD__ ) ? $this->get_prop( 'cogs_total_value' ) : 0 );
}