From 374b761fdf3ad7013c671aa4c1c334da921597cf Mon Sep 17 00:00:00 2001
From: MAxime Kohlhaas <maxime@atm-consulting.fr>
Date: Sat, 25 Oct 2014 19:20:02 +0200
Subject: [PATCH] Fix : product list was wrong on supplier invoice because
 fourn_id is not fetched

---
 htdocs/core/tpl/objectline_create.tpl.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/htdocs/core/tpl/objectline_create.tpl.php b/htdocs/core/tpl/objectline_create.tpl.php
index a51a6505416..ed06bca8725 100644
--- a/htdocs/core/tpl/objectline_create.tpl.php
+++ b/htdocs/core/tpl/objectline_create.tpl.php
@@ -152,7 +152,7 @@ else {
 					'option_disabled' => 'addPredefinedProductButton',	// html id to disable once select is done
 					'warning' => $langs->trans("NoPriceDefinedForThisSupplier") // translation of an error saved into var 'error'
 			);
-			$form->select_produits_fournisseurs($object->fourn_id, GETPOST('idprodfournprice'), 'idprodfournprice', '', '', $ajaxoptions, 1);
+			$form->select_produits_fournisseurs($object->socid, GETPOST('idprodfournprice'), 'idprodfournprice', '', '', $ajaxoptions, 1);
 		}
 		echo '</span>';
 	}
-- 
GitLab