From c59e26457deaecc332cffd58be91c923a2883133 Mon Sep 17 00:00:00 2001 From: altairis Date: Wed, 25 Sep 2019 12:18:19 +0200 Subject: [PATCH] add MAIN_SHOW_COMPANY_NAME_IN_BANNER_ADDRESS constant --- htdocs/core/class/commonobject.class.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php index 817713f221b..4f522956f59 100644 --- a/htdocs/core/class/commonobject.class.php +++ b/htdocs/core/class/commonobject.class.php @@ -616,7 +616,12 @@ abstract class CommonObject { if (! empty($conf->use_javascript_ajax)) { - $namecoords = $this->getFullName($langs, 1).'
'.$coords; + $namecoords = ''; + if ( $this->element == 'contact' && ! empty($conf->global->MAIN_SHOW_COMPANY_NAME_IN_BANNER_ADDRESS)) + { + $namecoords.= $object->name.'
'; + } + $namecoords.= $this->getFullName($langs, 1).'
'.$coords; // hideonsmatphone because copyToClipboard call jquery dialog that does not work with jmobile $out.=''; $out.=img_picto($langs->trans("Address"), 'object_address.png');