New: Add product_label into substitution tags for ODT.
This commit is contained in:
parent
f74440aa65
commit
b8a61e73a0
@ -337,6 +337,7 @@ class FactureRec extends Facture
|
||||
$line->product_type = $objp->product_type; // Type of line
|
||||
$line->product_ref = $objp->product_ref; // Ref product
|
||||
$line->libelle = $objp->label; // Label product
|
||||
$line->product_label = $objp->product_label;
|
||||
$line->product_desc = $objp->product_desc; // Description product
|
||||
$line->fk_product_type = $objp->fk_product_type; // Type of product
|
||||
$line->qty = $objp->qty;
|
||||
|
||||
@ -856,6 +856,7 @@ class Facture extends CommonObject
|
||||
$line->product_type = $objp->product_type; // Type of line
|
||||
$line->product_ref = $objp->product_ref; // Ref product
|
||||
$line->libelle = $objp->label; // Label product
|
||||
$line->product_label = $objp->product_label;
|
||||
$line->product_desc = $objp->product_desc; // Description product
|
||||
$line->fk_product_type = $objp->fk_product_type; // Type of product
|
||||
$line->qty = $objp->qty;
|
||||
|
||||
@ -132,7 +132,7 @@ class doc_generic_order_odt extends ModelePDFCommandes
|
||||
'line_fulldesc'=>doc_getlinedesc($line),
|
||||
'line_product_ref'=>$line->product_ref,
|
||||
'line_product_label'=>$line->product_label,
|
||||
'line_desc'=>$line->desc,
|
||||
'line_desc'=>$line->desc,
|
||||
'line_vatrate'=>vatrate($line->tva_tx,true,$line->info_bits),
|
||||
'line_up'=>price($line->subprice, 0, $outputlangs),
|
||||
'line_qty'=>$line->qty,
|
||||
|
||||
@ -841,7 +841,7 @@ class Expedition extends CommonObject
|
||||
|
||||
$sql = "SELECT cd.rowid, cd.fk_product, cd.description, cd.qty as qty_asked";
|
||||
$sql.= ", ed.qty as qty_shipped, ed.fk_origin_line, ed.fk_entrepot";
|
||||
$sql.= ", p.ref as product_ref, p.fk_product_type, p.label, p.weight, p.weight_units, p.volume, p.volume_units";
|
||||
$sql.= ", p.ref as product_ref, p.label as product_label, p.fk_product_type, p.weight, p.weight_units, p.volume, p.volume_units";
|
||||
$sql.= " FROM (".MAIN_DB_PREFIX."expeditiondet as ed,";
|
||||
$sql.= " ".MAIN_DB_PREFIX."commandedet as cd)";
|
||||
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."product as p ON p.rowid = cd.fk_product";
|
||||
@ -860,14 +860,15 @@ class Expedition extends CommonObject
|
||||
$obj = $this->db->fetch_object($resql);
|
||||
|
||||
$line->fk_origin_line = $obj->fk_origin_line;
|
||||
$line->origin_line_id = $obj->fk_origin_line; // TODO deprecated
|
||||
$line->origin_line_id = $obj->fk_origin_line; // TODO deprecated
|
||||
$line->entrepot_id = $obj->fk_entrepot;
|
||||
$line->fk_product = $obj->fk_product;
|
||||
$line->fk_product_type = $obj->fk_product_type;
|
||||
$line->ref = $obj->product_ref; // TODO deprecated
|
||||
$line->product_ref = $obj->product_ref;
|
||||
$line->label = $obj->label;
|
||||
$line->libelle = $obj->label; // TODO deprecated
|
||||
$line->product_label = $obj->product_label;
|
||||
$line->label = $obj->product_label;
|
||||
$line->libelle = $obj->product_label; // TODO deprecated
|
||||
$line->description = $obj->description;
|
||||
$line->qty_asked = $obj->qty_asked;
|
||||
$line->qty_shipped = $obj->qty_shipped;
|
||||
|
||||
@ -176,7 +176,7 @@ class CommandeFournisseur extends Commande
|
||||
$sql.= " l.tva_tx, l.remise_percent, l.subprice,";
|
||||
$sql.= " l.localtax1_tx, l. localtax2_tx, l.total_localtax1, l.total_localtax2,";
|
||||
$sql.= " l.total_ht, l.total_tva, l.total_ttc,";
|
||||
$sql.= " p.rowid as product_id, p.ref as product_ref, p.label as label, p.description as product_desc";
|
||||
$sql.= " p.rowid as product_id, p.ref as product_ref, p.label as product_label, p.description as product_desc";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."commande_fournisseurdet as l";
|
||||
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'product as p ON l.fk_product = p.rowid';
|
||||
$sql.= " WHERE l.fk_commande = ".$this->id;
|
||||
@ -212,9 +212,11 @@ class CommandeFournisseur extends Commande
|
||||
$line->total_ttc = $objp->total_ttc;
|
||||
$line->product_type = $objp->product_type;
|
||||
|
||||
$line->fk_product = $objp->fk_product; // Id du produit
|
||||
$line->libelle = $objp->label; // Label produit
|
||||
$line->product_desc = $objp->product_desc; // Description produit
|
||||
$line->fk_product = $objp->fk_product; // Id du produit
|
||||
|
||||
$line->libelle = $objp->product_label; // TODO deprecated
|
||||
$line->product_label = $objp->product_label; // Label produit
|
||||
$line->product_desc = $objp->product_desc; // Description produit
|
||||
|
||||
$line->ref = $objp->product_ref; // TODO deprecated
|
||||
$line->product_ref = $objp->product_ref; // Internal reference
|
||||
|
||||
Loading…
Reference in New Issue
Block a user