Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Function checkQuoteItemQty :
- if (!$this->checkQty($summaryQty) || !$this->checkQty($qty)) {
- //$message = Mage::helper('cataloginventory')->__('The requested quantity for "%s" is not available.', $this->getProductName());
- $message = Mage::helper('cataloginventory')->__('The requested quantity for "%s" is not available (max:%s).', $this->getProductName(), ($this->getQty() * 1));
- $cat_id = $this->getProduct()->getCategoryIds();
- if($cat_id){
- $url = Mage::getModel('catalog/category')->load($cat_id[0])->getUrl();
- $message .= Mage::helper('cataloginventory')->__('You might be interested in <a href="%s">those products</a>.', $url);
- }
- $result->setHasError(true)
- ->setMessage($message)
- ->setQuoteMessage($message)
- ->setQuoteMessageIndex('qty');
- return $result;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement