FIX selectModelMail() : if default and no mail models select default model
This commit is contained in:
parent
31548c6fbb
commit
197d03f9d9
@ -7992,8 +7992,8 @@ class Form
|
||||
$formmail = new FormMail($db);
|
||||
$result = $formmail->fetchAllEMailTemplate($modelType, $user, $langs);
|
||||
|
||||
if ($default) $TModels[0] = $langs->trans('DefaultMailModel');
|
||||
if ($result > 0) {
|
||||
if ($default) $TModels[0] = $langs->trans('DefaultMailModel');
|
||||
foreach ($formmail->lines_model as $model){
|
||||
$TModels[$model->id] = $model->label;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user