2
0
forked from Wavyzz/dolibarr

Clean code around fetch_optionals()

This commit is contained in:
Laurent Destailleur
2018-02-20 19:38:18 +01:00
parent 8b54a80593
commit c4130730cb
29 changed files with 135 additions and 198 deletions

View File

@@ -1668,12 +1668,9 @@ class Commande extends CommonOrder
if ($this->statut == self::STATUS_DRAFT) $this->brouillon = 1;
// Retrieve all extrafields for invoice
// Retreive all extrafield
// fetch optionals attributes and labels
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
$extrafields=new ExtraFields($this->db);
$extralabels=$extrafields->fetch_name_optionals_label($this->table_element,true);
$this->fetch_optionals($this->id,$extralabels);
$this->fetch_optionals();
$this->db->free($result);