fix: Format thirdparty address label on pdf. Currently, an extra blank line is displayed between city/state and before country

This commit is contained in:
Erik van Berkum 2023-04-10 18:59:24 +09:00
parent 38bbc1d28d
commit ecb2492675

View File

@ -603,7 +603,7 @@ function pdf_build_address($outputlangs, $sourcecompany, $targetcompany = '', $t
}
} else {
if (is_object($targetcompany)) {
$stringaddress .= ($stringaddress ? "\n" : '').$outputlangs->convToOutputCharset(dol_format_address($targetcompany))."\n";
$stringaddress .= ($stringaddress ? "\n" : '').$outputlangs->convToOutputCharset(dol_format_address($targetcompany));
// Country
if (!empty($targetcompany->country_code) && $targetcompany->country_code != $sourcecompany->country_code) {
$stringaddress .= ($stringaddress ? "\n" : '').$outputlangs->convToOutputCharset($outputlangs->transnoentitiesnoconv("Country".$targetcompany->country_code));