Can set a dedicated message on payment forms
This commit is contained in:
parent
c7537732d2
commit
026f9d8e2a
@ -96,9 +96,10 @@ function payment_supplier_prepare_head(Paiement $object) {
|
|||||||
* @param Societe $fromcompany Third party
|
* @param Societe $fromcompany Third party
|
||||||
* @param Translate $langs Output language
|
* @param Translate $langs Output language
|
||||||
* @param int $addformmessage Add the payment form message
|
* @param int $addformmessage Add the payment form message
|
||||||
|
* @param string $suffix Suffix to use on constants
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
function htmlPrintOnlinePaymentFooter($fromcompany,$langs,$addformmessage=0)
|
function htmlPrintOnlinePaymentFooter($fromcompany,$langs,$addformmessage=0,$suffix='')
|
||||||
{
|
{
|
||||||
global $conf;
|
global $conf;
|
||||||
|
|
||||||
@ -152,16 +153,20 @@ function htmlPrintOnlinePaymentFooter($fromcompany,$langs,$addformmessage=0)
|
|||||||
|
|
||||||
print '<br>';
|
print '<br>';
|
||||||
|
|
||||||
print '<div class="center"><font style="font-size: 10px;">'."\n";
|
print '<div class="center">'."\n";
|
||||||
if ($addformmessage)
|
if ($addformmessage)
|
||||||
{
|
{
|
||||||
$key='ONLINE_PAYMENT_MESSAGE_FORM';
|
print '<br>';
|
||||||
if (! empty($conf->global->$key)) print '<br>'.$conf->global->$key;
|
$parammessageform='ONLINE_PAYMENT_MESSAGE_FORM_'.$suffix;
|
||||||
|
if (! empty($conf->global->$parammessageform)) print $conf->global->$parammessageform;
|
||||||
|
else if (! empty($conf->global->ONLINE_PAYMENT_MESSAGE_FORM)) print $conf->global->ONLINE_PAYMENT_MESSAGE_FORM;
|
||||||
}
|
}
|
||||||
|
|
||||||
print '<br><hr>'."\n";
|
print '<font style="font-size: 10px;"><br><hr>'."\n";
|
||||||
print $fromcompany->name.'<br>';
|
print $fromcompany->name.'<br>';
|
||||||
print $line1.'<br>';
|
print $line1;
|
||||||
|
if (strlen($line1+$line2) > 50) print '<br>';
|
||||||
|
else print ' - ';
|
||||||
print $line2;
|
print $line2;
|
||||||
print '</font></div>'."\n";
|
print '</font></div>'."\n";
|
||||||
}
|
}
|
||||||
|
|||||||
@ -802,7 +802,7 @@ print '</div>'."\n";
|
|||||||
print '<br>';
|
print '<br>';
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs,1);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,1,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
@ -162,7 +162,7 @@ if (! empty($conf->global->$key)) print $conf->global->$key;
|
|||||||
print "\n</div>\n";
|
print "\n</div>\n";
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,0,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
@ -193,7 +193,7 @@ if (! empty($conf->global->ONLINE_PAYMENT_SENDEMAIL))
|
|||||||
|
|
||||||
print "\n</div>\n";
|
print "\n</div>\n";
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,0,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
@ -1447,7 +1447,7 @@ if (preg_match('/^dopayment/',$action))
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs,1);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,1,$suffix);
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|
||||||
|
|||||||
@ -244,7 +244,7 @@ if (! empty($conf->global->$key)) print $conf->global->$key;
|
|||||||
print "\n</div>\n";
|
print "\n</div>\n";
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,0,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
@ -443,7 +443,7 @@ else
|
|||||||
print "\n</div>\n";
|
print "\n</div>\n";
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,0,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
@ -1015,7 +1015,7 @@ print '<br>';
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs,1);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,1,$suffix);
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|
||||||
|
|||||||
@ -172,7 +172,7 @@ if (! empty($conf->global->$key)) print $conf->global->$key;
|
|||||||
print "\n</div>\n";
|
print "\n</div>\n";
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,0,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
@ -328,7 +328,7 @@ else
|
|||||||
|
|
||||||
print "\n</div>\n";
|
print "\n</div>\n";
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,0,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
@ -1229,7 +1229,7 @@ if (preg_match('/^dopayment/',$action))
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs,1);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,1,$suffix);
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|
||||||
|
|||||||
@ -159,7 +159,7 @@ if (! empty($conf->global->$key)) print $conf->global->$key;
|
|||||||
print "\n</div>\n";
|
print "\n</div>\n";
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,0,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
@ -193,7 +193,7 @@ if ($ispaymentok)
|
|||||||
print "\n</div>\n";
|
print "\n</div>\n";
|
||||||
|
|
||||||
|
|
||||||
htmlPrintOnlinePaymentFooter($mysoc,$langs);
|
htmlPrintOnlinePaymentFooter($mysoc,$langs,0,$suffix);
|
||||||
|
|
||||||
|
|
||||||
llxFooter('', 'public');
|
llxFooter('', 'public');
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user