Update card_presend.tpl.php

Add hidden feature ORDER_SUPPLIER_EMAIL_SENDER as sender address for purchase order emails
This commit is contained in:
Frans Bosman 2021-12-13 20:33:42 +01:00 committed by GitHub
parent 57ebcf94c0
commit 8c844c96df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -147,6 +147,11 @@ if ($action == 'presend')
$formmail->fromname = '';
$formmail->fromtype = 'special';
}
if ($object->element === 'order_supplier' && !empty($conf->global->ORDER_SUPPLIER_EMAIL_SENDER)) {
$formmail->frommail = $conf->global->ORDER_SUPPLIER_EMAIL_SENDER;
$formmail->fromname = '';
$formmail->fromtype = 'special';
}
$formmail->trackid=$trackid;
if (!empty($conf->global->MAIN_EMAIL_ADD_TRACK_ID) && ($conf->global->MAIN_EMAIL_ADD_TRACK_ID & 2)) // If bit 2 is set