From 05772531397551fc7ea3fa1daed516aa3192cb75 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Tue, 9 May 2006 19:01:20 +0000 Subject: [PATCH] =?UTF-8?q?r=E9cup=E9ration=20des=20conditions=20de=20r=E8?= =?UTF-8?q?glement=20d'une=20commande?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/commande/commande.class.php | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/htdocs/commande/commande.class.php b/htdocs/commande/commande.class.php index 94f2d256906..b9a798babf1 100644 --- a/htdocs/commande/commande.class.php +++ b/htdocs/commande/commande.class.php @@ -683,6 +683,23 @@ class Commande $this->adresse_livraison_id = $obj->fk_adresse_livraison; $this->db->free(); + + if ($this->cond_reglement_id) + { + $sql = "SELECT rowid, libelle, code"; + $sql.= " FROM ".MAIN_DB_PREFIX."cond_reglement"; + $sql.= " WHERE rowid = ".$this->cond_reglement_id; + + $resqlcond = $this->db->query($sql); + + if ($resqlcond) + { + $objc = $this->db->fetch_object($resqlcond); + $this->cond_reglement = $objc->libelle; + $this->cond_reglement_code = $objc->code; + } + } + if ($this->statut == 0) $this->brouillon = 1; // exp pdf -----------