// Change sentence "Allow seperated package"

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@10718 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
mDeflotte
2011-11-28 16:47:50 +00:00
parent e474dc01b5
commit 7577e5ff0f
2 changed files with 17 additions and 1 deletions
+14
View File
@@ -2520,5 +2520,19 @@ class CartCore extends ObjectModel
return false;
}
/**
* Return false is some product from the cart are out of stock
*/
public function isAllProductsInStock()
{
foreach ($this->getProducts() as $product)
{
elog($product);
if (isset($product['out_of_stock']) && (int)$product['out_of_stock'])
return false;
}
return true;
}
}