WC_Product::get_min_purchase_quantity
Get min quantity which can be purchased at once.
Метод класса: WC_Product{}
Хуки из метода
Возвращает
int|float.
Использование
$WC_Product = new WC_Product(); $WC_Product->get_min_purchase_quantity();
Список изменений
| С версии 3.0.0 | Введена. |
Код WC_Product::get_min_purchase_quantity() WC Product::get min purchase quantity WC 10.5.0
public function get_min_purchase_quantity() {
/**
* Filters the minimum quantity which can be purchased at once.
*
* @since 10.1.0
* @param int|float $quantity The minimum quantity.
* @param \WC_Product $this The product object.
* @return int|float The minimum quantity.
*/
return wc_stock_amount( apply_filters( 'woocommerce_quantity_input_min', 1, $this ) );
}