From 18d14d89dc376e2173e7455a9c7914a55ba92eda Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Tue, 12 Apr 2005 13:45:32 +0000 Subject: [PATCH] =?UTF-8?q?Mise=20=E0=20jour=20du=20lien=20vers=20la=20fic?= =?UTF-8?q?he=20produit?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/fourn/commande/fiche.php | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/htdocs/fourn/commande/fiche.php b/htdocs/fourn/commande/fiche.php index cbe400c10f0..5c4b2038d95 100644 --- a/htdocs/fourn/commande/fiche.php +++ b/htdocs/fourn/commande/fiche.php @@ -361,8 +361,8 @@ if ($_GET["id"] > 0) $sql .= " FROM ".MAIN_DB_PREFIX."commande_fournisseurdet as l "; $sql .= " WHERE l.fk_commande = $commande->id ORDER BY l.rowid"; - $result = $db->query($sql); - if ($result) + $resql = $db->query($sql); + if ($resql) { $num_lignes = $db->num_rows(); $i = 0; $total = 0; @@ -388,7 +388,7 @@ if ($_GET["id"] > 0) if ($objp->fk_product > 0) { print ''; - print ''.stripslashes(nl2br($objp->description)).''; + print ''.stripslashes(nl2br($objp->description)).''; } else { @@ -454,20 +454,22 @@ if ($_GET["id"] > 0) $sql .= " WHERE p.rowid = pf.fk_product AND pf.fk_soc = ".$commande->fourn_id; $sql .= " AND quantity = 1"; $sql .= " ORDER BY p.ref "; - if ( $db->query($sql) ) + $resql = $db->query($sql); + if ($resql) { $opt = ""; - if ($result) + if ($resql) { - $num = $db->num_rows(); $i = 0; + $num = $db->num_rows($resql); + $i = 0; while ($i < $num) { - $objp = $db->fetch_object(); + $objp = $db->fetch_object($resql); $opt .= "\n"; $i++; } } - $db->free(); + $db->free($resql); } else {