mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-13 13:01:27 +01:00
Merge pull request #9820 from laudeco/hotfix/9640_member_email
FIX the member e-mail on resign and validation.
This commit is contained in:
@@ -634,6 +634,11 @@ if (empty($reshook))
|
|||||||
$msg = $arraydefaultmessage->content;
|
$msg = $arraydefaultmessage->content;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (empty($labeltouse) || (int)$labeltouse === -1) {
|
||||||
|
//fallback on the old configuration.
|
||||||
|
setEventMessages('WarningMandatorySetupNotComplete', [], 'errors');
|
||||||
|
$error++;
|
||||||
|
}else{
|
||||||
$substitutionarray=getCommonSubstitutionArray($outputlangs, 0, null, $object);
|
$substitutionarray=getCommonSubstitutionArray($outputlangs, 0, null, $object);
|
||||||
complete_substitutions_array($substitutionarray, $outputlangs, $object);
|
complete_substitutions_array($substitutionarray, $outputlangs, $object);
|
||||||
$subjecttosend = make_substitutions($subject, $substitutionarray, $outputlangs);
|
$subjecttosend = make_substitutions($subject, $substitutionarray, $outputlangs);
|
||||||
@@ -647,6 +652,9 @@ if (empty($reshook))
|
|||||||
$error++;
|
$error++;
|
||||||
setEventMessages($object->error, $object->errors, 'errors');
|
setEventMessages($object->error, $object->errors, 'errors');
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -707,6 +715,11 @@ if (empty($reshook))
|
|||||||
$msg = $arraydefaultmessage->content;
|
$msg = $arraydefaultmessage->content;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (empty($labeltouse) || (int)$labeltouse === -1) {
|
||||||
|
//fallback on the old configuration.
|
||||||
|
setEventMessages('WarningMandatorySetupNotComplete', [], 'errors');
|
||||||
|
$error++;
|
||||||
|
}else{
|
||||||
$substitutionarray=getCommonSubstitutionArray($outputlangs, 0, null, $object);
|
$substitutionarray=getCommonSubstitutionArray($outputlangs, 0, null, $object);
|
||||||
complete_substitutions_array($substitutionarray, $outputlangs, $object);
|
complete_substitutions_array($substitutionarray, $outputlangs, $object);
|
||||||
$subjecttosend = make_substitutions($subject, $substitutionarray, $outputlangs);
|
$subjecttosend = make_substitutions($subject, $substitutionarray, $outputlangs);
|
||||||
@@ -715,13 +728,16 @@ if (empty($reshook))
|
|||||||
$moreinheader='X-Dolibarr-Info: send_an_email by adherents/card.php'."\r\n";
|
$moreinheader='X-Dolibarr-Info: send_an_email by adherents/card.php'."\r\n";
|
||||||
|
|
||||||
$result=$object->send_an_email($texttosend, $subjecttosend, array(), array(), array(), "", "", 0, -1, '', $moreinheader);
|
$result=$object->send_an_email($texttosend, $subjecttosend, array(), array(), array(), "", "", 0, -1, '', $moreinheader);
|
||||||
}
|
|
||||||
if ($result < 0)
|
if ($result < 0)
|
||||||
{
|
{
|
||||||
$error++;
|
$error++;
|
||||||
setEventMessages($object->error, $object->errors, 'errors');
|
setEventMessages($object->error, $object->errors, 'errors');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$error++;
|
$error++;
|
||||||
|
|||||||
@@ -6538,7 +6538,7 @@ function get_htmloutput_mesg($mesgstring='',$mesgarray='', $style='ok', $keepemb
|
|||||||
* @see dol_print_error
|
* @see dol_print_error
|
||||||
* @see dol_htmloutput_mesg
|
* @see dol_htmloutput_mesg
|
||||||
*/
|
*/
|
||||||
function get_htmloutput_errors($mesgstring='', $mesgarray='', $keepembedded=0)
|
function get_htmloutput_errors($mesgstring='', $mesgarray=array(), $keepembedded=0)
|
||||||
{
|
{
|
||||||
return get_htmloutput_mesg($mesgstring, $mesgarray,'error',$keepembedded);
|
return get_htmloutput_mesg($mesgstring, $mesgarray,'error',$keepembedded);
|
||||||
}
|
}
|
||||||
@@ -6556,7 +6556,7 @@ function get_htmloutput_errors($mesgstring='', $mesgarray='', $keepembedded=0)
|
|||||||
* @see dol_htmloutput_errors
|
* @see dol_htmloutput_errors
|
||||||
* @see setEventMessages
|
* @see setEventMessages
|
||||||
*/
|
*/
|
||||||
function dol_htmloutput_mesg($mesgstring='',$mesgarray='', $style='ok', $keepembedded=0)
|
function dol_htmloutput_mesg($mesgstring = '',$mesgarray = array(), $style = 'ok', $keepembedded=0)
|
||||||
{
|
{
|
||||||
if (empty($mesgstring) && (! is_array($mesgarray) || count($mesgarray) == 0)) return;
|
if (empty($mesgstring) && (! is_array($mesgarray) || count($mesgarray) == 0)) return;
|
||||||
|
|
||||||
@@ -6610,7 +6610,7 @@ function dol_htmloutput_mesg($mesgstring='',$mesgarray='', $style='ok', $keepemb
|
|||||||
* @see dol_print_error
|
* @see dol_print_error
|
||||||
* @see dol_htmloutput_mesg
|
* @see dol_htmloutput_mesg
|
||||||
*/
|
*/
|
||||||
function dol_htmloutput_errors($mesgstring='', $mesgarray='', $keepembedded=0)
|
function dol_htmloutput_errors($mesgstring='', $mesgarray=array(), $keepembedded=0)
|
||||||
{
|
{
|
||||||
dol_htmloutput_mesg($mesgstring, $mesgarray, 'error', $keepembedded);
|
dol_htmloutput_mesg($mesgstring, $mesgarray, 'error', $keepembedded);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user