WC_Coupon::set_usage_limit_per_user()publicWC 3.0.0

Set the amount of times this coupon can be used per user.

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

Хуков нет.

Возвращает

null. Ничего (null).

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

$WC_Coupon = new WC_Coupon();
$WC_Coupon->set_usage_limit_per_user( $usage_limit );
$usage_limit(int) (обязательный)
Usage limit.

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

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

Код WC_Coupon::set_usage_limit_per_user() WC 8.7.0

public function set_usage_limit_per_user( $usage_limit ) {
	$this->set_prop( 'usage_limit_per_user', absint( $usage_limit ) );
}