Fix: If object already loaded, the url was not returned.
This commit is contained in:
parent
bf9b8657c3
commit
a249061017
@ -3765,11 +3765,10 @@ class Form
|
||||
if (empty($object->barcode_type_code) || empty($object->barcode_type_coder))
|
||||
{
|
||||
$result = $object->fetch_barcode();
|
||||
//Check if fetch_barcode() failed
|
||||
if ($result < 1) return '<!-- ErrorFetchBarcode -->';
|
||||
}
|
||||
|
||||
//Check if fetch_barcode() failed
|
||||
if ($result < 1) return '';
|
||||
|
||||
// Barcode image
|
||||
$url=DOL_URL_ROOT.'/viewimage.php?modulepart=barcode&generator='.urlencode($object->barcode_type_coder).'&code='.urlencode($object->barcode).'&encoding='.urlencode($object->barcode_type_code);
|
||||
$out ='<!-- url barcode = '.$url.' -->';
|
||||
|
||||
Loading…
Reference in New Issue
Block a user