From 36ad3bfbc9bcf1d455d664e6723389add0c3bb1a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20FRANCE?= Date: Thu, 22 Oct 2020 21:11:49 +0200 Subject: [PATCH] Update product.class.php --- htdocs/product/class/product.class.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/htdocs/product/class/product.class.php b/htdocs/product/class/product.class.php index 2427ac74714..ccb81ad03bc 100644 --- a/htdocs/product/class/product.class.php +++ b/htdocs/product/class/product.class.php @@ -14,7 +14,7 @@ * Copyright (C) 2014 Ion agorria * Copyright (C) 2016-2018 Ferran Marcet * Copyright (C) 2017 Gustavo Novaro - * Copyright (C) 2019 Frédéric France + * Copyright (C) 2019-2020 Frédéric France * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -2441,6 +2441,7 @@ class Product extends CommonObject $sql .= " WHERE "; $sql .= " b.entity IN (".getEntity('bom').")"; $sql .= " AND b.fk_product =".$this->id; + $sql .= " GROUP BY b.rowid"; $result = $this->db->query($sql); if ($result) {