From e4984492b3173a053362da42bd11f59b7d511ed4 Mon Sep 17 00:00:00 2001 From: Ferran Marcet Date: Tue, 17 Sep 2019 09:32:43 +0200 Subject: [PATCH] Dejarlo igual que develop --- htdocs/compta/facture/class/facture-rec.class.php | 6 +----- htdocs/compta/facture/class/facture.class.php | 1 - htdocs/install/mysql/tables/llx_facture_rec.sql | 1 - 3 files changed, 1 insertion(+), 7 deletions(-) diff --git a/htdocs/compta/facture/class/facture-rec.class.php b/htdocs/compta/facture/class/facture-rec.class.php index 57ecc836acf..37a031198bc 100644 --- a/htdocs/compta/facture/class/facture-rec.class.php +++ b/htdocs/compta/facture/class/facture-rec.class.php @@ -77,7 +77,6 @@ class FactureRec extends CommonInvoice public $total; public $db_table; public $propalid; - public $ref_client; public $date_last_gen; public $date_when; @@ -168,7 +167,6 @@ class FactureRec extends CommonInvoice $sql.= ", fk_account"; $sql.= ", fk_cond_reglement"; $sql.= ", fk_mode_reglement"; - $sql.= ", ref_client"; $sql.= ", usenewprice"; $sql.= ", frequency"; $sql.= ", unit_frequency"; @@ -197,7 +195,6 @@ class FactureRec extends CommonInvoice $sql.= ", ".(! empty($facsrc->fk_account)?"'".$facsrc->fk_account."'":"null"); $sql.= ", ".($facsrc->cond_reglement_id > 0 ? $this->db->escape($facsrc->cond_reglement_id) : "null"); $sql.= ", ".($facsrc->mode_reglement_id > 0 ? $this->db->escape($facsrc->mode_reglement_id) : "null"); - $sql.= ",'".$this->db->escape($this->ref_client)."'"; $sql.= ", ".$this->usenewprice; $sql.= ", ".$this->frequency; $sql.= ", '".$this->db->escape($this->unit_frequency)."'"; @@ -386,7 +383,7 @@ class FactureRec extends CommonInvoice $sql.= ', f.note_private, f.note_public, f.fk_user_author'; $sql.= ', f.modelpdf'; $sql.= ', f.fk_mode_reglement, f.fk_cond_reglement, f.fk_projet as fk_project'; - $sql.= ', f.fk_account, f.ref_client'; + $sql.= ', f.fk_account'; $sql.= ', f.frequency, f.unit_frequency, f.date_when, f.date_last_gen, f.nb_gen_done, f.nb_gen_max, f.usenewprice, f.auto_validate'; $sql.= ', f.generate_pdf'; $sql.= ", f.fk_multicurrency, f.multicurrency_code, f.multicurrency_tx, f.multicurrency_total_ht, f.multicurrency_total_tva, f.multicurrency_total_ttc"; @@ -1147,7 +1144,6 @@ class FactureRec extends CommonInvoice $facture->brouillon = 1; $facture->date = (empty($facturerec->date_when)?$now:$facturerec->date_when); // We could also use dol_now here but we prefer date_when so invoice has real date when we would like even if we generate later. $facture->socid = $facturerec->socid; - $facture->ref_client = $facturerec->ref_client; $invoiceidgenerated = $facture->create($user); if ($invoiceidgenerated <= 0) diff --git a/htdocs/compta/facture/class/facture.class.php b/htdocs/compta/facture/class/facture.class.php index 70ecf6500f5..131f0ee90fd 100644 --- a/htdocs/compta/facture/class/facture.class.php +++ b/htdocs/compta/facture/class/facture.class.php @@ -372,7 +372,6 @@ class Facture extends CommonInvoice $this->socid = $_facrec->socid; // Invoice created on same thirdparty than template $this->entity = $_facrec->entity; // Invoice created in same entity than template - $this->ref_client = $_facrec->ref_client; // Fields coming from GUI (priority on template). TODO Value of template should be used as default value on GUI so we can use here always value from GUI $this->fk_project = GETPOST('projectid', 'int') > 0 ? ((int) GETPOST('projectid', 'int')) : $_facrec->fk_project; diff --git a/htdocs/install/mysql/tables/llx_facture_rec.sql b/htdocs/install/mysql/tables/llx_facture_rec.sql index 2c1c2514488..1add07c6e8c 100644 --- a/htdocs/install/mysql/tables/llx_facture_rec.sql +++ b/htdocs/install/mysql/tables/llx_facture_rec.sql @@ -29,7 +29,6 @@ create table llx_facture_rec tms timestamp, -- date creation/modification suspended integer DEFAULT 0, -- 1=suspended - ref_client varchar(255), -- reference for customer amount double(24,8) DEFAULT 0 NOT NULL, remise real DEFAULT 0,