diff --git a/classes/SpecificPriceRule.php b/classes/SpecificPriceRule.php index 99b9f674d..294d770fc 100755 --- a/classes/SpecificPriceRule.php +++ b/classes/SpecificPriceRule.php @@ -183,7 +183,7 @@ class SpecificPriceRuleCore extends ObjectModel if ($conditions_group) { - $where .= ' AND ('; + $where .= ' AND (('; foreach ($conditions_group as $id_condition_group => $condition_group) { $fields = array( @@ -235,7 +235,7 @@ class SpecificPriceRuleCore extends ObjectModel $where = rtrim($where, ' AND ').') OR ('; } - $where = rtrim($where, 'OR ('); + $where = rtrim($where, 'OR (').')'; } if ($products && count($products)) $where .= ' AND p.id_product IN ('.implode(', ', array_map('intval', $products)).')';