WC_Product_Variation::get_purchase_note()publicWC 3.0.0

Get purchase note.

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

Хуки из метода

Возвращает

Строку.

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

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

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

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

Код WC_Product_Variation::get_purchase_note() WC 8.7.0

public function get_purchase_note( $context = 'view' ) {
	$value = $this->get_prop( 'purchase_note', $context );

	// Inherit value from parent.
	if ( 'view' === $context && empty( $value ) ) {
		$value = apply_filters( $this->get_hook_prefix() . 'purchase_note', $this->parent_data['purchase_note'], $this );
	}
	return $value;
}