From 8819e2b286f133ec19d6c54d1ec575f4797d733e Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Tue, 30 May 2006 10:56:48 +0000 Subject: [PATCH] =?UTF-8?q?D=E9but=20ajout=20bon=20de=20livraison?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/livraison/fiche.php | 17 ++++++++++------- htdocs/livraison/livraison.class.php | 5 +++-- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/htdocs/livraison/fiche.php b/htdocs/livraison/fiche.php index 27811f9688d..03a985aeda2 100644 --- a/htdocs/livraison/fiche.php +++ b/htdocs/livraison/fiche.php @@ -424,13 +424,16 @@ else // Date print ''.$langs->trans("Date").''; - print "".strftime("%A %d %B %Y",$livraison->date)."\n"; -/* - // Entrepot - $entrepot = new Entrepot($db); - $entrepot->fetch($expedition->entrepot_id); - print ''.$langs->trans("Warehouse").''.$entrepot->libelle.''; -*/ + print "".strftime("%A %d %B %Y",$livraison->date_creation)."\n"; + + if (!$conf->expedition->enabled && $conf->stock->enabled) + { + // Entrepot + $entrepot = new Entrepot($db); + $entrepot->fetch($expedition->entrepot_id); + print ''.$langs->trans("Warehouse").''.$entrepot->libelle.''; + } + print ''; print "\n"; diff --git a/htdocs/livraison/livraison.class.php b/htdocs/livraison/livraison.class.php index 1f89547e14d..b2c7b7afb8d 100644 --- a/htdocs/livraison/livraison.class.php +++ b/htdocs/livraison/livraison.class.php @@ -214,6 +214,7 @@ class Livraison $obj = $this->db->fetch_object($result); $this->id = $obj->rowid; + $this->date_creation = $obj->date_creation; $this->ref = $obj->ref; $this->soc_id = $obj->socid; $this->statut = $obj->fk_statut; @@ -221,11 +222,11 @@ class Livraison $this->expedition_id = $obj->fk_expedition; $this->user_author_id = $obj->fk_user_author; $this->user_valid_id = $obj->fk_user_valid; - $this->date = $obj->date_livraison; + $this->date_livraison = $obj->date_livraison; $this->adresse_livraison_id = $obj->fk_entrepot; $this->note = $obj->note; $this->note_public = $obj->note_public; - $this->modelpdf = $obj->model_pdf; + $this->modelpdf = $obj->model_pdf; $this->db->free(); if ($this->statut == 0) $this->brouillon = 1;