From 025a0dc0b4e35239fd4dc5c8b93a121fba92e436 Mon Sep 17 00:00:00 2001 From: BENKE Charlie Date: Sun, 7 Aug 2016 14:36:48 +0200 Subject: [PATCH] Update facture.class.php --- htdocs/compta/facture/class/facture.class.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/htdocs/compta/facture/class/facture.class.php b/htdocs/compta/facture/class/facture.class.php index 001b9058b24..f41983e5d6f 100644 --- a/htdocs/compta/facture/class/facture.class.php +++ b/htdocs/compta/facture/class/facture.class.php @@ -4141,7 +4141,7 @@ class FactureLigne extends CommonInvoiceLine $sql.= ' fd.date_start as date_start, fd.date_end as date_end, fd.fk_product_fournisseur_price as fk_fournprice, fd.buy_price_ht as pa_ht,'; $sql.= ' fd.info_bits, fd.special_code, fd.total_ht, fd.total_tva, fd.total_ttc, fd.total_localtax1, fd.total_localtax2, fd.rang,'; $sql.= ' fd.fk_code_ventilation,'; - $sql.= ' fd.fk_unit,'; + $sql.= ' fd.fk_unit, fd.fk_user,'; $sql.= ' fd.situation_percent, fd.fk_prev_id,'; $sql.= ' p.ref as product_ref, p.label as product_libelle, p.description as product_desc'; $sql.= ' , fd.multicurrency_subprice'; @@ -4194,6 +4194,7 @@ class FactureLigne extends CommonInvoiceLine $this->product_label = $objp->product_libelle; $this->product_desc = $objp->product_desc; $this->fk_unit = $objp->fk_unit; + $this->fk_user = $objp->fk_user; $this->situation_percent = $objp->situation_percent; $this->fk_prev_id = $objp->fk_prev_id; @@ -4294,7 +4295,7 @@ class FactureLigne extends CommonInvoiceLine $sql.= ' rang, special_code, fk_product_fournisseur_price, buy_price_ht,'; $sql.= ' info_bits, total_ht, total_tva, total_ttc, total_localtax1, total_localtax2,'; $sql.= ' situation_percent, fk_prev_id,'; - $sql.= ' fk_unit'; + $sql.= ' fk_unit, fk_user'; $sql.= ', fk_multicurrency, multicurrency_code, multicurrency_subprice, multicurrency_total_ht, multicurrency_total_tva, multicurrency_total_ttc'; $sql.= ')'; $sql.= " VALUES (".$this->fk_facture.","; @@ -4328,6 +4329,7 @@ class FactureLigne extends CommonInvoiceLine $sql .= ", " . $this->situation_percent; $sql .= ", " . $this->fk_prev_id; $sql .= ", ".(!$this->fk_unit ? 'NULL' : $this->fk_unit); + $sql .= ", ".$user->id; $sql.= ", ".(int) $this->fk_multicurrency; $sql.= ", '".$this->db->escape($this->multicurrency_code)."'"; $sql.= ", ".price2num($this->multicurrency_subprice);