/** * Check - can change item's amount or not * * @return boolean */ public function canChangeAmount() { $product = $this->getProduct(); if ($product && $product->getInventory()->getEnabled() && $this->getVariant() && !$this->getVariant()->getDefaultAmount()) { $result = 0 < $this->getVariant()->getAmount(); } else { $result = parent::canChangeAmount(); } return $result; }
/** * {@inheritDoc} */ public function canChangeAmount() { $this->__initializer__ && $this->__initializer__->__invoke($this, 'canChangeAmount', array()); return parent::canChangeAmount(); }