// Improve collections : where() method reworked (prototype changed) + validation of fields
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@11383 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -151,10 +151,10 @@ class ProductSupplierCore extends ObjectModel
|
||||
public static function getSupplierCollection($id_product, $group_by_supplier = true)
|
||||
{
|
||||
$suppliers = new Collection('ProductSupplier');
|
||||
$suppliers->where('a.id_product = '.(int)$id_product);
|
||||
$suppliers->where('id_product', '=', $id_product);
|
||||
|
||||
if ($group_by_supplier)
|
||||
$suppliers->groupBy('a.id_supplier');
|
||||
$suppliers->groupBy('id_supplier');
|
||||
|
||||
return $suppliers;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user