Fix: Better error management

This commit is contained in:
Laurent Destailleur 2013-04-01 22:35:54 +02:00
parent 954af0f6c7
commit 110d0f1d3b

View File

@ -1253,14 +1253,16 @@ else
$productstatic = new Product($db); $productstatic = new Product($db);
$object->fetch($id); $object->fetch($id);
$object->fetch_thirdparty(); $result=$object->fetch_thirdparty();
if ($result < 0) dol_print_error($db);
$societe = new Fournisseur($db); $societe = new Fournisseur($db);
$societe->fetch($object->socid); $result=$societe->fetch($object->socid);
if ($result < 0) dol_print_error($db);
/* /*
* View card * View card
*/ */
$head = facturefourn_prepare_head($object); $head = facturefourn_prepare_head($object);
$titre=$langs->trans('SupplierInvoice'); $titre=$langs->trans('SupplierInvoice');
dol_fiche_head($head, 'card', $titre, 0, 'bill'); dol_fiche_head($head, 'card', $titre, 0, 'bill');