diff --git a/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php b/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php index 4a1915b0a349c420300fdac1616d62bd5e15ddbb..be1d81ed1d24db0a40eb40de70ac95e3eceac2b9 100644 --- a/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php +++ b/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php @@ -82,7 +82,7 @@ class pdf_soleil extends ModelePDFFicheinter $this->option_modereg = 0; // Affiche mode reglement $this->option_condreg = 0; // Affiche conditions reglement $this->option_codeproduitservice = 0; // Affiche code produit-service - $this->option_multilang = 0; // Dispo en plusieurs langues + $this->option_multilang = 1; // Dispo en plusieurs langues $this->option_draft_watermark = 1; //Support add of a watermark on drafts // Get source company diff --git a/htdocs/societe/class/societe.class.php b/htdocs/societe/class/societe.class.php index 72558da58bbfe7f8dcf5cbc104853d9dd0cfb5d7..cfd37436b721601b5d7bd53aab6a81731ae6110c 100644 --- a/htdocs/societe/class/societe.class.php +++ b/htdocs/societe/class/societe.class.php @@ -1840,12 +1840,18 @@ class Societe extends CommonObject $nump = $this->db->num_rows($resql); if ($nump) { + $sepa="("; $sepb=")"; + if ($mode == 'email') + { + $sepa="<"; $sepb=">"; + } $i = 0; while ($i < $nump) { $obj = $this->db->fetch_object($resql); if ($mode == 'email') $property=$obj->email; else if ($mode == 'mobile') $property=$obj->phone_mobile; + else $property=$obj->$mode; // Show all contact. If hidedisabled is 1, showonly contacts with status = 1 if ($obj->statut == 1 || empty($hidedisabled)) @@ -1858,11 +1864,11 @@ class Societe extends CommonObject if (!empty($obj->poste)) { - $contact_property[$obj->rowid] = trim(dolGetFirstLastname($obj->firstname,$obj->lastname))."(".$obj->poste.")"." <".$property.">"; + $contact_property[$obj->rowid] = trim(dolGetFirstLastname($obj->firstname,$obj->lastname)).($obj->poste?" - ".$obj->poste:"").(($mode != 'poste' && $property)?" ".$sepa.$property.$sepb:''); } else { - $contact_property[$obj->rowid] = trim(dolGetFirstLastname($obj->firstname,$obj->lastname))." <".$property.">"; + $contact_property[$obj->rowid] = trim(dolGetFirstLastname($obj->firstname,$obj->lastname)).(($mode != 'poste' && $property)?" ".$sepa.$property.$sepb:''); } } $i++;