Highliting IBAN (sepa)
Highliting IBAN code in pdf ( SEPA )
This commit is contained in:
parent
e18caccdc9
commit
7318d0fbc0
@ -524,6 +524,28 @@ function pdf_bank(&$pdf,$outputlangs,$curx,$cury,$account,$onlynumber=0,$default
|
|||||||
$cury+=3;
|
$cury+=3;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Use correct name of bank id according to country
|
||||||
|
$ibankey="IBANNumber";
|
||||||
|
if ($account->getCountryCode() == 'IN') $ibankey="IFSC";
|
||||||
|
if (! empty($account->iban))
|
||||||
|
{
|
||||||
|
|
||||||
|
$ibanDisplay_temp = $outputlangs->convToOutputCharset($account->iban);
|
||||||
|
$ibanDisplay = "";
|
||||||
|
|
||||||
|
for($i = 0; $i < dol_strlen($ibanDisplay_temp); $i++){
|
||||||
|
$ibanDisplay .= $ibanDisplay_temp[$i];
|
||||||
|
if($i%4 == 3 && $i > 0){
|
||||||
|
$ibanDisplay .= " ";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$pdf->SetFont('','B',$default_font_size - 3);
|
||||||
|
$pdf->SetXY($curx, $cury);
|
||||||
|
$pdf->MultiCell(100, 3, $outputlangs->transnoentities($ibankey).': ' . $ibanDisplay, 0, 'L', 0);
|
||||||
|
$cury+=3;
|
||||||
|
}
|
||||||
|
|
||||||
if (empty($onlynumber)) $pdf->line($curx+1, $cury+1, $curx+1, $cury+8);
|
if (empty($onlynumber)) $pdf->line($curx+1, $cury+1, $curx+1, $cury+8);
|
||||||
|
|
||||||
if ($usedetailedbban == 1)
|
if ($usedetailedbban == 1)
|
||||||
@ -604,9 +626,7 @@ function pdf_bank(&$pdf,$outputlangs,$curx,$cury,$account,$onlynumber=0,$default
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Use correct name of bank id according to country
|
// Use correct name of bank id according to country
|
||||||
$ibankey="IBANNumber";
|
|
||||||
$bickey="BICNumber";
|
$bickey="BICNumber";
|
||||||
if ($account->getCountryCode() == 'IN') $ibankey="IFSC";
|
|
||||||
if ($account->getCountryCode() == 'IN') $bickey="SWIFT";
|
if ($account->getCountryCode() == 'IN') $bickey="SWIFT";
|
||||||
|
|
||||||
$pdf->SetFont('','',$default_font_size - $diffsizecontent);
|
$pdf->SetFont('','',$default_font_size - $diffsizecontent);
|
||||||
@ -623,13 +643,6 @@ function pdf_bank(&$pdf,$outputlangs,$curx,$cury,$account,$onlynumber=0,$default
|
|||||||
}
|
}
|
||||||
else if (! $usedetailedbban) $cury+=1;
|
else if (! $usedetailedbban) $cury+=1;
|
||||||
|
|
||||||
if (! empty($account->iban))
|
|
||||||
{
|
|
||||||
$pdf->SetXY($curx, $cury);
|
|
||||||
$pdf->MultiCell(100, 3, $outputlangs->transnoentities($ibankey).': ' . $outputlangs->convToOutputCharset($account->iban), 0, 'L', 0);
|
|
||||||
$cury+=3;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (! empty($account->bic))
|
if (! empty($account->bic))
|
||||||
{
|
{
|
||||||
$pdf->SetXY($curx, $cury);
|
$pdf->SetXY($curx, $cury);
|
||||||
@ -639,7 +652,6 @@ function pdf_bank(&$pdf,$outputlangs,$curx,$cury,$account,$onlynumber=0,$default
|
|||||||
return $pdf->getY();
|
return $pdf->getY();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Show footer of page for PDF generation
|
* Show footer of page for PDF generation
|
||||||
*
|
*
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user