forked from Wavyzz/dolibarr
FIX - Online Sign pos on last page (#30158)
Co-authored-by: Anthony Berton <anthony.berton@bb2a.fr>
This commit is contained in:
@@ -215,9 +215,21 @@ if ($action == "importSignature") {
|
||||
// A signature image file is 720 x 180 (ratio 1/4) but we use only the size into PDF
|
||||
// TODO Get position of box from PDF template
|
||||
|
||||
$param['xforimgstart'] = (empty($s['w']) ? 120 : round($s['w'] / 2) + 15);
|
||||
$param['yforimgstart'] = (empty($s['h']) ? 240 : $s['h'] - 60);
|
||||
$param['wforimg'] = $s['w'] - 20 - $param['xforimgstart'];
|
||||
if (getDolGlobalString("PROPAL_SIGNATURE_XFORIMGSTART")) {
|
||||
$param['xforimgstart'] = getDolGlobalString("PROPAL_SIGNATURE_XFORIMGSTART");
|
||||
} else {
|
||||
$param['xforimgstart'] = (empty($s['w']) ? 120 : round($s['w'] / 2) + 15);
|
||||
}
|
||||
if (getDolGlobalString("PROPAL_SIGNATURE_YFORIMGSTART")) {
|
||||
$param['yforimgstart'] = getDolGlobalString("PROPAL_SIGNATURE_YFORIMGSTART");
|
||||
} else {
|
||||
$param['yforimgstart'] = (empty($s['h']) ? 240 : $s['h'] - 60);
|
||||
}
|
||||
if (getDolGlobalString("PROPAL_SIGNATURE_WFORIMG")) {
|
||||
$param['wforimg'] = getDolGlobalString("PROPAL_SIGNATURE_WFORIMG");
|
||||
} else {
|
||||
$param['wforimg'] = $s['w'] - 20 - $param['xforimgstart'];
|
||||
}
|
||||
|
||||
dolPrintSignatureImage($pdf, $langs, $param);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user