[-] MO : mailalert : #PSCFV-3763 : Fix error when i delete an mail alert

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@17030 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
lLefevre
2012-08-27 16:08:26 +00:00
parent 88ed4999ba
commit 8b761fa766
3 changed files with 11 additions and 7 deletions
+1 -2
View File
@@ -75,8 +75,7 @@ class MailAlert extends ObjectModel
{
$sql = '
DELETE FROM `'._DB_PREFIX_.self::$definition['table'].'`
WHERE '.(($id_customer > 0) ? '(`customer_email` = \''.pSQL($customer_email).'\'
OR `id_customer` = '.(int)$id_customer.')' :
WHERE '.(($id_customer > 0) ? '(`customer_email` = \''.pSQL($customer_email).'\' OR `id_customer` = '.(int)$id_customer.')' :
'`customer_email` = \''.pSQL($customer_email).'\'').
' AND `id_product` = '.(int)$id_product.'
AND `id_product_attribute` = '.(int)$id_product_attribute;