Skip to content

Commit

Permalink
Merge branch '6.0' of git@github.com:Dolibarr/dolibarr.git into 7.0
Browse files Browse the repository at this point in the history
Conflicts:
	htdocs/core/lib/pdf.lib.php
  • Loading branch information
eldy committed Sep 5, 2018
2 parents f216da7 + f7d5172 commit dfea391
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
13 changes: 11 additions & 2 deletions htdocs/core/lib/pdf.lib.php
Expand Up @@ -434,8 +434,17 @@ function pdf_build_address($outputlangs,$sourcecompany,$targetcompany='',$target

if (!empty($targetcontact->address)) {
$stringaddress .= ($stringaddress ? "\n" : '' ).$outputlangs->convToOutputCharset(dol_format_address($targetcontact));
}else {
$stringaddress .= ($stringaddress ? "\n" : '' ).$outputlangs->convToOutputCharset(dol_format_address($targetcompany));
} else {
$companytouseforaddress = $targetcompany;

// Contact on a thirdparty that is a different thirdparty than the thirdparty of object
if ($targetcontact->socid > 0 && $targetcontact->socid != $targetcompany->id)
{
$targetcontact->fetch_thirparty();
$companytouseforaddress = $targetcontact->thirdparty;
}

$stringaddress .= ($stringaddress ? "\n" : '' ).$outputlangs->convToOutputCharset(dol_format_address($companytouseforaddress));
}
// Country
if (!empty($targetcontact->country_code) && $targetcontact->country_code != $sourcecompany->country_code) {
Expand Down
1 change: 1 addition & 0 deletions htdocs/product/dynamic_price/class/index.html
@@ -0,0 +1 @@

1 change: 1 addition & 0 deletions htdocs/product/dynamic_price/index.html
@@ -0,0 +1 @@

0 comments on commit dfea391

Please sign in to comment.