Fix: [ bug #240 ] No description while adding a line in an Supplier

invoice
This commit is contained in:
Laurent Destailleur 2011-12-01 22:25:11 +01:00
parent 497ebdfdf2
commit e35ff42eda

View File

@ -403,7 +403,7 @@ if ($_REQUEST['action'] == 'update_line')
{ {
$prod = new Product($db); $prod = new Product($db);
$prod->fetch($_POST['idprod']); $prod->fetch($_POST['idprod']);
$label = $prod->libelle; $label = $prod->description;
if (trim($_POST['label']) != trim($label)) $label=$_POST['label']; if (trim($_POST['label']) != trim($label)) $label=$_POST['label'];
$type = $prod->type; $type = $prod->type;
@ -457,9 +457,7 @@ if ($_GET['action'] == 'addline')
// cas special pour lequel on a les meme reference que le fournisseur // cas special pour lequel on a les meme reference que le fournisseur
// $label = '['.$product->ref.'] - '. $product->libelle; // $label = '['.$product->ref.'] - '. $product->libelle;
$label = $product->libelle; $label = $product->description;
$tvatx=get_default_tva($societe,$mysoc,$product->id); $tvatx=get_default_tva($societe,$mysoc,$product->id);