Merge branch '11.0' of git@github.com:Dolibarr/dolibarr.git into develop

This commit is contained in:
Laurent Destailleur 2020-02-08 16:02:23 +01:00
commit ee29c3efdd
2 changed files with 5 additions and 2 deletions

View File

@ -676,10 +676,12 @@ class FormMail extends Form
}
else
{
// The free input of email
if (!empty($this->withtofree))
{
$out .= '<input class="minwidth200" id="sendto" name="sendto" value="'.(!is_array($this->withto) && !is_numeric($this->withto) ? (isset($_REQUEST["sendto"]) ? $_REQUEST["sendto"] : $this->withto) : "").'" />';
$out .= '<input class="minwidth200" id="sendto" name="sendto" value="'.(($this->withtofree && !is_numeric($this->withtofree)) ? $this->withtofree : (!is_array($this->withto) && !is_numeric($this->withto) ? (isset($_REQUEST["sendto"]) ? $_REQUEST["sendto"] : $this->withto) : "")).'" />';
}
// The select combo
if (!empty($this->withto) && is_array($this->withto))
{
if (!empty($this->withtofree)) $out .= " ".$langs->trans("and")."/".$langs->trans("or")." ";

View File

@ -188,7 +188,8 @@ if ($action == 'presend')
}
}
$formmail->withto = GETPOST('sendto') ? GETPOST('sendto') : $liste;
$formmail->withto = $liste;
$formmail->withtofree = (GETPOSTISSET('sendto') ? (GETPOST('sendto') ? GETPOST('sendto') : '1') : '');
$formmail->withtocc = $liste;
$formmail->withtoccc = $conf->global->MAIN_EMAIL_USECCC;
$formmail->withtopic = $topicmail;