[*] Classes : improve performances of "Feature detachable" feature

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@8754 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
aFolletete
2011-09-24 15:03:21 +00:00
parent cfca41b012
commit 78f6a4e20a
18 changed files with 334 additions and 149 deletions
+2 -2
View File
@@ -444,12 +444,12 @@ class CartCore extends ObjectModel
return array();
foreach ($result AS $row)
{
if (isset($row['ecotax_attr']) AND $row['ecotax_attr'] > 0)
if (isset($row['ecotax_attr']) && $row['ecotax_attr'] > 0)
$row['ecotax'] = (float)($row['ecotax_attr']);
$row['stock_quantity'] = (int)($row['quantity']);
// for compatibility with 1.2 themes
$row['quantity'] = (int)($row['cart_quantity']);
if (isset($row['id_product_attribute']) AND (int)$row['id_product_attribute'])
if (isset($row['id_product_attribute']) && (int)$row['id_product_attribute'] && isset($row['weight_attribute']))
$row['weight'] = $row['weight_attribute'];
if ($this->_taxCalculationMethod == PS_TAX_EXC)
{